Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8205327
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T08:11:40+00:00 2026-06-07T08:11:40+00:00

I am sending details to be stored in a database using a web service

  • 0

I am sending details to be stored in a database using a web service using KSOAP.This code was working perfectly before and I didn’t make any change to it. Now its not working. Please help. I checked the web service and it works. I have attached the log cat details. Please help !!!

public class Registration extends Activity{
private static final String SOAP_ACTION = "http://tempuri.org/register";
private static final String OPERATION_NAME = "register";
private static final String WSDL_TARGET_NAMESPACE = "http://tempuri.org/";
private static final String SOAP_ADDRESS = "http://10.0.2.2:54714/WebSite1/Service.asmx";
Button sqlRegister, sqlView;

EditText  sqlFirstName,sqlLastName,sqlEmail,sqlMobileNumber,sqlCurrentLocation,sqlUsername,sqlPassword;

@Override
protected void onCreate(Bundle savedInstanceState){
super.onCreate(savedInstanceState);
setContentView(R.layout.registration);
sqlFirstName = (EditText) findViewById(R.id.etFname);
sqlLastName = (EditText) findViewById(R.id.etLname);
sqlEmail = (EditText) findViewById(R.id.etEmail);
sqlMobileNumber = (EditText) findViewById(R.id.etPhone);
sqlCurrentLocation = (EditText) findViewById(R.id.etCurrentLoc);

sqlUsername = (EditText) findViewById(R.id.etUsername);
sqlPassword = (EditText) findViewById(R.id.etPwd);

sqlRegister = (Button) findViewById(R.id.bRegister);

sqlRegister.setOnClickListener(new View.OnClickListener() {

    public void onClick(View v) {
        switch (v.getId()){
        case R.id.bRegister:

                String firstname = sqlFirstName.getText().toString();
                String lastname = sqlLastName.getText().toString();
                String emailadd = sqlEmail.getText().toString();
                String number = sqlMobileNumber.getText().toString();
                String loc = sqlCurrentLocation.getText().toString();
                String uname = sqlUsername.getText().toString();
                String pwd = sqlPassword.getText().toString();

                SoapObject Request = new SoapObject(WSDL_TARGET_NAMESPACE,OPERATION_NAME);
                Request.addProperty("fname", String.valueOf(firstname));
                Request.addProperty("lname", String.valueOf(lastname));
                Request.addProperty("email", String.valueOf(emailadd));
                Request.addProperty("num", String.valueOf(number));
                Request.addProperty("loc", String.valueOf(loc));
                Request.addProperty("username", String.valueOf(uname));
                Request.addProperty("password", String.valueOf(pwd));
                Toast.makeText(Registration.this, "You have been registered Successfully", Toast.LENGTH_LONG).show();

                SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
                envelope.dotNet = true;
                envelope.setOutputSoapObject(Request);
                HttpTransportSE httpTransport  = new HttpTransportSE(SOAP_ADDRESS);
                try
                {
                    httpTransport.call(SOAP_ACTION, envelope);
                    SoapObject response = (SoapObject)envelope.getResponse();
                    int result =  Integer.parseInt(response.getProperty(0).toString());
                    if(result == '1'){
                        Toast.makeText(Registration.this, "You have been registered Successfully", Toast.LENGTH_LONG).show();
                    }
                    else
                    {
                        Toast.makeText(Registration.this, "Try Again", Toast.LENGTH_LONG).show();
                    }
                }
                catch(Exception e)
                {
                   e.printStackTrace();
                }

            break;
        }
           }
        });
    }

}

enter image description here

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T08:11:44+00:00Added an answer on June 7, 2026 at 8:11 am

    Pretty simple reason why you’re getting an Application Not Responding error: you are making the web request on the main (UI) thread. There are two rules to the Android threading model: 1) don’t block the main thread for more than a couple seconds 2) don’t update the UI from off of the main thread. You are violating the first of those rules. You should look into using AsyncTask to do your longer operations.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am sending details to be stored in a database using a web service
This is the jQuery code i'm using to send the form details to a
in my mysql cell this is stored using serialize function a:1:{i:0;s:275:a:4:{s:8:khghg_id;s:10:foo1187;s:3:uri;s:21:foo/vtory/1187;s:4:name;s:5:nmart;s:5:tuhlmb;a:3:{i:0;s:40:knuujhs/201205/13_03_pceb9.jpg;i:1;s:40:knuujhs/201205/13_03_0wlih.jpg;i:2;s:40:knuujhs/201205/13_03_tq5wf.jpg;}};} i am trying
I'm sending this request to my WCF webservice with a Android client using ksoap2:
Here are my code:- //Sending mail if ($this->Session->read('Enrollment.personalinfo_language') == 'English') { $language = english;
I've created a servlet for sending the exception or error details to the webmaster.
Sending XML from C# Server and receiving it it in Android Java client This
sending mail along with embedded image using asp.net I have already used following but
Sending Email in Android using JavaMail API without using the default/built-in app I'm trying
I have username and password of user stored in my database, like one time

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.