R
Reg
I have made a small Access database for my daughter to use at her work to
send and store emails. It uses code I have found on the www and behaves fine
when I use it, but gives an error when she tries to use it.
My default email client is Outlook Express and hers is Outlook but the error
seems to occur before Outlook is opened
At one point the code is as follows
Private Function EmailCreate(sTmpFile) As Long
Dim hFile As Long
hFile = FreeFile
Open sTmpFile For Output As #hFile
EmailCreate = hFile
End Function
She gets an Error 55 (file already open) at the line
Open sTmpFile For Output As #hFile
Stepping through the code she sees hFile is intially 0 and then becomes 1
when it is assigned a FreeFile
I would be grateful if someone could explain what is causing this error.
Thanks
send and store emails. It uses code I have found on the www and behaves fine
when I use it, but gives an error when she tries to use it.
My default email client is Outlook Express and hers is Outlook but the error
seems to occur before Outlook is opened
At one point the code is as follows
Private Function EmailCreate(sTmpFile) As Long
Dim hFile As Long
hFile = FreeFile
Open sTmpFile For Output As #hFile
EmailCreate = hFile
End Function
She gets an Error 55 (file already open) at the line
Open sTmpFile For Output As #hFile
Stepping through the code she sees hFile is intially 0 and then becomes 1
when it is assigned a FreeFile
I would be grateful if someone could explain what is causing this error.
Thanks