unable to add a secure java web service to .net thru visual studio add web reference

I have a secure java web service running on my system.   I am able to successfully do a URL based invocation of it and also was able to get the expected SOAP response. It uses the Basic Authentication mechanism to make it secure. So basically when I type the URL in the address bar and invoke it, it asks me for a user name password, I enter it and it runs normally. 

Now, when I try to add that web service to a simple asp.net web application thru visual studio add web reference mechanism, it first prompts with a certificate, which I accept and then prompts with Discovery Credential window asking for username and  password and domain . No idea what the domain is.  so I enter just the username and password and leave that domain empty. 

Then it fails to add the web reference with the following :

There was an error downloading 'https://84q5tb1:7002/WebServices/security/transport/basicAuthentication/BasicAuthentication.jws'.

The underlying connection was closed: An unexpected error occurred on a receive.

Can you please help me with this situation. 

5/4/2007 3:48:20 PM
asp.net.xml-web-services 7071 articles. 0 followers. Follow

4 Replies

Similar Articles

[PageSpeed] 20

The web service itself isn't what the web reference mechanism wants. It wants the WSDL. You don't really need it when using .NET web services because .NET knows where to look for it, but if its in Java, you'll have to point the Add Web Reference tool to the WSDL address.


5/4/2007 4:00:51 PM

I did supply the WSDL to the add web reference from visual studio. 


But still, it fails and the following is the exact error message that is displayed. 

Unable to cast COM object of type 'System.__ComObject' to interface type 'EnvDTE.IVsExtensibility'. This operation failed because the QueryInterface call on the COM component for the interface with IID '{3C536122-57B1-46DE-AB34-ACC524140093}' failed due to the following error: No such interface supported (Exception from HRESULT: 0x80004002 (E_NOINTERFACE)).

5/6/2007 1:21:07 AM

Hi naween,

Here is a brief summary of this issue:

========PROBLEM DESCRIPTION===================

When try using the "Add Web Reference" function in Visual Studio 2005 to

create webservice client proxy against multiple webservice endpoints (asmx

files) in the same webservice application. And if the webservice

application is protected by client authentication which will prompt for

client to input credentials, the IDE will report the following exception:


Unable to cast COM object of type 'System.__ComObject' to interface type

'EnvDTE.IVsExtensibility'. This operation failed because the QueryInterface

call on the COM component for the interface with IID

'{3C536122-57B1-46DE-AB34-ACC524140093}' failed due to the following error:

