帮忙看看,怎样修改错误

shot_big shot_big 墨衍会员 · AI 创作全网分发 墨衍智能分发 通过墨衍一键同步至各平台 可同步平台 CSDN微信公众号微博知乎掘金百家号博客园抖音小红书 你的文章也可以这样分发 墨衍会员 ¥399起/年,写一次发全网 我也要 + 加入社区
Compiler Error Message: BC30203: Expected an identifier.

Source Error:
Line 11: End class
Line 12: public class datatypes
Line 13: Public Function <WebMethod()> SayHello() As String
Line 14: Return "Hello World!"
Line 15: End Function



<%@ WebService language="vb" class=dataservice%>
Imports system
Imports system.data
Imports system.data.sqlclient
Imports system.web.services

Public class dataservice
public function<Webmethod()>Getcolor() As DataSet
Dim myconnection As sqlconnection=New sqlconnection("server=localhost;uid=sa;pwd=;database=aspx")
Dim mycommand1 As sqldatasetcommand=New sqldatasetcommand("select* from bbs_sort",myconnection)
Dim mycommand2 As sqldatasetcommand=New sqldatasetcommand("select * from bbs_root",myconnection)
Dim ds As New dataset
mycommand1.filldataset(ds,"bbs_sort")
mycommand2.filldataset(ds,"bbs_root")
return ds
end function
Public funtion<WebMethod()>Putcolor(ds as dataset) as Integer
Return ds.tables(0).Rows.count
End function
end class
...全文
评论 7
收藏 已收藏
分享
返回顶部
shot_big
.NET社区 62,272 成员 668,968 内容