how to consume a .net webservice using java client ?

Hi experts,

I really need your help. I have create one .net webservice , it is really simple , the code is shown below .

  

    [WebService(Namespace = "http://tempuri.org/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    [ToolboxItem(false)]
    // To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line. 
    // [System.Web.Script.Services.ScriptService]
    public class Service1 : System.Web.Services.WebService
    {

        [WebMethod]
        public string HelloWorld()
        {
            return "Hello World";
        }
    }
 

Then , I type in url in browser "http://localhost:1031/Service1.asmx?WSDL" , and copy the content of wsdl file , paste it in Eclipse enviroment.

 

But when I want to generate stub Classes from the wsdl file , some error occurs, such as "the wsdl file is not valid" . Can anybody tell me why ? Or are there good articles I can learn from ?

 

Thank you very much.  

 

0
Jack19840827
10/10/2008 7:57:28 AM
asp.net.xml-web-services 7071 articles. 0 followers. Follow

1 Replies
538 Views

Similar Articles

[PageSpeed] 36

There would be no way for us to tell what the problem is from your description. Is that the entire message that Eclipse gave you?

Also, I'm sure there's a way to do the equivalent of "Add Web Reference" in Eclipse. I have used IBM Rational Web Developer in the past, and it is based on Eclipse. It had a way to create a web service client that required me to type in the URL to the WSDL, and it just worked.


John Saunders | MVP – Connected System Developer
0
johnwsaunders3
10/10/2008 1:46:16 PM
Reply:

Similar Artilces:

problem in using java web services from .net client
I am trying to make a .net client for a java web service made using JAX-WS 2.0 . Actually the web service maintains session of the client. Well i did create a client from java and it worked. But i am having problem in consuming the web service from .net client. According to the specification of that web service i have to set the SESSION_MAINTAIN_PROPERTY of the BindingProvider true to indicate whether or not the client wants to participate in session with service endpoint. It is done in java client in following way:Hello proxy = new HelloService()...

Issue with clients consuming a web service that was upgraded from .NET 1.1 to .NET 3.5
I am currently working with an application that was converted from Visual Studio 2003 to Visual Studio 2008 and we are having issues with a client consuming the web service portion of the application.  The web services were written in .NET 1.1 using the Web Services Enhancements 2.0 and was upgraded to use the .NET 3.5 framework.  One of our clients application, which is still written in .NET 1.1 was reference the upgraded web service and tried to consume the web service and received the following error: System.Web.Services.Protocols.SoapException: Se...

How to call a .net web service from another .net web service?
Hi all,I have developed two asp .net web services using visual studio .net 2003.I wish to call one web service from another web service.I tried adding a web reference of the web service in another web service and was able to do so.but i m not able to access the web methods provided by the web servicecould you please suggest a way to go about itExpecting quick replyThanxCharmy try to make sure that you reference it in the web reference and call it properly this is sample  [WebMethod()] public double CalcDistance(int x1, int y1, int x2, int y2) { Calculator.Service1 calc = new...

Web service in .NET from Java Web Service
Hi there,I'm pretty new to .net (although i have years of experience with the old vb 6, access 2k, as well as java)... and need some with perhaps either some syntax or something.Here is the wsdl.<wsdl:definitions targetNamespace="http://www.dynix.com/schema/book">−<wsdl:types>−<schema targetNamespace="GetBookInfoByISBN">−<complexType name="BookInfoType">−<sequence><element maxOccurs="1" minOccurs="0" name="Title" nillable="true" type="xsd:string"/><element maxOccurs=&quo...

Consuming a .NET web service in Delphi 2010 using a service reference
Hi, I've been asked to modify one of my existing applications (D2010 Win32) to interact with a web service written under VS2010/.Net 4. The information I have so far is :- "As communication is secured by .NET WsHttpBinding data encrypting, In order to consume it you have to add to your application a Service Reference (not a web reference) that joins the service available at the URL: http://ctm.mobilling.it/SmsComApi/Sms.svc . Assuming that the binding created in your app.confing is named "WSHttpBinding_ISms" you have to instantiate a client as shown below: {c...

Consuming Web service from .net 3.5 web application using ajax
Hi , Before in .net 2005 ,I use to consume the  web service from client side via Ajax and java script. that's just adding web service inside the script manger services.But  it was not possible with .net 2008 version WEB APPLICATION   , Even it works well with .net 2008 web sites. Please help me to solve the issue. I have no idea what you mean. Please post the code that "does not work". NC...   I have the same problem.  I have a .NET 3.5 Web Application not Web Site.  I fully qualify the web service with the namespace i,e,  &n...

.NET CLIENT TO ACCESS a non. NET WEB SERVICE
I develop in .net and need to create a web client to connect to a web service built in Java. http://xchainj.com:8080/axis/services/ScsEnvirodatWaterQualityIndexServiceSoap Its pretty easy when the web service was also built in .net. You can just create a web reference with the gui and automatically can see its functions and stuff. when i put this url in the box and hit go i dont get to see its functions. maybe this shouldnt be the url of the WSDL?? I Have no idea. Im very new to all of this. If there are any examples of .net clients connecting to non .net web clients it woul...

.NET web services Vs Java Web Services
Hello, does anyone know of a book or good source of information that compares .NET and Java Web Services? (I would like soemthing neutral if possible). I am thinking of approaching this subject for my dissertation? Many Thanks Rob Hi Rob, Last year I had to give a powepoint presentation on Web Services. I noticed some good books at barnes and noble that discussed the subject. These books were specific to Java and discussed Web Services in a very clear fashion. They gave some elementary examples that were easy to understand. I have not yet had the pleasure of creatin .NET Web Servi...

Consuming Java web service from .Net
Hi, I have a question, somebody with exposure please answer. I need to call a JAVA webservice from C# (VS.6 & SOAP tool kit or VS.net). The Java webservice has been deployed on SOAP RPC Router .I got a copy of the WSDL published from the WebService provider, then I am trying to create a proxy class from the WSDL. I have seen that there are some bugs on initial version of the .Net Framework so I have installed SP1 for .net Frame work with latest version and service pack for WSE (version 2 SP3). then I Tried to compile the proxy but getting error from WSDL.exe This is the command I am ...

Client .NET Web Service Java
 Hi, I am reading some docs about Web Services and I have some questions,  1) If I have a Web service wrote in Java, Can I use it from a asp or a Windows form??2) If It's not possible, and the webservice only have to recive 2 parameters (for instance add(int a, int b)) can I write myself the SOAP message and pass it to the Java WebService?? I'm not sure about all of this, because to make a client for a webservice you only have to know what parameters are needed. Thanx for your help! Please remember to click “Mark as Answer” on the post that helps you, and to click...

Cannot call a web service from java script using ajax in .net 3.5 web applications
As like 2005 .net websites i tried to consume a web service from client side java script  using Ajax script manager in  .net 3.5 (2008) version web application it was not working, Event it works with 3.5 web sites, What i have to do to solve the issue. Thanks in advance Hi, can you create the least amount of code to reproduce it and post it? This gives us the ability to check out your code and better guide you. Also please check out this article: Create a Simple WCF Web Service and Use In JavaScript With Visual Studio 2008 and .Net 3.5.  Grz, Kris.Read my blog. Handy Fire...

What do non-.net users need to do to consume a .net web service?
Hello, I'm very new to web service world and haven't had much chance to do much reading on theory and architecture yet. So I'm asked to create one for someone external to my organization (still inside my company). I make one, test it, deploy it, consume it. Go me. It was very easy within my comfortable .net shop. However, the intended consumer is not a .Net shop (J2EE). I was under the impression that if I sent in a GET request to the asmx file, I would get XML back. This turned out to be not the case and I had to use the proxy file to prove that I could consume the service. S...

what are the steps in consuming java webservice from .net client
Hi, I am tyring to consume a java webservice from .net client and I am not sure how to proceed with that. Any kind of help on this is appreciated. Thanks Srinivasa. adding a webreference to a java webservice is no different then one for a .net webservice simply add a webreference and the proxy class will be generated within your .net client application. -Mathew Nolton-Mathew Nolton Website=www.cybral.com Email=mnolton@cybral.com Blog=weblogs.asp.net/mnolton...

Difficulties Consuming Java Web Services in .NET
I am consuming Java Web Services in .NET. The Java Web Services have been coded using Apache Axis. The binding style in the WSDL is 'Document' and type is 'Literal'. I have added these Java Web Services both as Web Reference and Reference (ie dll generated using wsdl.exe) in the Project in order to access them. I am able to get the output for web methods that return just a string. However when it comes to complex data like an object / array , it returns me an object with empty attribute values. I have tried posting the XML Content to the Web Services using XML Spy and it seems to wo...

Web resources about - how to consume a .net webservice using java client ? - asp.net.xml-web-services

webservices Articles, Posts, Blogs, Videos - Technorati
— Authority: The job consist in a PHP program that read a file, compose a message (email or sms) and call an API of email provider (Amazon SES) ...

Section: software:webservices
Wired.com © 2012 Condé Nast. All rights reserved. Use of this Site constitutes acceptance of our User Agreement (effective 3/21/12) and Privacy ...

Products - CrunchBase
Product profiles

App Search on Flickr - Application Sharing!
Flickr is almost certainly the best online photo management and sharing application in the world. Show off your favorite photos and videos to ...

Wikipedia:Press coverage 2005 - Wikipedia, the free encyclopedia
If you add an article, please cite both the title and the source. Note that if you're listing an article from a traditional press wire service ...

Entity–relationship model - Wikipedia, the free encyclopedia
In software engineering , an entity-relationship model ( ER model for short) is an abstract and conceptual representation of data . Entity-relationship ...

Entity-relationship model - Wikipedia, the free encyclopedia
In software engineering , an entity-relationship model ( ER model for short) is an abstract and conceptual representation of data . Entity-relationship ...

IT and Telecommunications Jobs in Melbourne Metro - MyCareer
Find IT and Telecommunications Jobs in Melbourne Metro on MyCareer. Fresh IT and Telecommunications Jobs posted daily. Free email alerts and ...

AWS Elastic Beanstalk: A Quick and Simple Way into the Cloud
Flexibility is one of the key principles of Amazon WebServices - developers can select any programming language and software package,any operating ...

How To Use the Amazon SDK for Android to Upload Photos to Amazon S3
This article demonstrates how to use the AWS SDK for Android to upload an image to Amazon Simple Storage Service (S3) from your mobile device ...

Resources last updated: 12/1/2015 1:31:10 AM