Multi Network Servers?
Multi Network Servers?
Result = CreateNetworkServer(4444)
Result = CreateNetworkServer(5555)
Result = CreateNetworkServer(6666)
if i only want to shutdown listening on port 5555 how can i do that since CloseNetworkServer() has no parameter for it??
Result = CreateNetworkServer(5555)
Result = CreateNetworkServer(6666)
if i only want to shutdown listening on port 5555 how can i do that since CloseNetworkServer() has no parameter for it??
AMD 1.8 - 512mb - ATI All-In-Wonder Radeon 9000 pro - W2k Pro
BASIC programmers never die, they just return without gosub.
BASIC programmers never die, they just return without gosub.
Syntax
Result = CreateNetworkServer(Port)
Description
Create a new network server on the local computer at the specified port. Port values can range from 6000 to 7000 (this is a recommended area space, but it can go from 0 to 16000 in reality). Any number of servers can run simultaneously on the same computer but not with the same port number. However, there can only one Server be started from every Pb program. If the 'Result' is 0, the server can't be created (port in use), otherwise the server has been correctly created and is ready to use.
This is not quite accurate, i did a netstat and ports 4444/5555/6666 were in listening mode. In theory it works fine, it's only if i want to shutdown one of them. To be more precise:However, there can only one Server be started from every Pb program.
I'm currently doing an IRC engine and i require port 113 for idendt requests and another one for DCC. Looks like i'll have to decide which feature to throw out.. the ident or DCC?
See my dilema here?
AMD 1.8 - 512mb - ATI All-In-Wonder Radeon 9000 pro - W2k Pro
BASIC programmers never die, they just return without gosub.
BASIC programmers never die, they just return without gosub.
Let me clear this up 
Note the bold part...Syntax
Result = CreateNetworkServer(Port)
Description
Create a new network server on the local computer at the specified port. Port values can range from 6000 to 7000 (this is a recommended area space, but it can go from 0 to 16000 in reality). Any number of servers can run simultaneously on the same computer but not with the same port number. However, there can only one Server be started from every Pb program. If the 'Result' is 0, the server can't be created (port in use), otherwise the server has been correctly created and is ready to use.
-Mitchell
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net
hmm... well it sounds like he noticed that the first time... however in practice he was able to actually open more than one. of course.. i could be wrong, that's just what it sounded like to me.
i do think it would be a worthy request to put into the request section though ~_^
i myself am working on a project that could definantly benefit from the ability to have more than one server running through the same app..
@AngelSoul, just a few ideas...
maybe you could make more than one EXE, and have them communicate between each other, then it would only be one server per app, but the combined apps could work as a whole....
i haven't made any DLL's yet.. so i can't speak from experience, but perhaps you could make a server from DLL's, and just manipulate them through the main EXE....
anyhow, just a few thoughts.
*editted for bad grammar, cauze me no good at good gramar*
i do think it would be a worthy request to put into the request section though ~_^
i myself am working on a project that could definantly benefit from the ability to have more than one server running through the same app..
@AngelSoul, just a few ideas...
maybe you could make more than one EXE, and have them communicate between each other, then it would only be one server per app, but the combined apps could work as a whole....
i haven't made any DLL's yet.. so i can't speak from experience, but perhaps you could make a server from DLL's, and just manipulate them through the main EXE....
anyhow, just a few thoughts.
*editted for bad grammar, cauze me no good at good gramar*
--Aszid--
Making crazy people sane, starting tomorrow.
Making crazy people sane, starting tomorrow.
The fact that you can open several servers doesn't mean that you're meant to. Why it's mentioned in the manual is because there's no way with the current commandset to tell wich port the incomming data is received on and i don't even know if PB just receives data from the latest opened server port or from all of them.
Last edited by Pupil on Thu Jul 31, 2003 9:47 pm, edited 1 time in total.
I was only joking with my post.. By all means, put this in the feature requests forum!
-Mitchell
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net
Thanks aszid for the suggestion, i thought about it right after but i realized that my problem is virtually solved since ident requests are done in the beginning of the connection only. After that i simply re-initialize a new server port for DCCs.
I'm sure this will be resolved in a future release (hopefully) and UDP support?
Anyway i'm celebrating my 4th day or PB programming :>
I'm sure this will be resolved in a future release (hopefully) and UDP support?
Anyway i'm celebrating my 4th day or PB programming :>
AMD 1.8 - 512mb - ATI All-In-Wonder Radeon 9000 pro - W2k Pro
BASIC programmers never die, they just return without gosub.
BASIC programmers never die, they just return without gosub.
Another bump of course .. can we expect a more filled net library in PB4?
Also, Ident would be used all throughout the lifetime of the irc client if the client connects to more then one server at any given time (like mine).
Right now I created a dll with tailbite to take care of the ident server. However, I cannot do that in Linux since Tailbite does not work in Linux. And that is the only thing that is preventing the app from running in linux.
Also, Ident would be used all throughout the lifetime of the irc client if the client connects to more then one server at any given time (like mine).
Right now I created a dll with tailbite to take care of the ident server. However, I cannot do that in Linux since Tailbite does not work in Linux. And that is the only thing that is preventing the app from running in linux.





