I have a rather unusual project. I'm supposed to create a VB/Dot Net 2.0 web
app that uses FoxPro 6 tables.
I'm using an XSD and Object Data Sources. I've gotten it to the point where
I can reasonably say I know how to do updates and inserts. Now I have a main
page with a Gridview bound to an ODS. I want to add the standard Delete
command field. Everything is set up correctly so far as I can tell. (The
Delete statement is in the XSD table adapter. The ODS on the page recognizes
the Delete call. The parameter is declared, in the xsd and in the ODS. The
key field used as a parameter is not only visible in the grid row, it's
extracted and used as a query string parameter in a hyperlink in the same
row, so the data is most definitely available.)
But when I click the Delete, I get the error:
Value cannot be null.
Parameter name: oid
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information about
the error and where it originated in the code.
Exception Details: System.ArgumentNullException: Value cannot be null.
Parameter name: oid
Source Error:
Line 11918: Public Overloads Overridable Function Delete(ByVal oid As
String) As Integer
Line 11919: If (oid Is Nothing) Then
Line 11920: Throw New
Global.System.ArgumentNullException("oid")
Line 11921: Else
Line 11922: Me.Adapter.DeleteCommand.Parameters(0).Value =
CType(oid,String)
Source File: C:\Data\Visual Studio
2005\Projects\FoxProOrderEntrySystem3\FoxProOrderEntrySystem3\FoxPro1.Designer.vb Line: 11920
----------------------
What else could I be forgetting? What could be keeping the value from the
function call?
|