Results 1 to 8 of 8
  1. #1
    3 Star Lounger
    Join Date
    Jun 2009
    Location
    Hemet CA
    Posts
    310
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Talking

    I have a Userform that I enter data on, which updates on to the main document using bookmarks, I then use these same bookmarks to transfer data to various other word documents, using this method,
    Copy/Special Paste/Unformatted Text/Past Link
    And I also adjust my font colors and size at this point. This method works great with the Linking part, except when I re-enter or update new data and it happens to have a larger amount of text, the first portion will be formatted correctly but the last section will resort back to original font setting from book mark. How do I set this up so that no matter what amount of text I put in, small amount or large amount if will keep the setting I need.
    and by the way I am using Word 2007

  2. #2
    Plutonium Lounger
    Join Date
    Nov 2001
    Posts
    10,550
    Thanks
    0
    Thanked 7 Times in 7 Posts
    Type Alt-F9 in the target document to show the links as fields.
    Add \*CHARFORMAT to the end of the link field
    Format the first letter of the field (the L of Link) to have the formatting you want for the whole field
    The field will now be something like...



    { LINK Word.Document.12 "C:\\Users\\Me\\Desktop\\Document 1.doc" "OLE_LINK1" \a \t \*CHARFORMAT }

    Type Alt-F9 again so you see field results instead of field codes
    Select the field and type F9 to update it

  3. #3
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts
    Click in one of the link fields in the destination document.
    Press Shift+F9 to show field codes.
    You'll see something like

    { LINK Word.Document.8 "OtherDocument.doc" "OLE_LINK1" \a \t \* MERGEFORMAT }

    Change MERGEFORMAT to CHARFORMAT. (If \* MERGEFORMAT is absent, add \* CHARFORMAT before the closing bracket.)
    Press F9 to hide the field code and update the result.
    Repeat for each link field.

  4. #4
    3 Star Lounger
    Join Date
    Jun 2009
    Location
    Hemet CA
    Posts
    310
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thank you both very much, it appears to solve my issue and I also learned that I could use Alt + F9 to view all link fields or use Shift + F9 (when highlighted) to view single link field.
    HansV when I was first viewing my link fields they appeared like so
    { LINK Word.Document.8 "OtherDocument.doc" "OLE_LINK1" \a \t }
    So of course I added \* C?HARFORMAT before the closing bracket.
    Then I Press F9 to hide the field code and update the result.
    When I completed all of my fields I saved then closed
    Upon reopening to verify the links where working correctly I was getting an error message in my link fields. So I pressed Alt + F9 to view all link fields. I noticed that all link fields looked like
    { LINK Word.Document.8 "OtherDocument.doc" "OLE_LINK1" \a \t \* C?HARFORMAT \* MERGEFORMAT }
    But I noticed one link that was still working did not have the ( ? ) in CHARFORMAT so I removed the ? from all of the Link field and it seems to work at least at the moment. Is this going to be a problem down the road or was this the right fix.
    I have a whole lot of other documents that need same corrections made so I want to get it right, back tracking is no fun.
    Thank you again for all your assistance

  5. #5
    Plutonium Lounger
    Join Date
    Nov 2001
    Posts
    10,550
    Thanks
    0
    Thanked 7 Times in 7 Posts
    I think that the ? in \* C?HARFORMAT was a typing error.

    You should not have both \* CHARFORMAT and \* MERGEFORMAT in your links. Delete the \* MERGEFORMAT

  6. #6
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts
    The ? was a typo (sorry!), as was clear from the first part of the sentence and from Stuart's reply. I have corrected the error.

  7. #7
    3 Star Lounger
    Join Date
    Jun 2009
    Location
    Hemet CA
    Posts
    310
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi
    The link seems to change the location for some unknown reason.
    Here is how it works. On my userform when I prepare to start a new report I select the reset reports, using a command button that copies a new set of reports (Word documents) from a separate folder called “Master reports” it then replaces the old copies with the new.
    My newly copied reports have no data entered at this point. As I mentioned previously above they are linked to bookmarks from my “HomeInspect.docm” .
    I checked on the Master Report copies and they seem to be correct, it all seems to change when they are copied and then replacing the old copies. It only does it on the last 3 links of 10
    Here is how the links look
    working
    Code:
    { LINK Word.Document.12 “C:\\Program Files\\Home Inspection Program\\Home Inspect.docm”CompanyAddress \a \t \* CHARFORMAT }
    NOT Working - Error! Not a valid link
    Code:
    { LINK Word.Document.12 “C:\\Program Files\\Home Inspection Program\\Inspection Reports\\Home Inspect.docm”CompanyAddress \a \t \* CHARFORMAT }
    It seens to add Inspection Reports for some unknown reason
    any thoughts why this maybe happening
    When I remove Inspection Reports from link it works??????

  8. #8
    3 Star Lounger
    Join Date
    Jun 2009
    Location
    Hemet CA
    Posts
    310
    Thanks
    0
    Thanked 0 Times in 0 Posts
    As to my previous reply I seem to have stopped the links from adding an additional location, not sure what I did.

    I thank you all for all of your assistance

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •