How can i "see" the next record

  • Thread starter Thread starter giannis
  • Start date Start date
G

giannis

How can i know ("see") the next record using the BindingSource
without move to the next record ?
 
When i use the BindingSource.position + 1 the form display the next record.
I want to know the value of the next record without the form display the
next record.
 
Giannis,

Are you sure of that, it would be in my idea new VB code. Are you not mixing
this up with BindingSource.Position += 1

I cannot see your code but BindingSource.Position + 1 gives you in my idea
the next record.

Cor
 
Cor said:
BindingSource.Position + 1 gives you in my idea the next record.

What code must i write to take the value of the next record ?
Can you indicate me ?
 
First show me a piece how you do it, I can not give you a sample from 1:1000

Cor
 
If the underlying DataSource for the BindingSource is a DataTable,
then the object retrieved from the BindingSource by indexing it will
be a DataRowView. Below is code that shows how to get at a field once
you have a DataRowView. If you underlying datasource is something
other than a DataTable, then the object retrieved will be some other
type.

Dim drv As DataRowView =
CType(bindingSource1(bindingSource1.Position + 1), DataRowView) '
Dim someIntValue As Integer = CInt(drv("Col1")) ' Col1 is name
of column in DataTable

==================
Clay Burch
Syncfusion, Inc.
 
We have a form (form1) with a Text box (box1) that takes values
from a BindingSource. The currency value for the box1 is :
"me.box1.text"
How can we find (with the BindingSource.Position +1) the next value
for the box1 before we move to the next record ? (BindingSource.movenext)
Sorry for my english ....
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top