PC Review


Reply
Thread Tools Rate Thread

DataTable PrimaryKey problem

 
 
Steve
Guest
Posts: n/a
 
      23rd Jan 2004
Hello

I hve a primary key defined on a DataTable in a DataSet. When I create
a new row in the table I give the primary key a default value from the
database but then want the user to be able to update it (i.e. specify
a different value from the default). The problem is that the
DataTable.Rows.Find() and DataTable.Select() methods seem to work off
of the original value rather than the new one. Is there a way of
getting either Find or Select to return the current value? I've tried
the DataViewRowState parameter on the Select, but this doesn't work.

Steve
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Set primarykey to a datatable Lars E Microsoft C# .NET 4 26th Apr 2006 02:01 PM
Adding PrimaryKey to a DataTable Shawn Microsoft ASP .NET 1 21st Jun 2005 03:35 PM
Re: PrimaryKey in Datatable Disappears Teemu Keiski Microsoft ASP .NET 2 31st Mar 2004 08:58 PM
the primarykey property on the datatable object =?Utf-8?B?YWxhbg==?= Microsoft Dot NET 2 18th Feb 2004 04:40 PM
How to Find Row Index by PrimaryKey of DataTable Ivan Microsoft ADO .NET 2 14th Aug 2003 01:22 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:19 PM.