Click here to Skip to main content
15,887,821 members
Home / Discussions / C#
   

C#

 
GeneralRe: handle shorcut Ctrl+V event on AxWebBrowser Pin
Pete O'Hanlon16-Mar-09 2:47
mvePete O'Hanlon16-Mar-09 2:47 
QuestionPreserving row pointer across an database update via a datatable Pin
jrgrobinson15-Mar-09 22:29
jrgrobinson15-Mar-09 22:29 
AnswerRe: Preserving row pointer across an database update via a datatable Pin
Wael Dalloul15-Mar-09 23:19
Wael Dalloul15-Mar-09 23:19 
GeneralRe: Preserving row pointer across an database update via a datatable Pin
jrgrobinson16-Mar-09 0:23
jrgrobinson16-Mar-09 0:23 
GeneralRe: Preserving row pointer across an database update via a datatable Pin
Wael Dalloul16-Mar-09 0:56
Wael Dalloul16-Mar-09 0:56 
AnswerRe: Preserving row pointer across an database update via a datatable Pin
Mycroft Holmes15-Mar-09 23:25
professionalMycroft Holmes15-Mar-09 23:25 
GeneralRe: Preserving row pointer across an database update via a datatable Pin
jrgrobinson16-Mar-09 0:19
jrgrobinson16-Mar-09 0:19 
AnswerRe: Preserving row pointer across an database update via a datatable Pin
jrgrobinson16-Mar-09 1:44
jrgrobinson16-Mar-09 1:44 
Just to close it off for prosperity.

I have a data table, filled by a table adapter with '...WHERE(PK=@PK)'. It had a single row in it. I added another row (.NewRow, .AddRow). The Rows count of the table was 2. Index [0] pointed to the old origional data. Index [1] pointed to the new data, DataRowState=Added.

I then called the table adapter.update (a rather large INSERT statement)

There was still a count of two rows but both [0] and [1] pointed to the same row, the origional. This would indicate the data table of the dataset is no longer valid after an Update. I then did another fill and the data table had both rows as before (now unchanged state).

The reason for writing this is to record for other people that may fall into this minor but time consuming trap. The tableAdapter.Update call is the end of the road for the validity of the data table data. There isn't a lot of documentation or web resource that tells you this.

It maybe obvious to seasoned .NET database engineers, and maybe standard practice. It would be unexpected to new entrants in this field with experience of other, dare I say it, more normal, caching systems.

Thanks for the help.

Ooops, I modified Table Adapter to refer more correctly to the data table of the dataset where referring to storage.
QuestionHandling the state of a form Pin
saeidfarahi15-Mar-09 22:12
saeidfarahi15-Mar-09 22:12 
AnswerRe: Handling the state of a form Pin
Eddy Vluggen15-Mar-09 22:33
professionalEddy Vluggen15-Mar-09 22:33 
AnswerRe: Handling the state of a form Pin
Michael Bookatz16-Mar-09 0:38
Michael Bookatz16-Mar-09 0:38 
QuestionHow to create own spell checker window in c# or vb.net(windows) Pin
dilipmca0415-Mar-09 21:21
dilipmca0415-Mar-09 21:21 
AnswerRe: How to create own spell checker window in c# or vb.net(windows) Pin
Christian Graus15-Mar-09 22:07
protectorChristian Graus15-Mar-09 22:07 
AnswerRe: How to create own spell checker window in c# or vb.net(windows) Pin
Eddy Vluggen15-Mar-09 22:35
professionalEddy Vluggen15-Mar-09 22:35 
QuestionHow to add folder with files at runtime into solution explorer visual studio 2008 Pin
am 200915-Mar-09 21:15
am 200915-Mar-09 21:15 
QuestionAdding an AJAX enabled page to normal ASP.NET website Pin
maheshsahini15-Mar-09 21:12
maheshsahini15-Mar-09 21:12 
AnswerRe: Adding an AJAX enabled page to normal ASP.NET website Pin
Christian Graus15-Mar-09 22:08
protectorChristian Graus15-Mar-09 22:08 
QuestionInsert multiple data in a single excel row Pin
shantanusenin15-Mar-09 20:55
shantanusenin15-Mar-09 20:55 
AnswerRe: Insert multiple data in a single excel row Pin
Christian Graus15-Mar-09 22:09
protectorChristian Graus15-Mar-09 22:09 
Question[Message Deleted] Pin
prettymugdha15-Mar-09 20:28
prettymugdha15-Mar-09 20:28 
AnswerRe: send file from web application to windows application via http post PinPopular
Christian Graus15-Mar-09 20:34
protectorChristian Graus15-Mar-09 20:34 
QuestionUrlDownloadToFile () in c# Pin
p_196015-Mar-09 19:17
p_196015-Mar-09 19:17 
AnswerRe: UrlDownloadToFile () in c# Pin
Christian Graus15-Mar-09 20:35
protectorChristian Graus15-Mar-09 20:35 
Questionproblem passing datetime to webservice Pin
prasadbuddhika15-Mar-09 18:12
prasadbuddhika15-Mar-09 18:12 
AnswerRe: problem passing datetime to webservice Pin
King Julien15-Mar-09 21:00
King Julien15-Mar-09 21:00 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.