How do I navigate through records using drag 'n' drop controls?
I have an example in C# for Windows forms that relies on
BindingContext but this is not available for ASP.NET. How do I solve
that problem?
PS: I don't need a code example showing me how to do it without drag
'n' drop because I already know how. I WANT to learn how to do it with
drag 'n' drop.
Suppose I have a form in which I want to display records with two
textboxes: txtID and txtName, two buttons 'Last' and 'Next'. My
database record has an key field: myID which is an integer Identity
field and a varchar field called myName.
I already have the sqlConnection, sqlDataAdaptor, DataSet and
DataView. Let's call them connMine, daMine, dsMine and dvMine.
I set the properties of each textbox to a relevant field from the
DataView, dvMine. I'm not worried about what to do when the Last and
Next click events loop around to the first and last records; I can
deal with that. I just need an example of drag 'n' drop database
controls with navigation. There must be one somewhere?
For instance with a windows form I can bind records simply with the
code:
private void frmMain_Load(object sender, System.EventArgs e)
{
this.daMine.Fill(this.dsMine,1,0,"EgTable");
}
private void cmdNext_Click(object sender, System.EventArgs e)
{
// Move to next record.
this.BindingContext[this.dsMine,"EgTable"].Position++
}
What code substitues in ASP.NET Page_Load() and cmdNext_Click()?