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 John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using the Messenger Service from FoxPro

Status
Not open for further replies.

ajpa

Programmer
Jan 31, 2002
52
GB
I've put an application on computer A (running Windows 2000). It can be accessed by lots of computers (B1, B2, etc) running any old Windows. When a user leaves I want to send an alert to computer C, running Windows 2000. I've tried

RUN NET SEND <user_id> <message text>

What I get is an error message in the DOS window that says

CMD.EXE was started with &quot;\\Fileserver\shared_pc\staff\absentees&quot; as the current directory path. UNC paths are not supported. Defaulting to Windows directory.

So RUN has managed to kick off, and the only worry expressed in the FoxPro manual is that it might not be able to find CMD.EXE, which it obviously can.

Does anyone know what a UNC path is, and how I can get round this problem?

There's a related issue. If user B doesn't have Windows 2000, his own computer won't have the NET SEND command. Is there any way of forcing the FoxPro program to use computer A's resources?

Yet another related problem is that of the date and time functions. Their values seem to come from the user's computer (B) when the program calls for them. Can I force the values to come from the computer on which the program resides (A)?
 
UNC= Universal naming convention
A way to identify a machine on a network. It uses the following format: \\servername\shared ressource\.
I suspect that your application uses UNC to define the default directory. Try changing it to the stadard format: Drive:\directory
Jean
 
Thanks for this.

The home directory was declared when I built the application on my own computer as c:\ss\absentees\. Then I just parked the .exe file with the various support files on the remote computer in the folder mentioned. Foxpro is detecting the path and sending it to DOS by itself. I don't think I've got any control over what that path is, have I? Is there a switch that will force FoxPro to use the standard format you suggest?

Tony
 
I tried to reproduce this behavior on an NT machine without success. Worked fine there. Suspend it has something to do about how Win2000 deals with DOS Based programs. Yes Net.exe (at least in NT) is a DOS program....

Check if you have a foxrun.pif program and take attention to de working directory. You could also rename this file and then try your program....

Hope this is usefull....

Jean
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top