Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Select a record from VFP view
Message
General information
Forum:
ASP.NET
Category:
ADO.NET
Miscellaneous
Thread ID:
00727610
Message ID:
00727652
Views:
8
Dmitry,

You use the BindingContext method of the form to position the record pointer in the dataset to the correct row you want to display. You pass the index of the row and in .NET (unlike VFP), indexes are zero based to you would set the pointer to number of records in the DataTable minus 1:
Me.BindingContext(MyDataSet,"MyDataTable").Position = _
   MyDataSet.Tables("MyDataTable").Rows.Count - 1
Here is an article that explains DataBinding in .NET. It is very different than in VFP:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dndotnet/html/databindingadonet.asp

>I am very new to .NET.
>
>I am designing a simple page where controls will be "bound" to a view in VFP database. The page has Next/Previous buttons. When the page is opened I want to show the very last record in the view and then allow user to navigate the records.
>
>Would the DataSets be suggested way to implement this?
>
>Thank you.
-----------------------------------------

Cathi Gero, CPA
Prenia Software & Consulting Services
Microsoft C# / .NET MVP
Mere Mortals for .NET MVP
cgero@prenia.com
www.prenia.com
Weblog: blogs.prenia.com/cathi
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform