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 7038191
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T01:38:22+00:00 2026-05-28T01:38:22+00:00

I am unable to save values into my webserver which is in .net. i

  • 0

I am unable to save values into my webserver which is in .net. i have use the following code but i got the follow in error in emulator..i.e..,

Server was unable to process request---> cannot insert the value null into column 'Name', table 'MyWorldApp.dbo.tbl_UserRegistration';column doesnot allow nulls.INSERT fails. The Statement has been terminated.

i have use the following link: http://113.193.181.53/MyWorldApp/Service1.asmx?op=InsertUsertRegistrationDetails

my code is:

import org.ksoap2.SoapEnvelope;
import org.ksoap2.serialization.SoapObject;
import org.ksoap2.serialization.SoapSerializationEnvelope;
import org.ksoap2.transport.HttpTransportSE;
import android.app.*;
    import android.os.*;
    import android.util.Log;
    import android.widget.TextView;

    public class MyworldActivity extends Activity {
        /** Called when the activity is first created. */

        private static final String SOAP_ACTION = "http://localhost/service1/InsertUsertRegistrationDetails";

        private static final String METHOD_NAME = "POST";

        private static final String NAMESPACE = "http://localhost/service1";
        private static final String URL = "http://113.193.181.53/MyWorldApp/Service1.asmx";



        TextView tv;

        @Override
        public void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            setContentView(R.layout.main);
            tv=(TextView)findViewById(R.id.text1);
            call();

        }

        public void call()
        {
            try {

                SoapObject request = new SoapObject(NAMESPACE, METHOD_NAME);

                request.addProperty("Name", "'Rajapandian'");
                request.addProperty("UserName", "Rajapandian");
                request.addProperty("Password", "123");
                request.addProperty("MobileNumber", "456");
                request.addProperty("EmailID", "Rajapandian@gmail.com");
                request.addProperty("image", "http://www.thehindu.com/multimedia/dynamic/00880/INDIA_CORRUPTION_PR_880168f.jpg");
                Log.e("success","success");
                SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
                envelope.dotNet=true;
                envelope.setOutputSoapObject(request);

                HttpTransportSE androidHttpTransport = new HttpTransportSE(URL);
                androidHttpTransport.call(SOAP_ACTION, envelope);

                Object result = (Object)envelope.getResponse();

                tv.setText(result.toString());
            } catch (Exception e) {
                tv.setText(e.getMessage());
                }
        }
    }

can anyone tell me where i have done wrong..

thanks in advance..

  • 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-05-28T01:38:22+00:00Added an answer on May 28, 2026 at 1:38 am

    here is the solution,
    in this example i have use get method.just pass your variable in url string

    String url = "http://113.193.181.53/MyWorldApp/Service1.asmx/InsertUsertRegistrationDetails?Name=string&UserName=string&Password=string&MobileNumber=string&EmailID=string&image=string"
    
    URL sourceUrl = new URL(url);
                SAXParserFactory spf = SAXParserFactory.newInstance();
                SAXParser sp = spf.newSAXParser();
                XMLReader xr = sp.getXMLReader();
                Handler1 dataHandler = new Handler1();
                xr.setContentHandler(dataHandler);
                xr.parse(new InputSource(sourceUrl.openStream()));
                Dataset dataset = dataHandler.getParsednewJobdtl_DataSet();
    

    Dataset :

    package com.RecordingApp;
    
    public class AuthDataset {
    
    
    
        private String booleanx = null;
    
        public void setbooleanx (String booleanx ) {
            this.booleanx = booleanx ;
        }
    
        public String getbooleanx () {
            return booleanx ;
        }
    
    
    }
    

    Handler:

    package com.RecordingApp;
    
    import java.util.ArrayList;
    
    import org.xml.sax.Attributes;
    import org.xml.sax.SAXException;
    import org.xml.sax.helpers.DefaultHandler;
    
    public class AuthHandler extends DefaultHandler {
        boolean int1 = false;
    
        ArrayList ar1 = new ArrayList();
    
        ArrayList br1 = new ArrayList();
    
        private AuthDataset mysitelist = new AuthDataset();
    
        public AuthDataset getParsednewJobdtl_DataSet() {
            return this.mysitelist;
        }
    
        public void startDocument() throws SAXException {
            this.mysitelist = new AuthDataset();
        }
    
        @Override
        public void endDocument() throws SAXException {
        }
    
        // ***********************Start Element********************
        @Override
        public void startElement(String namespaceURI, String localName,
                String qName, Attributes atts) throws SAXException {
            if (localName.equals("boolean ")) {
                this.int1 = true;
            }
    
        }
    
        // ***********************End element********************
        @Override
        public void endElement(String namespaceURI, String localName, String qName)
                throws SAXException {
            if (localName.equals("boolean ")) {
                this.int1 = false;
    
            }
        }
    
        // ***********************character********************
        @Override
        public void characters(char ch[], int start, int length) {
            if (this.int1) {
                mysitelist.setbooleanx(new String(ch, start, length));
                ar1.add(new String(ch, start, length));
                setbooleanx (ar1);
    
            }
    
        }
    
        public void setbooleanx (ArrayList ar1) {
            this.br1 = ar1;
        }
        public ArrayList getbooleanx () {
    
            return br1;
        }
    
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a custom configuration file in my asp.net website, named urls.config , which
in Python 2.6.5 with sqlite3.version 2.4.1, I use the following code: c = conn.cursor()
I have following html: <label for=live>Live</label> <input type=checkbox name=live id=live /> How to save
I am unable to create a table and insert the values into it using
Am using Shared server. I can save external images using curl. But am unable
Error: Unable to read data from the transport connection: A blocking operation was interrupted
I have been unable to receive UDP multicast under VxWorks 5.5. I've joined the
I have been unable to trigger an onselect event handler attached to a <div>
Let's say we have the following XML document: <root> <options> ... </options> <children> <child
Based on the following code... A user can come along and add as many

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.