Calling A Web Services using Web Service Behavior
Recently I came across a client requirement, where I needed to fetch small
piece of data from a web service, and display it on a web form, without page
getting posted back.
The problem was resolved with the help of Web Behaviors. Web service
behaviors - also called as HTC - are reusable DHTML components that uses Web
Service to transfer SOAP data on HTTP. In this solution , web page gets small
is displayed on the web form in browser. All this happens without page being
The Code Download
The sample code available for download along with this article contains a web
service is returning latest DateTime. Note that we need to keep a file called
webservice.htc with the web form which uses the web service behavior.
Nitin Mekhiya is presently working with Cap gemini Consulting.Nitin has fascination for .Net technology and subjects like OOAD , Design patterns and software Architecture.