hi,
i am utilizing a web service in a C# windows application for a smart
client.
there is a method
[System.Web.Serv ices.Protocols. SoapDocumentMet hodAttribute("h ttp://kajol
.csse.monash.ed u.au/cse3211/ValidateUser",
RequestNamespac e="http://kajol.csse.mona sh.edu.au/cse3211",
ResponseNamespa ce="http://kajol.csse.mona sh.edu.au/cse3211",
Use=System.Web. Services.Descri ption.SoapBindi ngUse.Literal,
ParameterStyle= System.Web.Serv ices.Protocols. SoapParameterSt yle.Wrapped)
]
public int ValidateUser(st ring userName, string password) {
object[] results = this.Invoke("Va lidateUser", new object[]
{
userName,
password});
return ((int)(results[0]));
}
which works fine.....when i supply a user name and pwd..
but then there is this other method ;
[System.Web.Serv ices.Protocols. SoapDocumentMet hodAttribute("h ttp://kajol
.csse.monash.ed u.au/cse3211/GetMovies",
RequestNamespac e="http://kajol.csse.mona sh.edu.au/cse3211",
ResponseNamespa ce="http://kajol.csse.mona sh.edu.au/cse3211",
Use=System.Web. Services.Descri ption.SoapBindi ngUse.Literal,
ParameterStyle= System.Web.Serv ices.Protocols. SoapParameterSt yle.Wrapped)
]
public System.Data.Dat aSet GetMovies(int userID) {
object[] results = this.Invoke("Ge tMovies", new object[] {
userID});
return ((System.Data.D ataSet)(results[0]));
}
but whenever i supply the user id (196 or 129) to this it gives me error
saying
"The remote server returned an error : (403)
Forbidden"
but when i manually go to the site and enter the user id (196 or 129) i
dont get any error and i can see the data in XML format..
what i am trying to do in my code is to get the dataset returned by the
web-service method : "GetMovies" into a dataset so i do this :
DataSet ds = new System.Data.Dat aSet();
Users wsUsers = new Users();
ds = wsUsers.GetMovi es(129);
this is where i get the above mentioned error..
can anyone pls help????
tks a lot...
*** Sent via Developersdex
http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!