Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Any help in using Communication Control in VFP?
Message
From
18/08/1999 09:14:09
 
 
To
18/08/1999 08:21:22
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
00254884
Message ID:
00254923
Views:
22
>Hi...
>
>Anyone had any experience using the ActiveX Communication Control in VFP 6.0?
>
>I'm trying to use it to have my modem dial up and connect to another computer within my foxpro app, handshake, send a txt file, stay on the line for 2 min, and receive a txt file back from the remote computer.
>
>I find the MSDN documentation a bit lacking (for me, anyway-- given my limited experience writing communication scripts) and am looking for a few tips, or some direction to white papers etc.
>

There arre some samples here on UT in the Files Section showing simple interaction with the MSCOMM32 control; you might try those. You'll probably be fairly freustrated, though, since the MSCOMM32 control is a low-level comm port control, with no concept of a modem - it lets you have primitive control of the comm port, so you'll have to write everything yourself.

My advice is to get VFP entirely out of the communications loop. You can use on of the native dial-up networking services like RAS to establish a connection between the two systems, and then use high-level VFP concepts (like COPY FILE) to handle copying a file to and from the target system. If you find RAS and Dial-Up networking tought to handle, you can use a package like POCAnywhere to establish the connection instead; it may prove an easier path.

Doing this radically expands the capabilities of your connection between the two machines; it no longer matters if you're dialing directly, using VPN across an internet connection, using a LAN, or have the ports hard-wired to each other. You no longer are concerned about the type of modem, which comm port is used, or how to manage dialing strategy (what to do if you get a busy signal, or don't get dial tone), or what happens if the connection drops mid-transfer.

If you'd rather write all the crud required to do this by hand at both ends (remember, something has to answer the phone, accept the file, do something and pass back a result at the other end, so it's not just a one-way process) or are talking to a different type of system that won't support RAS-like connects, you'll probably find a package like CommTools, which has built-in understanding of handling the modem and the like considerably easier to use. You can purchase CommTools through Hallogram, an advertiser here on UT. You might also consider using a scriptable communications product like Telix or ProComm to handle this, launching the comm package with an appropriate script from VFP.

>Or is there an easier way within VFP to do what I'm trying to do?
>
>Any help appreciated.
>
>best...
>
>ken
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform