nullmicgo
nullmicgo

Reputation: 633

In AsyncSocket framework, how to do more than one Socket Connection in iPhone?

I am now using AsyncSocket for iPhone socketing connection development. http://code.google.com/p/cocoaasyncsocket/

But I am having problem that, how to connect 2 multi-server to collect data from server?

I have host IP address A: 201.22.33.XXX.XX and host IP address B: 202.33.XXX.XX

I can success connect one server to collect data. But how to collect both server at the same time?

I tried create two socket objects with their own delegates, my path is like that:
step 1 ---- Connect to A step 2 ---- Connect to B Step 3 ---- Disconnect B but at this moment when i disconnect B, A also disconnected....

Please help.

Upvotes: 1

Views: 724

Answers (1)

Flyingdiver
Flyingdiver

Reputation: 2142

You'll need to create two socket objects with their own delegates. I have several applications that connect to multiple servers at once.

Upvotes: 1

Related Questions