Login  
Search All Forums
Dart Home | PowerTCP Winsock for ActiveX | Custom Development Reply | PowerTCP Winsock for ActiveX Topics | Forums   
AuthorForum: PowerTCP Winsock for ActiveX
Topic: tcp control limit
rklenotiz

From: Rochester, NY USA
Posts: 19
Member Since: 08/08/03
posted August 8, 2003 1:05 PM

I would like to put an array of tcp controls on a form...and use a daemon to accept the connections and assign to tcp(0), tcp(1), etc etc.

Is there some limit on how many tcp(X) objects can be put on a form?
Thank you.
Tony Priest



From: Utica, NY USA
Posts: 8466
Member Since: 04/11/00
posted August 8, 2003 1:10 PM

The only limit would be resources, I've put as many a 100 on a program before with no problem.
rklenotiz

From: Rochester, NY USA
Posts: 19
Member Since: 08/08/03
posted August 8, 2003 1:18 PM

Ok, thanks. Thought that might be the case (resources) and good to hear.

2 other quickies....

1. Would a VB DOEVENTS be a bad statement in a TCP event procedure??

2. Error 10060. I don't seem to be able to trap it with ON ERROR. Is there a way to catch it?
Tony Priest



From: Utica, NY USA
Posts: 8466
Member Since: 04/11/00
posted August 8, 2003 1:41 PM

1) Yes, putting DoEvents in our event is a bad thing. Our events are non-reentrant so allowing other events to fire before ours has exited can cause unpredictable behavior. You should not be doing anything in an event that would take that long anyway.

2) What have you tried to do to trap the error that hasn't worked?
rklenotiz

From: Rochester, NY USA
Posts: 19
Member Since: 08/08/03
posted August 8, 2003 3:27 PM

Ok, thanks for the info.  My receive event code is really short. More curious than anything.

I have ON ERROR active in each event section but still getting the 10060 (standard windows fatal message window...).
Tony Priest



From: Utica, NY USA
Posts: 8466
Member Since: 04/11/00
posted August 8, 2003 3:37 PM

Why do you have On Errors in your events?

The On Error would go around your method calls like Connect or Receive.

Example:

On Error goto OnError
  Tcp1.Timeout = 10000
  Tcp1.Connect "www.dart.com", 80
  msgbox "Connected!"
  goto Done
OnError:
  msgbox err.number
Done:

In this example, if the connection is not established in 10 seconds, you will get a message box that says "10060"



rklenotiz

From: Rochester, NY USA
Posts: 19
Member Since: 08/08/03
posted August 8, 2003 3:42 PM

Sorry, I mis-spoke.  My error handling is just like your suggestion. Wrapped around the method calls.  Perhaps I missed one, let me double check......odd in that in only happens VERY rarely...maybe once a day at most.  I'm doing everything with timeout=0 (on the server side)....
Tony Priest



From: Utica, NY USA
Posts: 8466
Member Since: 04/11/00
posted August 8, 2003 3:49 PM

If timeout is 0, the OnErrors will not catch anything. All errors will fire in the Error Event.

Also, if timeout is zero, your program will be very different than if timeout > 0.

Please take a look at some of the samples.

Also, read the Online Help description of the timeout property.

rklenotiz

From: Rochester, NY USA
Posts: 19
Member Since: 08/08/03
posted August 8, 2003 3:50 PM

Last question. Just looked and my dartsock.dll is version 2.8.0.4 from last Nov.  Can I download the latest fixes and keep the same license info intact?
Tony Priest



From: Utica, NY USA
Posts: 8466
Member Since: 04/11/00
posted August 8, 2003 3:50 PM

Yes
Reply | PowerTCP Winsock for ActiveX Topics | Forums   
This site is powered by PowerTCP WebServer Tool PowerTCP WebServer for ActiveX