Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Tcp/ip
Message
 
To
28/02/2007 11:55:11
Scott Sherman
Puyallup Tribal Health Authority
Tacoma, Washington, United States
General information
Forum:
Visual FoxPro
Category:
Internet applications
Title:
Re: Tcp/ip
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01199639
Message ID:
01199693
Views:
16
Scott,

It can be done with Winsock ActiveX or API. The following are VFP code samples that use Winsock API calls (subscription is required):

How to create non-blocking Winsock server
http://www.news2news.com/vfp/?example=412

A client for testing non-blocking Winsock server
http://www.news2news.com/vfp/?example=413

A listener ideally must be multi-threaded: after connection established with a client, a thread is created to process client's request; but the listener keeps listening on another thread.

This scenario is not possible in VFP due to its single-thread nature. Unless such listener starts new VFP instance for each request to be processed.

An example, a listener receives SQL SELECT requests and returns results to clients. Some SQL SELECT requests may take quite a time to be processed and sent back to client. During this time VFP listener does not actually listens.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform