Results 1 to 4 of 4
  1. #1
    New Lounger
    Join Date
    Oct 2009
    Location
    Amsterdam
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    In WordPerfect (version X3) I can make merge documents that start a macro to obtain user-input and fill variables which are used in the merge. Is this also possible in Word 2007?

    Regards,
    Ed

  2. #2
    Super Moderator
    Join Date
    May 2002
    Location
    Canberra, Australian Capital Territory, Australia
    Posts
    5,054
    Thanks
    2
    Thanked 417 Times in 346 Posts
    [quote name='evdbogaard' post='798329' date='16-Oct-2009 21:15']In WordPerfect (version X3) I can make merge documents that start a macro to obtain user-input and fill variables which are used in the merge. Is this also possible in Word 2007?

    Regards,
    Ed[/quote]
    Hi Ed,

    Welcome to the Lounge.

    In Word, you can use FILLIN and ASK fields to solicit user input in a mailmerge document. Depending on how you set these up, the prompt can occur once per merge or once per record. For the latter, you can even get the prompt to tell the user which record is being merged.
    Cheers,

    Paul Edstein
    [MS MVP - Word]

  3. #3
    New Lounger
    Join Date
    Oct 2009
    Location
    Amsterdam
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi Paul, thanks for your reply.
    Maybe you can help me on the way with a related question.

    I have a macro in WP that merges a formfile with a datafile to store the contents a datafield (e.g. field(1)) into a variable. Then I close the file which was created during the merge. The variable stays in memory (the macro is still running) and is used in a macrostatement to change the default directory and then opens that directory.

    I can't figure out how to do this in Word / VBA. How can I instruct VBA to get the contents of a datafield into a variable? The data file is either a comma delimited txt-file or a dbf-file.

    Any help will be appreciated.

    Thanks,
    Ed

  4. #4
    Super Moderator
    Join Date
    May 2002
    Location
    Canberra, Australian Capital Territory, Australia
    Posts
    5,054
    Thanks
    2
    Thanked 417 Times in 346 Posts
    [quote name='evdbogaard' post='800031' date='27-Oct-2009 09:24']Hi Paul, thanks for your reply.
    Maybe you can help me on the way with a related question.

    I have a macro in WP that merges a formfile with a datafile to store the contents a datafield (e.g. field(1)) into a variable. Then I close the file which was created during the merge. The variable stays in memory (the macro is still running) and is used in a macrostatement to change the default directory and then opens that directory.

    I can't figure out how to do this in Word / VBA. How can I instruct VBA to get the contents of a datafield into a variable? The data file is either a comma delimited txt-file or a dbf-file.

    Any help will be appreciated.

    Thanks,
    Ed[/quote]
    Hi Ed,

    I've never used Wordperfect, so I've really no idea what you mean. In Word, though, a mailmerge in run from a mailmerge main document. Opening the mailmerge main document causes Word to load the data also. If you merge to, say, a letter, the merge process creates a new file containing one 'letter' per record. You can save the new file in whatever folder and with whatever filename is valid. Closing the letter generated by the mailmerge doesn't close the data source - AFAIK, it remains in memory while mailmerge main document is open.
    Cheers,

    Paul Edstein
    [MS MVP - Word]

Posting Permissions

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