DataKeyField Property in Datagrid

Discussion in 'ASP .Net Web Controls' started by Bruce LeMond, Nov 17, 2003.

  1. Bruce LeMond

    Bruce LeMond Guest

    The datakeyfield property in the datagrid just lets us
    specify one field. But my primary key consist of 3
    fields. I know that this is used as a parameter for the
    execution of the findby method to find the record in the
    dataset for updating. So I went into the code and put in
    the parameters in the findby method which would be as
    follow:

    Dim r As DSHousekeepitems.housekeepingItemsRow
    r =
    DSHousekeepitems1.housekeepingItems.FindByroomitemRequestDa
    te(UPTRoom, UPTItem, UPTRequestDate)

    But no row was found causing an error message being
    displayed when executing. I also put in the code to
    display the values of the three fields, and the values are
    in these fields ok. So anyone have any answers on why the
    record is still not being found?

    Thanks in advance.
    Bruce LeMond, Nov 17, 2003
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Homer J. Simpson
    Replies:
    2
    Views:
    1,106
    Suresh
    Mar 5, 2004
  2. Adam Knight

    DataGrid - DataKeyField!!

    Adam Knight, Aug 7, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    4,183
    Adam Knight
    Aug 7, 2005
  3. Sean

    how to get datagrid item index from DataKeyField value?

    Sean, Aug 6, 2003, in forum: ASP .Net Datagrid Control
    Replies:
    1
    Views:
    758
    Arthur
    Aug 7, 2003
  4. A. Atienza

    DataGrid's DataKeyField Value (C#)

    A. Atienza, Dec 7, 2004, in forum: ASP .Net Datagrid Control
    Replies:
    1
    Views:
    334
    Michael Tkachev
    Dec 7, 2004
  5. Bruce LeMond

    DataKeyField Property in Datagrid

    Bruce LeMond, Oct 28, 2003, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    119
    Bruce LeMond
    Oct 28, 2003
Loading...

Share This Page