S
Saber
I have a gridview:
<asp:GridView ID="GridView1" runat="server" AllowPaging="True"
AllowSorting="True" AutoGenerateColumns="False" CellPadding="4"
DataSourceID="SqlDataSource1" ForeColor="#333333" GridLines="None"
DataKeyNames="ADid">
and it is my update query:
UPDATE tblAds SET ADName = @ADname, ADType = @ADType, ADPriority =
@ADPriority FROM tblAds INNER JOIN tblCategories ON tblAds.ADCatID =
tblCategories.CatID WHERE tblAds.ADid = @ADid
When I try to update a field, I get an error message:
Must declare the variable '@ADid'.
<asp:GridView ID="GridView1" runat="server" AllowPaging="True"
AllowSorting="True" AutoGenerateColumns="False" CellPadding="4"
DataSourceID="SqlDataSource1" ForeColor="#333333" GridLines="None"
DataKeyNames="ADid">
and it is my update query:
UPDATE tblAds SET ADName = @ADname, ADType = @ADType, ADPriority =
@ADPriority FROM tblAds INNER JOIN tblCategories ON tblAds.ADCatID =
tblCategories.CatID WHERE tblAds.ADid = @ADid
When I try to update a field, I get an error message:
Must declare the variable '@ADid'.