saving a file - syntax problem

  • Thread starter ozgirl via AccessMonster.com
  • Start date
O

ozgirl via AccessMonster.com

Hi,

i'm hoping someone can help me.

i have some code which saves a report to specific place. the problem i have
is when two people run the report at the same time. one works and the other
gets an error

the path i currently have is
V:\Temp\rptRCTI_Expanded.rtf

what would the correct syntax be above to have the file save to My Documents
for each user. (My Documents has the space)

thanks heaps
Lee-Anne
 
J

John Nurick

This function will return the user's My Documents folder:

Public Function MyDocumentsFolder() As String
Dim wshShell As Object
Set wshShell = CreateObject("WScript.Shell")
MyDocumentsFolder = wshShell.SpecialFolders("MyDocuments")
End Function
 
O

ozgirl via AccessMonster.com

many thanks John..

John said:
This function will return the user's My Documents folder:

Public Function MyDocumentsFolder() As String
Dim wshShell As Object
Set wshShell = CreateObject("WScript.Shell")
MyDocumentsFolder = wshShell.SpecialFolders("MyDocuments")
End Function
[quoted text clipped - 12 lines]
thanks heaps
Lee-Anne
 
Top