Inserting Database Record Using DataSource
This code:
Me.SqlDataSource1.InsertParameters("@term") = New Parameter("@term", Data.DbType.AnsiString, "test")
Me.SqlDataSource1.InsertParameters("@definition") = New Parameter("@definition", Data.DbType.AnsiString, "test")
Me.SqlDataSource1.Insert()
Gives me this error:
Cannot insert the value NULL into column 'term', table 'GeneralAssembly.dbo.tblGACMSGlossary'; column does not allow nulls. INSERT fails.
The statement has been terminated.
Insert code is defined in data source as
InsertCommand="INSERT INTO [tblGACMSGlossary] ([term], [definition]) VALUES (@term, @definition)"