I am creating a web service in asp.net. I not getting which one is better way to manage multiple classes with web service.
Two way in my mind but i am not getting which one is better.
1) Call all classes in single .asmx file. 2) Create different .asmx file for all classes.
paypal.sandbox.AddressType addressType = new paypal.sandbox.AddressType();
addressType.AddressID = "Your Address ID";
paypal.sandbox.DoDirectPaymentResponseType response = new paypal.sandbox.DoDirectPaymentResponseType();
response.TransactionID = "25554d";
I want to call my classeslike this from my code behind. I am not getting this how can i call like thi开发者_如何学Cs. Please Help me out from this problem.
Thanks
You can add multiple webmethods in a asmx if they have the same purposes, call them in an orther class.
Group webmethods in asmx by functionnality. In this case, you can group methods before payment, and group methods after payment (responses).
精彩评论