B4J Question Can i make "multi-ServerSocket" in same Application ?

Waldemar Lima

Well-Known Member
Licensed User
Longtime User
hi everyone !

i would like create multi-serverSocket to listen in same Application like this :

B4X:
Sub Process_Globals
    
    Public server1 As ServerSocket
    Public server2 As ServerSocket
    Public AStream As AsyncStreams
    
End Sub

Sub AppStart (Args() As String)
    
    server1.Initialize(5566, "server1")
    server1.Listen
    server2.Initialize(5562, "server2")
    server2.Listen
    StartMessageLoop   
    
End Sub

will this result in future problems?
 

OliverA

Expert
Licensed User
Longtime User
Upvote 0
Top