Parser error adding web reference RRS feed

  • Question

  • I have written two web services in a Web applicaiton. When I try and add a reference in a Windows project, one succeeds but the other fails with 

    Server Error in '/' Application.
    Parser Error 
    Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately. 
    Parser Error Message: Could not create type 'PCS_WebApp.WSReview'.
    Source Error: 
    Line 1:  <%@ WebService Language="vb" CodeBehind="WSReview.asmx.vb" Class="PCS_WebApp.WSReview" %>
    Source File: /WSReview.asmx    Line: 1 
    Version Information: Microsoft .NET Framework Version:2.0.50727.9148; ASP.NET Version:2.0.50727.9136 

    As far as I can tell the implementaiton of both is identical - certainly both asmx files contain the same text with the name changed.. (this from Notepad)

    <%@ WebService Language="vb" CodeBehind="WSEntrant.asmx.vb" Class="PCS_WebApp.WSEntrant" %>
    <%@ WebService Language="vb" CodeBehind="WSReview.asmx.vb" Class="PCS_WebApp.WSReview" %>

    How do i fix this?

    Sunday, March 22, 2020 12:29 PM

All replies

  • Hi,

    Thanks for posting here.

    To make sure that whether the file name and class name you create are consistent with the class name in. Asmx.

    And check this Answer from JohnW on SO for details.

    Best Regards,


    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.

    Tuesday, March 24, 2020 1:31 AM