Save button in Word

M

Manix

I have a command button at the end of a form to prompt users to save the
document to their desktop. Does anyone know the code to do this?
 
W

Word Heretic

G'day Manix <[email protected]>,

If you have a SOE, then you may be lucky enough to find the StartUp
folder is in their profile path. With a wee bit of editing, this
string can be used to calculate their desktop folder.

Steve Hudson - Word Heretic

steve from wordheretic.com (Email replies require payment)
Without prejudice


Manix reckoned:
 
S

Steve Yandl

Assuming your users will all have Win98 or beyond, the following lines will
return the string for the path to the desktop, to which you can add your
chosen file name.

Const Desktop = &H10&
Set objShell = CreateObject("Shell.Application")
Set objFldrDesk = objShell.Namespace(Desktop)
strDeskPath = objFldrDesk.Self.Path
MsgBox strDeskPath


Steve Yandl
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top