By default asp.net web services use soap for communication scriptservice marker make your webservice to use JASON.
1 2 3 4 5
That’s it now lets move to client side code.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
In above javasrcipt code we are making an ajax post request we set contentType to “application/json; charset=utf-8” and dataType to “json” and passing a=1,b=2 as are data input parameters note that varriables name are same as verriables declared in webservice’s function AddingNumbers input parameters.
Please read articles from following links to know more and have a strong background.