Hyperlink position in document

How can the insertion point be relocated in a Word document to where it finds a hyperlink? E.g. I would like to add some text after each hyperlink in a document. So I traverse the hyperlinks using
For each hLink in Selection.Hyperlinks
But when I try to reference hLink.Range it says that property is not defined.
Any ideas? 

Not a  hard thing, refer this
article. Download this DOC library then add reference to your project, then use the following code:
static void Main(string[] args)
Document doc = new Document();
doc.LoadFromFile("Spire.docx");
List hyperlinks = new List();
foreach (Section section in doc.Sections)
foreach (DocumentObject sec in section.Body.ChildObjects)
if (sec.DocumentObjectType == DocumentObjectType.Paragraph)
foreach (DocumentObject para in (sec as Paragraph).ChildObjects)
if (para.DocumentObjectType == DocumentObjectType.Field)
Field field = para as Field;
if (field.Type == FieldType.FieldHyperlink)
hyperlinks.Add(field);

Similar Messages

  • Relative hyperlinks in pdf documents printed from visio 2007

    Hello to all. The problem we are trying to solve is to maintain relative hyperlinks that were created in visio 2007 when we publish or print a pdf document. The pdf document that we printed is written in adobe reader 9, and it maintains the hyperlinks but as absolute ones and we required the hyperlinks to maintain as relatives. The idea is to distribute the pdf document with its hyperlinks and the documents that are linked to it in different computers that are not in the same network. The documents that we are trying to link are pdf, word and excel 2007 documents. The operating system we use is Microsoft vista home premium. Does anyone know how to maintain relative hyperlinks in a pdf document printed from visio 2007? Thanks in advance!

    Bernd Alheit, thanks for your answer. We print the pdf document from visio 2007 and then we read it in adobe reader 9. The relative hyperlinks work fine in visio 2007, but they change to absolute ones in the pdf document.

  • Insert hyperlinks in pdf-documents

    Since Mavericks you can´t insert hyperlinks in pdf-documents. I miss this option in the preview. Are there any other possibilities?
    (I have MS Office for apple, therefore the links get lost, if I convert it to pdf).

    No one here can guess what "Apple wants." This is just an end user forum. There are open source alternatives to Pages and Office you may want to research: https://discussions.apple.com/docs/DOC-6941
    http://www.apple.com/feedback is where you can put your two cents if you so desire to get Apple to consider them.

  • Add a hyperlink to another document? CS4

    Hi,
    How would one add a hyperlink to a document that refers to another document?
    The basic is:
    myDoc.hyperlinks.add(myHyperlinkTextSource, myHyperlinkTextDestination);
    How do I get "myHyperlinkTextDestination" if it exists in another, unopened InDesign document?
    I suppose I could open the document, get the Hyperlink destination, and then close it again, but in the UI this is not necessary (you simply browse to the required file and can then choose from a list of hyperlink destinations in that file). So how is this scripted?
    Thanks,
    Ariel

    Next, I tried this:
    I opened the document and got it's HyperlinkTextDestination.
    Then I used it when adding the hyperlink to the main document:
    app.activeDocument.hyperlinks.add(mySource, myDestination) //myDestination is a hyperlink destination in another document.
    And I get the following error message:
    Cannot set this property to an object in another document.
    So I'm clearly on a wild goose chase here.
    But obviously this is possible since it is doable in the UI.
    Any and all help appreciated!
    Ariel

  • How do I put a hyperlink in a document using the New Pages ... ?

    Using the "new" Pages;
    how do I put a hyperlink in a document ... ?
    I didn't have any problems with this using the Pages 4.2 or whatever ...

    There is a help menu
    http://help.apple.com/pages/mac/5.2/#/tand51db403

  • Hyperlinks within .pdf documents not working IMac Safari

    I am working with a website that displays several .pdf documents. The documents contain hyperlinks to urls. Everything works fine in other browsers, but in Safari, these hyperlinks do not work. The cursor does not change when it enters the hyperlink space, and nothing happens if the link is clicked. I am using an IMac running OS 10.6. 8 and Safari 5.1.10. I have tried both the native (Preview) option and a plug-in. Neither makes any difference. Can anyone suggest a fix other than abandoning Safari?

    I am a new user to OnLINE Adobe. My hyperlinks from Word
    documents do not transfer to the PDF files. Please help!!!

  • Change position of "document links" in query??

    Hi i've got a question...
    how can i change the position of "document links"picture in Bex Analyzer?
    The first two letters are always covered by the document picture....
    Thank you
    Chris

    In edit-mask you can force the position of the minus sign :
    USING EDIT MASK mask
    Effect
    Outputs f according to the formatting template mask.
    Without this addition, f is output in the standard format for that particular type or with a format defined in the ABAP Dictionary. The addition allows you to define a different format.
    You can specify the formatting template as follows:
    '_'represents one character of the field f
    or one digit with type P or I
    'V'only with fields of type P or I:
    output of leading sign
    'LL'at beginning of template:
    left justify (standard)
    'RR'at beginning of template:
    right justify
    '==conv'perform output conversion conv
    ':', ...separator
    (all other characters)
    Regards

  • Can I use Microsoft Project Professional to connect hyperlink a some documents in the server of our company?

    Just like the titre,
    Can I use Microsoft Project Professional to connect hyperlink to some documents in the server of our company?  I want to share some documents not in my computer, which is in the server of our company. 

    Hello,
    Sure you can, right click on required task that relates to the document, at the bottom on that menu you will see "Hyperlink". Click Hyperlink and a new window will open, in the new window in the "address" field type or paste in the web address / file share
    address etc. Click OK then you will see a web link appear in the indicator column.
    Paul
    Paul Mather | Twitter |
    http://pwmather.wordpress.com | CPS

  • Word2007 hyperlinks to pdf documents

    I have a word2007 docx that contains several hyperlinks to pdf documents. With ctrl-click to one of the links, the acrobat reader always opens and changes its window to maximized mode. I can override the page display options in the reader to always display "single page - continuous" and 100%, but there is no option to always open in normal mode for the window size.
    Is there a way to avoid this maximizing?

    I have the same issue.  This is unacceptable!

  • Hyperlinks to other Documents (non-html)?

    Hello everybody,
    is Pages unable to hyperlink to other documents (e.g. other *.pages-files, hyperlinks like "./myfile.pages") or is that function hidden somewhere else than at the hyperlinks page in the Information window?
    Thanks for any recommendations.
    Andreas

    Hello Frank,
    Thanks for your suggestion, I tried this.
    In the .pages package there is a file index.xml.gz by double clicking it extracts an index.xml. In that file one can search and replace the hyperlink's text to e.g. ./myfile.pages. Afterwards I saved the file, deleted index.xml.gz, made a .zip package of my altered index.xml, renamed the extension to index.xml.gz.
    Now if I try to open that in Pages, the application crashes. So I don't think we can hack this that easy.
    By the way: Even if that had worked, I would never consider this as a usable 'workaround'. I am using Macs because of their great user interface and that's not the way I like doing things.
    Andreas
    PowerBook 15'' Mac OS X (10.4.3)

  • How do you hyperlink one Pages document to another Pages document?

    How do you hyperlink one Pages document to another Pages document?

    Feature removed from Pages 5, along with over 90 others, by Apple.
    http://www.freeforum101.com/iworktipsntrick/viewforum.php?f=22&sid=3527487677f0c 6fa05b6297cd00f8eb9&mforum=iworktipsntrick
    Pages '09 should still be in your Applications/iWork folder.
    Archive/trash Pages 5, after Exporting your files to Pages '09, and rate/review it in the App Store, then get back to work.
    Peter

  • How to insert hyperlinks in RTF document shown in JEditorPane?

    This is a compound question so bear with me on this one :)
    What I need is to insert an hyperlink in a JEditorPane; Store it as RTF code; Retrieve it; Show it and click on it to go the the destination.
    1) So, first question, is there some method to automatically add the hyperlink and will it be saved in RTF with RTFEditorKit? (I'm actually using AdvancedRTFEditorKit but an answer to either will be enough)
    2) I tried a method that adds what appears as a link but the document that is stored doesn't have the necessary RTF codes, only the formatting that makes it look like a link. I also checked the actual RTF codes I'd need to add and they seem easy to do. So, is there a way to add the actual underlying RTF codes to the document while it's in the JEditorPane?
    I know the question(s) isn't too specific, if you can shed some light over the whole thing and point me in the right direction, it'd be great!

    Just a follow up to my own question. I found a way to answer my question 2) and I'm now storing the rtf code for hyperlinks. Now, when I show the document in JEditorPane with RTFEditorKit, I get the name of the hyperlink with no formatting indicating that it's a hyperlink.
    Example. The link "http://www.google.com" with the name "Google", only shows "Google" in plain text.
    Is it because the components I'm using don't support hyperlinks from RTF files even though they're supported from HTML files?
    Is there any way you can see this working? Is it possible to include something inside the JEditorPane that the user can click, instead of the hyperlink?

  • Where I can get hyperlinks in pdf document structure (except "Annots" entry in page dictionary)?

    Hi,
    I have two pdf documents (doc1 and doc2) with hyperlinks e.g www.somlink.com, www.somlink2.com.
    According to PDF Specification I can get those hyperlinks via Link Annotations -> URI Action. Link Annotations can be found in pdf page's dictionary under "Annots" key.
    So the problem is that in one pdf document I get that "Annots" array but in another document there is no such entry in page dictionary. But Adobe Reader recognize those hyperlinks (recognize means you can click on a link and it will be opened in web browser) in both documents. So it seems that there is another place where you can specify hyperlinks, not only in "Annots" array -> URI Action.
    Any ideas where it can be?

    No, that's where embedded ("real") link objects are.
    However, Adobe Acrobat/Reader have an "auto-detect links" feature which will read the text of the page and if it finds text that looks like a URL, make it active to click on.

  • Hyperlinks in PDF documents

    Hi there.
    The marketing department at work just came to me (in IT) asking if they could have the text "Click Here" in a document link off to a site from a PDF.
    They created the document and link in a word document and distilled it but the link disappears and just leaves the work "Click Here" is this possible in Acrobat 7.0 Standard and Professional?

    I find this easiest to do within Acrobat (unless there are lots of links!) -- using the Link to as Mike mentioned above.
    The best part is that with the link tool, my hyperlink zone -- which can be invisible -- can be any size I like. So, to capture people who don't click quite close enough to the letters, you can always expand the invisible rectangle a bit to help ensure you get all the clicks easily.

  • Hyperlinks in pdf documents created from Keynote

    For some reason the hyperlinks I've recently added to a keynote document are not active when I convert it to a pdf document. Neither Preview nor Adobe recognise them as hyperlinks.
    I've made the hyperlinks active using the inspector, and give the full url, including the http://. Can anybody help?

    Bernd Alheit, thanks for your answer. We print the pdf document from visio 2007 and then we read it in adobe reader 9. The relative hyperlinks work fine in visio 2007, but they change to absolute ones in the pdf document.

Maybe you are looking for

  • Bridge CS4 edit history problem with OS change from XP to 7

    I've changed my OS from XP to 7.  After reinstalling software, Bridge CS4 no longer keeps my editing steps in the "edit history" metadata.  The only steps recorded are that I've  saved a file.  I have the edit history box marked in preferences in bot

  • Using Boost features in CS3

    I am working on porting an plugin from CS5 to CS3 on a MAC, this plugin uses some features of boost libary. So when i try to compile the plugin in CS3 i get a no of linking errors related to boost, however the plugin builds successfully in CS5. So i

  • MainStage 1.0.2 released

    MainStage 1.0.2 addresses specific customer issues and general performance issues and improves overall stability. This update is recommended for all MainStage users.

  • Master& communication idocs

    if i send an idoc to 5 recipents how many master & comunication idocs will be generated

  • How to print PDF files using java print API

    Hi, I was goign throw lot of discusion and reading lot of forums related to print pdf files using java api. but nothing seems to be working for me. Can any one tell me how to print pdf files using java api. Thanks in advance