i mean do they give performance boost or speeds up the downloading time of the website.
No. Web service has nothing to do with speeding up downloading time.
Sangeeta J Singh
or similar like update panel???????
No, it is absolutely different from update panel.
Web service is about interoperability. Web services provides a SOAP protocol generally for discovery and usage of the service. Following this standard protocol, you can host a service and multiple clients can call your service. For example, you can
write a web service that produces the currency exchange rate related services. And clients can use your service from any standard language/platform to call your web methods and use them.
I guess, the confusion arose from the ASP.Net ajax and its web services. You can consume your web methods using asp.net ajax/javascript. However, this is just one of many ways to access your web service.
This is a very basic idea about web services. But, the bottom line is, web services and ajax/update panels are way different and you use web service to host a service (unlike a dynamic web page).
With UpdatePanel, it needs post back and retrieves the content related. UpdatePanel will be updated after responsed. In this way, the page needs build full request body to request to he server-side. The entire page life circle will be called.
With web service, JavaScript can call web service directly. It is more efficient and faster than by using normal postback. The minimun response text will be returned. However, After callback, you need build a callback function to update the related contents
and elements manually according to the returned text from web service. It is more complicated than using UpdatePanel when the updating process is complicated.
For example, if you want update a GridView by calling web service from Ajax. The performance is better than by using UpdatePanel. But updating content of GridView according to the callback result of web service is not a simple process.
If you have any feedback about my replies, please contact msdnmg@microsoft.com
Marked as answer by Vince Xu - MSFT on Apr 24, 2009 10:05 AM
By using webservices ur website performance will increase.. when u call webservices, it is done at client side.. postback is not going to occur coz u re doing it on client side...
Remember to click “Mark as Answer” on the post, if it helps you. Because It helps others to find the solution.
Sangeeta J S...
Member
240 Points
183 Posts
Advantage of webservices or webmethods
Apr 20, 2009 01:56 PM|LINK
Hi,
im using ajax in my web application and also want to user webservices which is also termed as web method
but im confused how does these webmethods helps? i mean do they give performance boost or speeds up the downloading time of the website.
Does it really increase the performance. or similar like update panel???????
if i dont call server method directly and call it from javascript what is the advantage post back is surely going to uccur na!
Please clear my doubts!!!
Sohan
Member
402 Points
66 Posts
Re: Advantage of webservices or webmethods
Apr 20, 2009 02:34 PM|LINK
No. Web service has nothing to do with speeding up downloading time.
No, it is absolutely different from update panel.
Web service is about interoperability. Web services provides a SOAP protocol generally for discovery and usage of the service. Following this standard protocol, you can host a service and multiple clients can call your service. For example, you can write a web service that produces the currency exchange rate related services. And clients can use your service from any standard language/platform to call your web methods and use them.
I guess, the confusion arose from the ASP.Net ajax and its web services. You can consume your web methods using asp.net ajax/javascript. However, this is just one of many ways to access your web service.
This is a very basic idea about web services. But, the bottom line is, web services and ajax/update panels are way different and you use web service to host a service (unlike a dynamic web page).
(Please, Mark as Answer if it Helped)
http://smsohan.blogspot.com
mrmercury
Star
8760 Points
1291 Posts
Re: Advantage of webservices or webmethods
Apr 20, 2009 02:51 PM|LINK
Since there are no postbacks when you use WebServices you do get a speed and performance advantage when you use WebServices instead of UpdatePanels.
Vince Xu - M...
All-Star
80367 Points
6801 Posts
Re: Advantage of webservices or webmethods
Apr 23, 2009 08:20 AM|LINK
Hi,
With UpdatePanel, it needs post back and retrieves the content related. UpdatePanel will be updated after responsed. In this way, the page needs build full request body to request to he server-side. The entire page life circle will be called.
With web service, JavaScript can call web service directly. It is more efficient and faster than by using normal postback. The minimun response text will be returned. However, After callback, you need build a callback function to update the related contents and elements manually according to the returned text from web service. It is more complicated than using UpdatePanel when the updating process is complicated.
For example, if you want update a GridView by calling web service from Ajax. The performance is better than by using UpdatePanel. But updating content of GridView according to the callback result of web service is not a simple process.
anup1252000
Contributor
3834 Points
698 Posts
Re: Advantage of webservices or webmethods
Apr 24, 2009 04:28 AM|LINK
By using webservices ur website performance will increase.. when u call webservices, it is done at client side.. postback is not going to occur coz u re doing it on client side...
Anup Hosur
HP
http://anup-anuphosur.blogspot.com/