Jay
Sat Jan 24 23:09:11 CST 2004
Charles Warner <rathernot@havemail.com> wrote:
>I've done my Usenet homework on this, but still can't find the proper
>syntax for this:
>
>I have a UserForm open, with some text stored in the "txtInsert" field
>in the form.
>
>What is the syntax to attach to a command button on the form to insert
>the value of txtInsert into the document at the current cursor
>position?
Selection.Text = txtInsert.Text
That statement will leave the entire insert highlighted. If you want
the cursor to move to the end of the insert, so that more stuff can be
inserted without overwriting, follow up with the statement
Selection.Collapse wdCollapseEnd
--
Regards,
Jay Freedman
Microsoft Word MVP FAQ:
http://www.mvps.org/word