Kirk Evans Blog

.NET From a Markup Perspective

Where The Heck is "Add Web Reference" in Visual Studio 2008?!?!

Where The Heck is "Add Web Reference" in Visual Studio 2008?!?!

Rate This
  • Comments 5

I was working on a demo for a customer and needed to use ASMX web services.  I crufted up my sample application, right-clicked the project node in the Solution Explorer pane, and saw that there is no "Add Web Reference" menu item there anymore.  Strange.  Then I went to the Project menu item and was going to select it from there, but it was grayed out.  Wha?!?  OK, I know I can use wsdl.exe to generate ASMX assets, but that doesn't answer why it was grayed out and I can't use ASMX anymore.

Turns out that you can still easily generate ASMX web references using Visual Studio 2008.  Right-click the project node in the Solution Explorer pane (or click the Project menu item) and choose "Add Service Reference..."  You will get the Add Service Reference dialog.  Click the Advanced button at the bottom left.

The next screen that appears is the Service Reference Settings dialog.  This is where you can easily enable your WCF client for asynchronous method invocation.  You can control message contract generation, and type reuse settings as well.  There's also a button at the bottom left that says "Add Web Reference".

Click that button, and you get the familiar dialog that lets you generate ASMX proxies.

  • What's wrong with using WCF to connect to ASMX? You'd get more control...

  • There's nothing wrong with it, I'd absolutely advocate using WCF over ASMX for all new development.  However, many customers are maintaining code bases with ASMX and haven't yet ported that functionality to WCF.  Visual Studio 2008 shouldn't be a blocker for them to continue development, I wrote the post to help those customers out.

  • why Microsoft change simple things when create new versions of products???

    In this way can I have new features from framework 3.5 or I only have featuures from framework 2.0 as is noted in wizard ??

  • Thanks, that was very helpful.  I was wondering where the heck that stupid add web reference went.

  • Thanks for that! I've been searching for that solution all day!

Page 1 of 1 (5 items)
Leave a Comment
  • Please add 5 and 1 and type the answer here:
  • Post
Translate This Page
Search
Archive
Archives