No such interface supported (Exception from HRESULT: 0x80004002


========= CAUSE==========================

This is a pure Visual Studio 2005 specific issue, the interal design-time

COM object has problem when dealing with service endpoint that will prompt

for inputting client credentials.

==========CURRENT WORK AROUND =====================

1. Visit the service description/WSDL document in external webbrowser and

save the WSDL document to local file system.   And add web reference

against the local saved WSDL document in Visual Studio 2005.

2. Use the WSDL.exe command utility in .net framework to create webservice

client proxy externally. 

NOTE:If you find my response contains a reference to a third party World Wide Web site, I am providing this information as a convenience to you.Microsoft does not control these sites and has not tested any software or information found on these sites; therefore,Microsoft cannot make any representations regarding the quality,safety, or suitability of any software or information found there.

Young Fang
Microsoft Online Community Support

Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
5/10/2007 6:24:32 AM

Actually there is a much easier way to do this.  After adding one secure service, simply close the project, then re-open it and you can add another secured service, that fixed the problem for me.  If that doesn't work, just create the reference in another project and copy it over.

5/14/2008 1:43:17 PM

Similar Artilces:

Visual Studio .NET cannot create or open the application. The likeliest problem is that required components are not installed on the local Web server. Run Visual Studio .NET setup and add the Web Deve
I installed Visual Studio .NET 2003 on Windows Vista Home Premuim, but I'm unable to select "Web Development" item from "Server Components" during the installation. I installed all the pre-requisits but I can not see Front Page Server Extention in the programs. I can see also the IIS. Appreciate if any one can guide me with the solution.   Thanks.   FPSE is not included with Vista, it's a separate download.  See www.iis.net for this. JeffPlease: Don't forget to click "Mark as Answer" on the post that helped you. Tha...

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...

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...

.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...

Can "Add Web Reference" if web service deployed to new web site, Can't add ref if deployed to Virt Server under Default web site (Sharepoint)
I have created a web service wich I can deploy successfully to a new IIS Web, but of course I have to set the port to something other than 80 (and I'd rather just use a virtual server under the Default web). If I try to deploy my web service under the Default Web as a new virtual server, and then try to "Add a web Reference" to the service, it fails with a 404: not found error. Notes: WServer 2003 My IIS server is running Sharepoint Portal Server (SPPS)sp2.  VS2005 Any ideas? /Bob C in GRR In Sharepoint Portal Admin I had to add a Path Exclusion.  Took me a whi...

Difference in between add a web service as a Reference and as Web Reference?
I know the question is very stupid which i am going to asked but.... I have an asp.net web service project with a webservice, i can add this WebServiceProject as a Reference and get that webservice, but also can add the webservice as a WebReference in my application. what is difference in both and when which should be used?"Hope its your Solution so Mark it as Answer"Ahmad SheikhMicrosoft Valuable Geekhttp://sharpcontents.blogspot.com  You should always use Web Reference (or Service Reference) since only then will the necessary proxy code be generated.-- "Mark As Answer...

Error:Visual Studio .NET cannot create or open the application. The likeliest problem is that required components are not installed on the local Web server. Run Visual Studio .NET setup and add the We
Hi, I installed the IIS 5.0 after VS.Net 2003 (1.1). after that I did run the aspnet_regiis -i at the visual studio command prompt. I am able to run local web application created on my PC. But when I tried to copy an web application created at shared PC into the wwwroot folder, I get the following error while trying to open the project in VS.Net. I've created the virtual directory for the project and also set the integrated windows authentication under the directory security tab in the IIS. Please help me resolving the problem. Thank You.   Do you have FrontPage Server Ext...

Can't 'Add Web Reference' of Java AXIS Web Service!
Hi All, I'm trying to consume a web service written in AXIS, but am having serious issues. Namely, when I try to add it as web reference, I get to a web page that displays: "MyWebServiceName, Hi there, this is an AXIS service!, Perhaps there will be a form for invoking the service here... "  I do have wsdl file of the web service, however when I try to manually create the proxy I get several binding errors and the process fails. Also, the web service does not seem to accept POST as I always seem to be getting http 500 errors. At this point I have no idea what else to t...

Taking Web services development a small step further
Maybe some of you know that I am a big believer in contract-based Web services design and development. Web services contracts can be expressed explicitly in .NET code or by using schema (XSD) and WSDL. When using the second approach you may want a tool that can generate .NET code from your WSDLs/XSDs. The .NET Framework's and Visual Studio .NET's intrinsic tools somehow don't cut it, sorry. So, did you ever want to simply right-click on a WSDL file in Visual Studio .NET and generate code from that Web service contract? Now you can. New Features in v0.3 (compared to v0.2): -------...

Converting windows application using web service from Visual C#.net 2003 to Visual Studio.net 2005
Hello, everyone! I have a solution which contains a windows project,a web service project and several other library projects. These projects were coded under visual c#.net 2003. Now I need to converted them to use Visual Studo.net 2005. Does any one know any article providing step-by-step guide  to converting WINDOWS APPLICATION with web service? I can find one under MSDN for converting web project.  But I guess I am a little confused if mine should follow this article since I am using web service in my windows application? Thanks a lot in advance.  ...

What action by a web service requires an app to update their web reference to a Web Service
I create a web reference to a web service in my aspx web application which returns an XML object. If the owner of the web service makes a change to their object am I required to do an update web reference? What if I dont use the information from the new object? thanks Larry You should make the change only if the contract b/w the two has changed (e.g. parameters, return values), etc.-Mathew Nolton Website=www.cybral.com Email=mnolton@cybral.com Blog=weblogs.asp.net/mnolton If the web service now returns a new element and my class reference doesn't match their new class ref...

How to call .net web service from Java web application?
Hi all,  I have a vb .net web service.How do i call .net web service from Java web application?What all resources I need?Can you please provide a sample application where a java application is invoking methods of .net web service? Thank you Hi, First I am not familiar with java language, but web services are universal operating system and language independent. It doesn't matter where the services is or in what language is written you just invoke it  and it gives you "replay".  Probably you must reffer to java consuming web services.   Regard...

Add web reference in a web service client application
I created a simple web service client application, simply want to test a web service I created. First I add web reference, and my web service did show up in the list of web services available on my local computer. But after clicking on Add Reference button, there were no disco, map and wsdl files automatically generated. Reference was added, no error. but no other files were generated. I wonder if my .NET installation was a complete one. You have to try through Add WebReference (Not AddReference) and in that you have to provide your web servie URL and then add the reference!Sreedharhttp...

Can you return .net web controls in a .net page from a web service?
I've got a problem with a project. I've got to compile an entire .net page and return it as part of a Web Service for display. The problem I have is that I need to add WebControls and functionality to the page so that not only the html content and images are displayed (which I've managed) but that textboxes, labels, buttons and datasets can be displayed also. Essentially I need to make a call from one site for a page, populate the page and return it in a state as though it resided on the same server/webspace as the calling page. Code is currently built as follows into a string: strOpenHT...

Web resources about - unable to add a secure java web service to .net thru visual studio add web reference - asp.net.xml-web-services

Wikipedia talk:Reference desk/Guidelines/Medical advice - Wikipedia, the free encyclopedia
I disagree with this implication that this section of the guideline represents the consensus. If you look at the last few years of discussion ...

Microsoft dismisses iPad Pro as “a companion device” and references old Steve Jobs stylus quote
... to be a companion device.” Laycock also said that “at one point in time, Apple declared that if there’s a stylus, that’s failure” – a reference ...

New York Times Removes Reference to President Obama and Cable News
... — Noah Rothman (@NoahCRothman) December 18, 2015 The Times story was published Thursday, but by Friday morning, the reference to cable news ...

Can you spot these classic film references hidden in Pixar movies?
The animators at Pixar definitely love to throw in allusions to some of their favorite movies in their own films. Vimeo user Jorge Luengo Ruiz ...

10 hidden references to classic films in your favorite Pixar movies
... Madrid, told BuzzFeed that he noticed a ton of allusions in "Toy Story 3" and was inspired to make a video highlighting the cinematic references ...

See The Classic Movie References Found In Pixar's Greatest Films
... all well aware of just how clever Pixar movies are. These emotionally engaging stories are full of intricate themes and crammed with references ...

Zootopia Trailer Adds a Godfather Reference to Disney Film - Collider
Watch a new trailer for the Disney animated movie Zootopia, which takes place in a world inhabited by talking animals and features Jason Bateman ...

Hillary Clinton Ends Democratic Debate With A Star Wars Reference
The other day, President Obama ended his White House press conference with a reference to The [...]

Review: Klipsch X20i Reference In-Ear Headphones
These Klipsch X20i Reference In-Ear Headphones are pretty darn fantastic, and worth every penny.`

The Force Is Strong With This Sportscaster Who Drops ‘Star Wars’ References Like A Jedi
The Force Is Strong With This Sportscaster Who Drops ‘Star Wars’ References Like A Jedi

Resources last updated: 1/16/2016 3:47:10 PM