Klaatu Posted August 2, 2006 Share Posted August 2, 2006 I'm a little confused on the TCPStartup and UDPStartup functions. Specifically in a UDF, how do I know if TCPStartup() or UDPStartup() has already been called? Does it hurt to call these if they've been called already? What if I call TCPShutdown() in my UDF but there's TCP activity going on outside of my UDF? How do I know? As far as I've been able to determine, there is no way for me to know (within my UDF at least).So, is there any downside in calling TCPStartup() and UDPStartup() in a OnAutoItStart() function, and never calling TCPShutdown() or UDPShutdown()? Or, at the very least, calling the two shutdown functions in an OnAutoItExit() function? Or am I wrong in my initial premise? Would there be a problem, peformance hit or anything like that, if no TCP or UDP activity was needed, but these startup functions were called anyway?"I am confused." -- Lewis Black My Projects:DebugIt - Debug your AutoIt scripts with DebugIt! Link to comment Share on other sites More sharing options...
Helge Posted August 2, 2006 Share Posted August 2, 2006 Specifically in a UDF, how do I know if TCPStartup() or UDPStartup() has already been called?Not sure about the other part, but @error is set to 10093 if you attempt to do any actionswithout using *Startup first. So if you do a TCPSend and if @error is 10093, then you canjust do a TCPStartup and TCPSend again. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now