Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MAPISession.Signon changes default drive and current directory

Status
Not open for further replies.

pcwc66

IS-IT--Management
Dec 14, 2001
163
US
After I issue MAPISession.Signon, the default drive sys(5) and current directory sys(2003) will be changed to c:\program files\common files\system\mapi\1033\NT. Is this unexpected change related to msmapi32.dll which is located in that directory.

Thank you for any info.
 


How does this relate to a VFP problem?

Mike Gagnon

If you want to get the best response to a question, please check out FAQ184-2483 first.
 
Hi Mike,

I'm using the MAPISession and MAPIMessage Controls in my VFP application. I don't expect that using those controls will change the default drive and current directory. In a way, you're right that this is probably an issue related to MAPISession and MAPIMessage Controls. However, since this issue is changing the running environment of my VFP application, I consider it is related to VFP too. In order to resolve this issue, I have to issue CD command to switch back to the original drive and directory before the Signon. Otherwise, the application will crash. I'm not sure whether it is an common issue in using ActiveX controls or not.



 
Yes, you've found the same thing I've found.
The default directory does change when instantiating the MAPI controls.

You can CD back to the right directory, and everything works fine.

I've never seen another ActiveX control do the same thing, but apparently that's because they were designed well....
 
Hi,
Although no MAPI-issue, same happens (change of defaultdir) to me when printing using a PDF-driver.
-Bart
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top