|
-
September 1st, 2004, 07:18 AM
#1
Special folders on network
Hi. Need some help here.
Is it possible to find a special folder on another machine over a network?
Currently I use SHGetSpecialFolderPath to find the All Users folder on my machine, but how can I find the All Users folder for someone else's machine (over a LAN)from a program running on mine? Can this be done?
Basically, I need my program to write a file on someone else's machine on the network, but I don't know which directories are going to have write permissions etc, so I need to use one of the special folders (or somewhere else appropriate - any ideas?).
Does anyone have any advice for me?
Cheers.
-
September 1st, 2004, 07:41 AM
#2
Re: Special folders on network
 Originally Posted by Jim1981
Currently I use SHGetSpecialFolderPath to find the All Users folder on my machine, but how can I find the All Users folder for someone else's machine (over a LAN)from a program running on mine? Can this be done?
No.
You have to share the folder that you want on the other machine.
Or use a client-server design.
Make a little app (client) that runs on the other machine. Then send a message from your machine to the client (including the file data). The client can then write the file to the desired folder, because it is running on the other machine.
-
September 1st, 2004, 08:01 AM
#3
Re: Special folders on network
Right, thanks Marc.
Just thinking now about the quickest, easiest way of sorting out my problem.
Is it possible to run an executable from my program and get a return value from it when it closes?
I know this can't be done using WinExec, but maybe some other way?
-
September 1st, 2004, 09:22 AM
#4
Re: Special folders on network
You can use CreateProcess, WaitForSingleObject and GetExitCodeProcess to respectively start the app, wait untill it finished and get the result code.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|