Comment on Tutorial - Web services basics By Saravanan D. Rao



Comment Added by : Anup

Comment Added at : 2013-01-02 05:11:51

Comment on Tutorial : Web services basics By Saravanan D. Rao
Getting Invalid IPv4 format J2me Midp 2.0, Asp.net version 4.0, Ksoap2-j2me-core2.1.2 . Iâm using CLDC 1.1 MIDP2.0 and IIS7 Asp.net version 4.0 . My code is as followsâ¦

public String loginVerification(String userId, String pwd){
String Method_Name = âmLoginâ;
//String Method_Name = âLoginCheckâ;
try{
SoapObject request = new SoapObject(Constants.NAMESPACE_URL, Method_Name);
request.addProperty(âuseridâ, userId);
request.addProperty(âpasswordâ, pwd);
SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
envelope.dotNet = true;
envelope.setOutputSoapObject(request);
HttpTransport ht = new HttpTransport(Constants.LOGIN_URL);
ht.debug = true;
ht.call(Constants.NAMESPACE_URL+Method_Name, envelope); // getting error here
SoapPrimitive result = (SoapPrimitive) envelope.getResponse();
return result.toString();
}catch(IOException e){
return e.getMessage().toString();
}catch(XmlPullParserException e){
return e.getMessage().toString();
}

}

web service is as followsâ¦

[WebMethod]
public string mLogin(string userid, string password)
{
string message = string.Empty;
CommonDataEntity cd = new CommonDataEntity();
sqlfilter filter = new sqlfilter();
int retVal=cd.Select_CustomerLogin(filter.SqFilter(userid), filter.SqFilter(password), out message);

if (retVal > 0 && message == âUserâ)
{

return âtrue#â+cd.mLogin(userid);

}
else
{
return âfalse#â+userid;
}

}

Iâm not able to figure out where and what is the probâ¦. Need help!!


View Tutorial



Ask a Question

Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. site is very good explanation is very clear throug
View Tutorial          By: sridevi at 2013-03-20 15:26:29

2. import gnu.io.*;
import java.io.*;
<

View Tutorial          By: Anonymous at 2013-03-29 02:39:00

3. Very good example .!
Ty

View Tutorial          By: Mprogrammer at 2014-11-25 12:10:21

4. Thanks a lot for your tutorial.
(: It was v

View Tutorial          By: Nevermore at 2011-08-03 10:39:32

5. 3221225477 is C0000005 in hex notation, which is j
View Tutorial          By: Stan at 2009-06-29 12:14:25

6. Thanks sir
View Tutorial          By: sivaraj at 2013-01-23 05:43:35

7. I hope so.:d
View Tutorial          By: khoa at 2008-06-10 04:18:31

8. Sir if i wnna to take the input from user then it
View Tutorial          By: Vivek at 2011-05-14 05:56:30

9. i like java but java many program are confused i a
View Tutorial          By: savaliya hardik at 2012-09-11 03:30:10

10. when iam trying to executing above program i am ge
View Tutorial          By: BHAGYALAXMI at 2008-10-11 06:45:57