locked
Want to use Microsoft.web.service3 when adding a web service. RRS feed

  • Question

  •         Dim MyServ As New HSEmpService.EmpServiceService()
            Dim token As New UsernameToken(strUserName, strPassword, PasswordOption.SendPlainText)
            MyServ.RequestSoapContext.Security.Timestamp.TtlInSeconds = 86000
            MyServ.RequestSoapContext.Security.Tokens.Add(token)
    
            DispThis(MyServ.sayHello() & NewLine)

    When I add a web service the Reference.vb is built with 

            Inherits System.Web.Services.Protocols.SoapHttpClientProtocol
    
    I have to change it to 

    Inherits Microsoft.Web.Services3.WebServicesClientProtocol
    to use the Service3. If I update the service I have to manually change them again. Is there a way for the add web reference to automatically use the Microsoft.web.service3?

    Wednesday, January 4, 2017 9:44 PM

All replies

  • Hi Paul_Braums,

    Since this forum discusses the Microsoft build engine aka MSBuild. As your issue is more related to asp.net web service, I would suggest that you could post your issue on asp.net web service forum for support.

    https://forums.asp.net/28.aspx/1?WCF+ASMX+and+other+Web+Services

    Thank you for your understanding and cooperation.

    Best regards,

    Cole Wu


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Thursday, January 5, 2017 6:53 AM
  • Just to make sure we are on the same page. How is the "Reference.vb" built when you go through the UI for "Add Web Service"? If there is an question on how it is built, would that not be here?
    • Edited by Paul_Braums Friday, January 6, 2017 2:53 PM Clarify my question.
    Thursday, January 5, 2017 5:48 PM