473,385 Members | 1,640 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

rowstate.deleted

Does anyone know if it is possible to get information out of a datarow which
has been deleted?

Thanks,

Albert
Nov 21 '05 #1
5 4463
Albert wrote:
Does anyone know if it is possible to get information out of a datarow which
has been deleted?

Thanks,

Albert

as long as you did not call the AcceptChanges method of the datarow.

Example accessing the data in Column idx of DataRow Row:
If Row.HasVersion(DataRowVersion.Original) Then
Debug.WriteLine(Row(idx, DataRowVersion.Original))
End If
Nov 21 '05 #2
Dim d As New DataTable
Dim deletedRows As DataRowCollection

d.DefaultView.RowStateFilter = DataViewRowState.Deleted

deletedRows = d.Rows

--

OHM ( Terry Burns )
. . . One-Handed-Man . . .
If U Need My Email ,Ask Me

Time flies when you don't know what you're doing

"Albert" <al****@informant.nl> wrote in message
news:cg**********@reader13.wxs.nl...
Does anyone know if it is possible to get information out of a datarow which has been deleted?

Thanks,

Albert

Nov 21 '05 #3
This will only give me a collection of deleted rows, i need to see what data
is in the rows which are deleted
"One Handed Man ( OHM - Terry Burns )" <news.microsoft.com> schreef in
bericht news:eZ*************@TK2MSFTNGP09.phx.gbl...
Dim d As New DataTable
Dim deletedRows As DataRowCollection

d.DefaultView.RowStateFilter = DataViewRowState.Deleted

deletedRows = d.Rows

--

OHM ( Terry Burns )
. . . One-Handed-Man . . .
If U Need My Email ,Ask Me

Time flies when you don't know what you're doing

"Albert" <al****@informant.nl> wrote in message
news:cg**********@reader13.wxs.nl...
Does anyone know if it is possible to get information out of a datarow

which
has been deleted?

Thanks,

Albert


Nov 21 '05 #4
Doesnt work, i tried following

I delete a row e.g.

dim dtchanges as datatable

dtchanges=dtmain.select(smt=smt)

for each drow in dtchanges
drow.delete
next

etc.

now when i try to get info out of the deleted rows i get an error
I read a row like this.

dim dtdeleted as datatable = dtmain.detectchanges

for each drow in dtdeleted
msgbox drow(0) <----- Error here
next
"Erik" <us**@domain.invalid> schreef in bericht
news:Ob*************@TK2MSFTNGP11.phx.gbl...
Albert wrote:
Does anyone know if it is possible to get information out of a datarow which has been deleted?

Thanks,

Albert

as long as you did not call the AcceptChanges method of the datarow.

Example accessing the data in Column idx of DataRow Row:
If Row.HasVersion(DataRowVersion.Original) Then
Debug.WriteLine(Row(idx, DataRowVersion.Original))
End If

Nov 21 '05 #5
Ok now I see what you mean,

it is the "DatarowVersion.Original". That'll do the trick, thanks!

Albert

"Albert" <al****@informant.nl> schreef in bericht
news:cg**********@reader13.wxs.nl...
Doesnt work, i tried following

I delete a row e.g.

dim dtchanges as datatable

dtchanges=dtmain.select(smt=smt)

for each drow in dtchanges
drow.delete
next

etc.

now when i try to get info out of the deleted rows i get an error
I read a row like this.

dim dtdeleted as datatable = dtmain.detectchanges

for each drow in dtdeleted
msgbox drow(0) <----- Error here
next
"Erik" <us**@domain.invalid> schreef in bericht
news:Ob*************@TK2MSFTNGP11.phx.gbl...
Albert wrote:
Does anyone know if it is possible to get information out of a datarow which has been deleted?

Thanks,

Albert

as long as you did not call the AcceptChanges method of the datarow.

Example accessing the data in Column idx of DataRow Row:
If Row.HasVersion(DataRowVersion.Original) Then
Debug.WriteLine(Row(idx, DataRowVersion.Original))
End If


Nov 21 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Cary Linkfield | last post by:
I have created a custom class inheriting CollectionBase and implementing IBindingList. I am binding the list to a datagrid. I would like to have a property on the class that works like the...
6
by: BStorm | last post by:
Is it possible to change individual RowState properties from updated to not updated?
0
by: fatboycanteen | last post by:
When I filled the db data to the dataset eg. (id_col is autoincrement) id_col field1 97 100 98 200 99 15 100 72 ---
1
by: thomson | last post by:
Hi all, i need to get the total count of rows in a datatable with rowstate deleted. Thanks in advance thomson
6
by: astro | last post by:
I'm working through the binder stuff trying to get a handle on it... I have setup a master-detail dataset and have a couple of textboxes from the master along with a datadgrid for the child data....
6
by: timbobd | last post by:
I have a Windows form that displays a database table in a DataGrid. When you click on a row, the row's values get copied to bound TextBoxes below, and when the "Save" button is clicked the database...
0
by: Steven Nagy | last post by:
HI, I have a situation where after moving a dataset as XML from one PC to another through a socket where the data tables lose their rowstate information. Luckily I am able to get what that...
13
by: Dale Harris | last post by:
I'm getting really strange behaviour where the data source RowState is not being updated to modified in some circumstances. I place my controls on a form, bind them through a BindingSource control...
3
by: perspolis | last post by:
Hi all I have a master detail table which I use them in Transaction to Update them. in some cases the detail table generates error and I Rollback transaction but RowState of master table dosen't...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.