Creating a Web Service

According to several examples on how to create a web service using WSE 2.0 when you enable WSE 2.0 for a project by selecting the two checkboxes on the General Tab references are automatically added to your project and in the Reference.cs (or Reference.vb) file of the project you will see two instances of the Service class created. Example: MyService and MyServiceWSE< xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

 

In my projects the references are being added to the project, but the two instances of the Service class in the reference file are not being created.   Does anyone know how I can fix this

 

Thanks,

Dennis



Answer this question

Creating a Web Service

  • Debbie M

    I thought right clicking on the project name and selecting Web Services2 was enabling it as it put the references into the program.

    Dennis

  • Brian Corcoran

    you have to enable the WSE first , before adding any web reference. if that still doesn't work , you have to manually modify your proxy to derive from Microsoft.Web.Services2.WebServicesClientProtocol
  • buntyrolln

    Thanks Nathan,

    I had already figured that out, but thanks for the info anyway.

    Dennis

  • chue

    There's two choices to do this automatically:  either enable WSE before adding any web references, or after enabling WSE right click on the web reference and update.

    Otherwise you can also manually change the class the proxy class derives from, but any changes will be overwritten when the web reference is updated.

  • Ole Martin Brynildsen

    Hello,guys!
    It works when I use vs.net2003 + wse2.0.
    But ,when I create webservice by using vs.net2005 beta2  and wse2.0,
    I can't find the Reference.cs file.

    Can you help me to resolve this problem
    Thanks

    Kent

    Email: it99kent@yahoo.com.cn



  • Creating a Web Service