テーブル「authors」を持つデータベース「Pubs」があります。「作成者」をドラッグして、データベースから dbml ファイルを作成しました。
ここに「Default.aspx.vb」があります
Public Class _Default
Inherits System.Web.UI.Page
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Dim db As New PubsContext
Dim products = From p In db.authors _
Select p
GridView1.DataSource = author
GridView1.DataBind()
End Sub
End Class
これがそのクラスです: "Class1.vb"
Partial Public Class PubsContext
Public Function GetProductsByCategory(ByVal id1 As Integer) As IEnumerable(Of authors)
Return From p In Me.authors _
Where p.ProductID = id1 _
Select p
End Function
End Class
著者と著者の訂正箇所には赤い下線が引かれています。私は何をすべきか?