Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Eric den Doop
  Where is Eric den Doop?
 Houten
 Netherlands
 Eric den Doop
 To: Bogdan Pratia
  Where is Bogdan Pratia?
 Satu Mare
 Romania
 Bogdan Pratia
 Tags
Subject: RE: Controlling serial ports (COM1,2...) from VFP
Thread ID: 16055 Message ID: 16059 # Views: 1 # Ratings: 0
Version: Unknown Category: General VFP Topics
Date: Tuesday, October 08, 2002 11:23:56 AM         
   


> Hi, everybody!
>
> My name is Bogdan Pratia and I have a problem with controlling the COM ports from Visual FoxPro (6.0), without ActiveX or other tools if possible.
> I belive that the following code should work:
>
>
> nHandle=FOPEN(COM1,2)	&& buffered
> FWRITE(nHandle, cCommand, nCharactersWritten)
> FCLOSE(nHandle)
> 

>
> but I don't know what should I write instead of cCommand and nCharactersWritten to open and close an electrical circuit depending on sistem clock.
>
> Thank you!
>
> Bogdan Pratia

It doesn't work that way. Use the MSCOMM32.OCX active x control instead. I use it to retrieve data from PBX telephony systems.
--
Eric den Doop
www.foxite.com - The Home Of The Visual FoxPro Experts

ENTIRE THREAD

Controlling serial ports (COM1,2...) from VFP Posted by Bogdan Pratia @ 10/8/2002 9:28:21 AM
RE: Controlling serial ports (COM1,2...) from VFP Posted by Eric den Doop @ 10/8/2002 11:23:56 AM