Question Open Multiple instances

carlin

New member
Joined
May 10, 2016
Messages
2
Programming Experience
3-5
How to open multiple instances in c#. Whenever i get multiple requests to the c# method.
I want to to process both the requests in separate instances.
something like the below code.


int noOfrequests = 2;
myclass request1 = null
using (request1 = new myclass())
{
connection.open();

//process business rules

request1.close();


}


If there is second request, On processing of request1 then i have to process the second request in parallel with the first one.
But both the requests or instances should process independently.


myclass request2 = null
using (request2 = new myclass())
{
connection.open();

//process business rules

request2.close();


}


It would be a great help, if anyone take sometime to reply on this post. Thanks in advance
 
Back
Top Bottom