• Upgrade your Internet Experience
  • Sign in
  • Microsoft.com
  • United States (English)
    Brasil (Português)Česká republika (Čeština)Deutschland (Deutsch)España (Español)France (Français)Italia (Italiano)Россия (Русский)대한민국 (한국어)中华人民共和国 (中文)台灣 (中文)日本 (日本語)香港特别行政區 (中文)
 
 
.NET Framework Developer Center
 
 
Home
 
 
Library
 
 
Learn
 
 
Downloads
 
 
Support
 
 
Community
 
 
Forums
 
 
 
.NET Framework Developer Center > .NET Development Forums > ASMX Web Services and XML Serialization > WSE 3.0 and Visual Studio 2008?
Ask a questionAsk a question
Search Forums:
  • Search ASMX Web Services and XML Serialization Forum Search ASMX Web Services and XML Serialization Forum
  • Search All .NET Development Forums Search All .NET Development Forums
  • Search All MSDN Forums Search All MSDN Forums
 

AnswerWSE 3.0 and Visual Studio 2008?

  • Thursday, November 29, 2007 7:38 PMEmmanuel Huna Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0

    So I downloaded and installed Visual Studio 2008 RTM.  I was able to upgrade all of my projects without problems, except for a client app that uses WSE 3.0.

     

    It refuses to build under Visual Studio 2008 - there were errors related to the web reference objects.  I updated the web references from VS 2008 and now the WSE 3.0 objects are gone.

     

    I googled and searched the MSDN forums, but the only thread I found was this one:

     

      http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2476455&SiteID=1

     

    where someone asks about WSE 3.0 support under VS 2008.  Unfortunately, there's no response.

     

    What should developers that are using WSE 3.0 do if they upgrade to Visual Studio 2008? 

     

    1) Is there a way to have support for the WSE 3.0 configuration tools within the VS 2008 IDE? (right click on project and choose WSE 3.0 settings)

     

    2) If not, is there anyway I could re-read the WSDL and create my WSE objects through a command line prompt if my project was upgraded to Visual Studio 2008?  Can someone point me to documentation and examples?

     

    It cracks me up that Microsoft is comitted to backwards compatibility for MFC, but WSE seems to never work with the latest version of Visual Studio.  I had the same problem when I upgraded to Visual Studio 2005 and was using WSE 2.0.  I had to wait and upgrade to WSE 3.0 to get the tools in the IDE.

    • ReplyReply
    • QuoteQuote
     

Answers

  • Tuesday, December 04, 2007 6:35 PMSidd Shenoy - MSFTModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer
    Vote As Helpful
    0

    Hi Emmanuel,

     

    WSE 3.0 is not supported in VS 2008. This would require a Service Pack to be released for WSE and currently the WSE team has no future Service Packs planned.

     

    The question then stands, what do developers do. I'll answer your questions above and hopefully that might help a bit:

     

    1. Currently no, there is no supported way of doing this. VS 2008 just released and WSE 3.0 released a while back. Is there anything in particular that you use in the configuration tool? Everything that is done through the configuration tool can be done manually by updating your web.config file.

     

    2. Re-reading your WSE used to work with "Add Web Reference" in VS 2005. However, under the covers, what is really happning is that wsdl.exe is being run against the service's wsdl, and the base class changes from SoapHttpProtocol to WebServicesClientProtocol. So that's all you have to do:

       a) Run wsdl.exe against the service's wsdl file

       b) Change the base class that your proxy inherits from, from SoapHttpClientProtocol to

           WebServicesClientProtocol

     

    WSE 3.0 does not have any future releases planned and people should really be thinking about upgrading their stack to WCF. Migration from WSE to WCF isn't all that difficult and there is literature to help with that. You can find out more about WCF at www.netfx3.com.

     

    If there are any specific questions regarding migration that you want to ask, please let me know.

     

    Thanks,

    Sidd [MSFT]

     

    • ReplyReply
    • QuoteQuote
     

