T
TC
You need to enclose the document filepathname in quotes.
Cut & paste this line:
Shell ("winword.exe ""\\Melfs004\PublicFolders\A5 - TRF Documents\03 -
Position Profiles\Profiles.doc""")
or do this:
dim sDoc as string
sDoc = "\\Melfs004\PublicFolders\A5 - TRF Documents\03 - Position
Profiles\Profiles.doc"
Shell ("winword.exe """ & sDoc & """")
Within a string, two quotes denotes a single quote. So "A""B" means [one A],
[>one< quote], [one B]. So with either method shown above, this is what is
passed to Shell():
winword.exe "\\Melfs004\PublicFolders\A5 - TRF Documents\03 - Position
Profiles\Profiles.doc"
Then winword will see the second parameter as >one< parameter - not as
winword.exe \\Melfs004\PublicFolders\A5 - TRF Documents\03 - Position
Profiles\Profiles.doc
^1 ^2 ^3 etc.
HTH,
TC
Cut & paste this line:
Shell ("winword.exe ""\\Melfs004\PublicFolders\A5 - TRF Documents\03 -
Position Profiles\Profiles.doc""")
or do this:
dim sDoc as string
sDoc = "\\Melfs004\PublicFolders\A5 - TRF Documents\03 - Position
Profiles\Profiles.doc"
Shell ("winword.exe """ & sDoc & """")
Within a string, two quotes denotes a single quote. So "A""B" means [one A],
[>one< quote], [one B]. So with either method shown above, this is what is
passed to Shell():
winword.exe "\\Melfs004\PublicFolders\A5 - TRF Documents\03 - Position
Profiles\Profiles.doc"
Then winword will see the second parameter as >one< parameter - not as
five<, which is probably what happens with this:
winword.exe \\Melfs004\PublicFolders\A5 - TRF Documents\03 - Position
Profiles\Profiles.doc
^1 ^2 ^3 etc.
HTH,
TC