Results 1 to 5 of 5

Thread: deleting row from dataset

  1. #1

    Thread Starter
    New Member
    Join Date
    Dec 2003
    Posts
    10

    deleting row from dataset

    hi gurus and pros,

    I used the following code to delete a row from dataset:
    Code:
    R.delete()
    the problem that I have an error msg of "System Error" when trying to update the dataset using dataadapter.update method.
    every thing else works fine like updating existing records or adding new entries.

    any suggestion

  2. #2
    Frenzied Member
    Join Date
    Oct 2002
    Location
    Gammapolis
    Posts
    1,474
    Please post error description. Dont you have any constraints in the database not letting the row to be deleted?
    'Heading for the automatic overload'
    Marillion, Brave, The Great Escape, 1994

    'How will WE stand the FIRE TOMORROW?'
    Eloy, Silent Cries and Mighty Echoes, The Vision - Burning, 1979

  3. #3
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083
    Or execute DELETE command . Here's a very good tutorial .http://samples.gotdotnet.com/quickstart/winforms/

  4. #4

    Thread Starter
    New Member
    Join Date
    Dec 2003
    Posts
    10
    thank you for your reply and sorry for my annoying questions...

    error msg is:
    "An unhandled exception of type 'System.Data.SqlClient.SqlException' occured in system.data.dll

    Additional information: System error."

    and I don't have any constraints on the DB. (or at least, this's what I think )

    by the way: this problem doesn't happen when deleting the last row in the database.
    Last edited by undo; Dec 31st, 2003 at 09:34 AM.

  5. #5
    Addicted Member rdove's Avatar
    Join Date
    Dec 2002
    Location
    Indianapolis
    Posts
    251
    Are you telling it which row to delete?

    Is would also probably be helpful if you posted the entire code in question because it is most likely not that exact line causing the error.
    ~Ryan





    Have I helped you? Please Rate my posts.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width