All Replies

  • Thursday, November 29, 2007 8:41 PMEmmanuel Huna Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0

    Ok, I found a fairly easy workaround to have the web references with WSE 3.0 updated and working in VS 2008:

     

    1) Create a new project in VS 2005. Name it exactly the same as the VS 2008 project

      a. In my case: “MYPROJECT”.

     

    2) Add a web reference to the web service with WSE 3.0 support.

      a. In my case: https://www.MYURL.com/MYSERVICE/MYASMX.asmx

     

    3) Right click on the project and choose > WSE 3.0 Settings > Enable this project for Web Services Enhancements.

     

    4) Update your web reference – this will create the WSE 3.0 classes and objects

      a. In my case: MYSERVICE.MYASMXWse

     

    5) Copy all of the files from the VS 2005 project to the VS 2008 project:

      a. In my case:

        i. From: C:\Projects\Misc\Projects\Vs2005Client\MYCLIENT\Web References\MYSERVICE

        ii. To: C:\Projects\MYCLIENT\main\Web References\MYSERVICE

     

    6) Exclude all previous files in the VS 2008 project and include the new ones.

      a. In my case: in the new VS 2008 project, refresh and include all files in MYCLIENT > Web References > MYSERVICE

     

    7) If you get an error on the default URL coming from “My Settings”, update it.

      a. In my case: Me.Url = My.Settings.MYCLIENT_MYSERVICE_MYASMX

     

    Hope this helps someone else, but if anyone from Microsoft reads this my question still stands: can we get WSE 3.0 support in VS 2008?

    • ReplyReply
    • QuoteQuote
     
  • Monday, December 03, 2007 10:16 PMahsteele2 Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0
    While this solution is definietly workable it is far from ideal.  I will be putting a watch on this thread to see if anyone from Microsoft replies to you.  Thank you for posting your workaround I will be utilizing it.
    • ReplyReply
    • QuoteQuote
     
  • Tuesday, December 04, 2007 7:29 AMAndreas Hammar Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0
    Couldn't agree more, I guess that they want us to be using WCF - but you can't do all transitions at the same time!

    Our workaround is doing a postbuild-replace of the class/constructor in the proxy project (we have a separate project just for the proxy):


    With regex, in reference.cs:

    "class.*Service .*\{"         to       class ServiceWse : Microsoft.Web.Services3.WebServicesClientProtocol {

    and

    "public Service\(.*\{"          to       public ServiceWse() {


    This will yield no non-wse proxy, just a wse one, but we don't need the non-wse.


    Looking forward to integrated tools!



    • ReplyReply
    • QuoteQuote
     
  • Friday, January 04, 2008 10:20 PMBrandonW Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0
    That is somewhat disheartening. I have tried to adopt WCF right off the bat on a new project, but after spending hours and hours knocking my head against the wall, I have decided to go back to the simple and easy to set up ASP.NET web services.

    It's nice that there is an easy conversion route from ASP.NET web services to WCF services, except that no matter what conversion path you decide on, if you include credentials in the requests, you need to include certificates in the workflow to secure the sensitive data... and if you use certificates, then you are doomed to fail.

    I have searched high and low through hundreds of blog postsings and forums, and it appears that either Microsoft doesn't want you to use certificates, or wants you to become brain dead before you use them. It seems all but impossible to create a test certificate that works for development. Since this was not feasible in a reasonable amount of time (I could have lived with weeks, but not even that was enough), I must try another path because the WCF path was going nowhere very fast.

    If I read your post correctly, it seems that one can still use WSE with VS 2008, as long as it is all done through the command line. Is this correct? If it isn't even usable that way then I'm going to have to decide on another technology stack because ASP.NET / WCF just doesn't seem very usable at the moment.
    • ReplyReply
    • QuoteQuote
     
  • Wednesday, January 23, 2008 11:24 AMMattaniah Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0

    Unfortunately I am forced to use vs 2005 for web part projects on SharePoint.  I like the one click to deploy web part.  Hopefully MS will give us some way in the near future.

     

     

    • ReplyReply
    • QuoteQuote
     
  • Thursday, January 24, 2008 10:54 PMBidware.com Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0

     



    I figured out exactly how to use WSE 3.0 with VS2008. You must use the old .cs or .vb files with your proxy or web reference files (They are in the same directory as your .wsdl files.) So, once VS 2008 finishes converting your VS 2005 to VS 2008, it will overwrite your existing reference.cs file (in my case) with the wrong base class (SoapHttpClientProtocol instead of WebServicesClientProtocol.) So, you can either manually modify your reference.cs files to use WebServicesClientProtocol, or simply copy your old .cs files from your working VS2005 project directory. It should compile and run after that. Contact me at chris@bidware.com should you have any questions.
    • ReplyReply
    • QuoteQuote
     
  • Thursday, January 24, 2008 11:18 PMBrandonW Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0
    I've gotten it to work with VS2008 alone too. You must use the GUI tool that is installed with WSE 3.0 to configure the app.config or web.config of the project (you can find a good amount of documentation on that on the net). Then you must go into a service reference's auto generated code (remember to make a old web reference, not a new service reference), and change the main web service client class so that it derives from The Protocol class in the Microsoft.Web.Services3 namespace (I forget the exact name). Once you do this, you will get access to all of the inherited properties, and it works fine.
    • ReplyReply
    • QuoteQuote
     
  • Thursday, January 24, 2008 11:27 PMBidware.com Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0

    Actually, you never need to use any GUI at all.  It's just a matter of using the old references to WSE.  It's that simple.

    • ReplyReply
    • QuoteQuote
     
  • Thursday, January 24, 2008 11:57 PMBrandonW Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0
    Sorry. I forgot to mention that my post was from the stand point of a person who isn't using VS 2005 at all (as in not even upgrading the original references).
    • ReplyReply
    • QuoteQuote
     
  • Tuesday, February 12, 2008 12:25 PMAlienationZombie Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0

     BrandonW wrote:
    I've gotten it to work with VS2008 alone too. You must use the GUI tool that is installed with WSE 3.0 to configure the app.config or web.config of the project (you can find a good amount of documentation on that on the net). Then you must go into a service reference's auto generated code (remember to make a old web reference, not a new service reference), and change the main web service client class so that it derives from The Protocol class in the Microsoft.Web.Services3 namespace (I forget the exact name). Once you do this, you will get access to all of the inherited properties, and it works fine.

     

    Thanx for the suggestion!

    It works great!

    It saved me the time of trying to figure this out.

    • ReplyReply
    • QuoteQuote
     
  • Monday, February 25, 2008 2:08 PMSilvero van Henningen Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0

    Thnx,

    Finally my client-app (VS2008) works with MTOM (WSE 3.0).

     

    I only had to replace (in Reference.cs)

    public partial class wsMTOM : System.Web.Services.Protocols.SoapHttpClientProtocol

    in

    public partial class wsMTOM : Microsoft.Web.Services3.WebServicesClientProtocol

     

    • ReplyReply
    • QuoteQuote
     
  • Friday, May 02, 2008 8:51 AMPK_Sean Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0

    There is a very simple solution if you can change the Target Framework of your application to 3.0 or 3.5:

     

    You simply need to delete the "Web Reference" from your application and then re-add the web service as a "Service Reference".  This should automatically configure your client to use the WSE settings.  The only other change you will need to make to your code is the proxy reference which will need to instantiate as <webservice name>Client instead of <webservice name>

     

    If you must remain at Framework 2.0, then the above solutions must be considered.

     

    • ReplyReply
    • QuoteQuote
     
  • Thursday, August 21, 2008 3:44 PMredluv Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0
    Dear Microsoft,

    I have been contracted to develop a small web application that interfaces with a Java-based web service written by IBM.  Of course I am using ASP.NET.  The client would prefer .NET 3.0.  My problem is that the web service I am consuming uses DIME attachments.  Therefore I must use WSE2 which is not supported with VS2008.  I understand DIME is outdated, obsolete, whatever.  But why not keep support for old time's sake?  Now I must revert to VS2005 for development.  Very disappointing.

    -Redluv
    • ReplyReply
    • QuoteQuote
     
  • Thursday, August 21, 2008 4:51 PMJohn SaundersMVP, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0
    Did you consider using WCF?
    John Saunders | Use File->New Project to create Web Service Projects
    • ReplyReply
    • QuoteQuote
     
  • Friday, August 29, 2008 1:18 PMbijay Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0
    We are currently running both version  WSE 3.0 and WCF with VS 2005 due to diverse clients needs. Not all are ready with WCF. We are upgrading to VS 2008 and have the same problem.

    Is there way to customize that WSE Proxy creation ? Or any other ideas other than replacing the inherit class manually.
    • Edited bybijay Friday, August 29, 2008 1:19 PMtypo
    •  
    • ReplyReply
    • QuoteQuote
     
  • Friday, August 29, 2008 4:14 PMbijay Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0
    Can you please  tell me how you are doing this as post-build action ?
    • ReplyReply
    • QuoteQuote
     
  • Friday, October 03, 2008 8:21 PMJason Young _iMeta_ Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Proposed Answer
    Vote As Helpful
    0
    Check out http://blogs.imeta.co.uk/jyoung/archive/2008/08/29/345.aspx for a solution to using WSE 3 in VS 2008
    • Proposed As Answer byJason Young _iMeta_ Friday, October 03, 2008 8:22 PM
    •  
    • ReplyReply
    • QuoteQuote
     
  • Tuesday, October 28, 2008 2:18 PMZoodor Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Vote As Helpful
    0
    One solution that doesn't seem to be mentioned so far is that if you have a separate project for your proxy classes (which we happen to do at my company) and you have both VS2005 and 2008 installed, then you can simply open this project in 2005 and update the web reference in there - no need to have separate projects, as VS2005 and 2008 can share project files. The project can then be built in 2008 and everything should work as before.

    Hope this helps someone.
    • ReplyReply
    • QuoteQuote
     
Need Help with Forums? (FAQ)
 
© 2009 Microsoft Corporation. All rights reserved.
Terms of Use
|
Trademarks
|
Privacy Statement