I want to know how to call a web service from .aspx file I know one of the way <form action="hello.asmx/GetUsers" method="GET"> Its working fine. But I use runat=server for the form tag, it is not working Also please tell me some scenarios where I can use web
services thanks
phuoc, thanks But I have found out how to call a web service from codebehind file I have created web service in VS project, Just you have to import the webservice file Suppose my webservice file is hello.asmx imports projectname.hello dim objh as hello() objh.GetUser()
my question is, Right now I am returning data in array format How can I return a data fetched with help of query to the calling .aspx?
Can you make it more clear? Is your Web service is returning Array(Serialized XML)? and you are trying to get that data to your aspx end? Is that is your question? If that is the question, then how you are getting Array of data from Web Service. Can you explain
in detail, so that I can give suggestions to you!
sreedhark, 1. ::you are trying to get that data to your aspx end I think that's what mp417 is looking for. But you're right for asking a clarification to avoid any confusion.
mp417, 1. ::How can I return a data fetched with help of query to the calling .aspx? If I understand your question correctly, then see point 2. 2. Example from link. See it for more detail.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconconsumingdatasetfromwebservice.asp
[WebMethod( Description = "Returns Northwind Customers", EnableSession = false )] public DataSet GetCustomers() { SqlDataAdapter custDA = new SqlDataAdapter("SELECT CustomerID, CompanyName FROM Customers", nwindConn); DataSet custDS = new DataSet(); custDA.MissingSchemaAction
= MissingSchemaAction.AddWithKey; custDA.Fill(custDS, "Customers"); return custDS; }
Where there is a will, there is a way.
and where there is a team, there is more than one way.
Hi, Did you try to use some PROXY assembly for that? I think is the simplest way. If you use VS.NET there you shall set web reference, but if you WebMatrix you can use PROXY generator. In both ways it produces some assembly - PROXY namespace and class, which
can use developing your webpage. If everything is correct VS (or WebMatrix) does all you needed. Good luck Krzysztof
In my .ASPX I use web references like this http:\\xxxx\webservice\dataservice.asmx. But now I want to use Web matrix. How can I add a web references????
mp417
Contributor
2658 Points
549 Posts
Calling Web service from .aspx
Jul 29, 2003 02:13 PM|LINK
Phuoc
Participant
1150 Points
230 Posts
Re: Calling Web service from .aspx
Jul 29, 2003 03:40 PM|LINK
and where there is a team, there is more than one way.
mp417
Contributor
2658 Points
549 Posts
Re: Calling Web service from .aspx
Jul 30, 2003 05:21 AM|LINK
SreedharK
All-Star
18571 Points
3119 Posts
MVP
Re: Calling Web service from .aspx
Jul 30, 2003 11:36 AM|LINK
http://www.w3coder.org
weblog http://weblogs.asp.net/skoganti
Phuoc
Participant
1150 Points
230 Posts
Re: Calling Web service from .aspx
Jul 30, 2003 04:20 PM|LINK
and where there is a team, there is more than one way.
kmalinowski
Member
25 Points
5 Posts
Re: Calling Web service from .aspx
Aug 01, 2003 08:02 AM|LINK
hmendezm
Member
20 Points
11 Posts
Re: Calling Web service from .aspx
Aug 05, 2003 07:10 PM|LINK