>We are using LogonUser & ImpersonateLoggedOnUser functions to make our .exe's run in separate threads from the actual logged-on PC. This enables us to hide some directory access (i.e., from users trying to access the files externally, rather than by using the program directly.) We have just discovered that ShellExecute doesn't seem to function under this alternate login. We formerly used VBA commands in FoxPro, to open Word, Excel, etc., & that all works fine under the alternate login. We were hoping the use ShellExecute instead, to avoid needing to code specifically for each potential document type.
>
>Actually, to be 100% accurate, ShellExecute does work, but ONLY if the called-for application (Word, Excel, Windows Viewer, Internet Explorer, etc.) is ALREADY OPEN on the PC. What ShellExecute won't apparently do is open the called-for application if it isn't already open.
>
>Any ideas of how to solve this?
>
>Thanks,
Randy,
Are you using a call to open the application or a specific document/ For example, if you pass the fully qualified file name of a Word document, it should open the document in Word. Same with Excel.
George
Ubi caritas et amor, deus ibi est