mdmohideen
Programmer
Hi,
I am working on creating a webservice in C#. Here is a scenario(sample code) of what I am trying to accomplish.
public class Customer {
public int id;
public string name;
public ArrayList list = new ArrayList(); //list for orders of a customer
}
public class Orders{
public int id;
public string orderno;
}
public class Service1{
[WebMethod]
public Customer getCustomerAndOrders(int customerId){
return customer;
}
}
The getCustomerAndOrders(..) method should return customer object along with list of Orders(ArrayList). The problem lies in returning the list along with the customer object.
I would appreciate your help.
Thanks,
-M
I am working on creating a webservice in C#. Here is a scenario(sample code) of what I am trying to accomplish.
public class Customer {
public int id;
public string name;
public ArrayList list = new ArrayList(); //list for orders of a customer
}
public class Orders{
public int id;
public string orderno;
}
public class Service1{
[WebMethod]
public Customer getCustomerAndOrders(int customerId){
return customer;
}
}
The getCustomerAndOrders(..) method should return customer object along with list of Orders(ArrayList). The problem lies in returning the list along with the customer object.
I would appreciate your help.
Thanks,
-M