Is there any way in VBA (Office 2000) to learn the name of the current
directory/folder?

I know how to change the current directory using the command
ChangeFileOpenDirectory

And I know how to see the current default folder, by examining

temp = Options.DefaultFilePath(wdDocumentsPath)

But neither one does what I want.

Say that my default folder is "C:\My Documents", but I have changed
the current directory from the default by "manually" opening a file in
a directory other than the default.

Can a macro obtain and do something with the name of this new folder?


--
Steve M - unspam@houston.rrwax.com (remove wax for reply)

Chaos. I can relate to that. My life is chaos most of the time. I
am in tune with the universe. It feels like home. -- Robert Fulghum

Re: Name of current OpenDirectory by Perry

Perry
Sun Jan 04 07:03:12 CST 2004

Try CurDir() function

? CurDir
C:\Documents and Settings\Perry\My Documents

Krrds,
Perry

"Steven M (remove wax to reply)" <unspam@houston.rrwax.com> wrote in message
news:jpsevvkalg4fjuj3jjtfbit73m560aq326@4ax.com...
> Is there any way in VBA (Office 2000) to learn the name of the current
> directory/folder?
>
> I know how to change the current directory using the command
> ChangeFileOpenDirectory
>
> And I know how to see the current default folder, by examining
>
> temp = Options.DefaultFilePath(wdDocumentsPath)
>
> But neither one does what I want.
>
> Say that my default folder is "C:\My Documents", but I have changed
> the current directory from the default by "manually" opening a file in
> a directory other than the default.
>
> Can a macro obtain and do something with the name of this new folder?
>
>
> --
> Steve M - unspam@houston.rrwax.com (remove wax for reply)
>
> Chaos. I can relate to that. My life is chaos most of the time. I
> am in tune with the universe. It feels like home. -- Robert Fulghum