Click here to Skip to main content
16,012,352 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi,
i created an json format web service in which iam getting the message"Attribute specifier is not a complete statement. Use a line continuation to apply the attribute to the following statement."
in the line
XML
<ScriptMethod(ResponseFormat:=ResponseFormat.Json)> _

i dont know whats the problem pls help me out.
XML
<System.Web.Script.Services.ScriptService()> _
<WebService(Namespace:="http://tempuri.org/")> _
<WebServiceBinding(ConformsTo:=WsiProfiles.BasicProfile1_1)> _
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Public Class Booking
    Inherits System.Web.Services.WebService
     <WebMethod()> _
<ScriptMethod(ResponseFormat:=ResponseFormat.Json)> _

    Public Function MobileBooking(ByVal Pickuplocation As String, ByVal Droplocation As String, ByVal latitude As String, ByVal longitude As String, ByVal Pickuptime As String, ByVal callerid As String, ByVal callername As String, ByVal companyid As String, ByVal frid As String) As String
Posted
Updated 29-Mar-12 2:36am
v2
Comments
ledtech3 29-Mar-12 10:05am    
Is there a Line length limit ?
You may try in the function Public Function MobileBooking
ByVal Pickuplocation As String, _
ByVal Droplocation As String, _
ByVal latitude As String, _

and so on.
Bernhard Hiller 29-Mar-12 11:01am    
Is it the empty line after <ScriptMethod(ResponseFormat:=ResponseFormat.Json)> _ whichis not accepted?

1 solution

Agreed with Bernhard, there's an empty line after:

VB
<scriptmethod(responseformat:> _
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900