Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
DataSet, DataTable, DataView
Message
From
03/08/2004 01:24:32
 
 
To
02/08/2004 21:03:59
General information
Forum:
ASP.NET
Category:
ADO.NET
Miscellaneous
Thread ID:
00928619
Message ID:
00930247
Views:
24
Hi Bonnie,

Thanks for the reply. I just want to inform you that we solved my problem :D Thanks....

Here is what I did.

First I passed my Dataview and the CurrentRowIndex of my DataGrid from my MainForm.

Then, I initialized the variables that will receive the Dataview and CurrentRowIndex in my modal Form

Next, I created an instance of the BindingManagerBase of my ModalForm and used the received Dataview as its source.

Then I just assign the Received CurrentRowIndex value to the position of the BindingManager just like this

private DataView dvStaff;
private int rindex;

public FrmEditStaff(DataView dv, int ri)
{
InitializeComponent();
this.dvStaff = dv;

BindingManagerBase bmStaff = this.BindingContext[dvStaff] ;
bmStaff.Position = ri;
}

Now my modal form displays the record that I want to modify.

Thanks...

By the way, Is this the best approach on how to deal with this kind of scenarios?

Please Advice...
Thanks...
Music Rocks www.musicreserve.blogspot.com
Success is 1% Inspiration & 99% Perspiration
God Sometimes Delays His Help to Test Our Faith and Energize Our Prayers
Our Boat May Be Tossed While He Sleeps, But He Wakes Up Before it Sinks.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform