Datagrid vs. Multi-select button.

  • Thread starter Thread starter Marc R.
  • Start date Start date
M

Marc R.

Hi all,

I want to select all record into a grid that is bind to A Dataview,

any easy way ?

thanks.
Marc R.
 
Marc,

Version VB2005 or before. The dataview in VB2005 has a new method .ToTable

http://msdn2.microsoft.com/en-us/library/dw1b4t59.aspx

Be aware on this page is not mentioned that it is a Net 2.0 method, you
don't find it in 1.x

For version before you can have a look what this method can to you (not
exactly because you have to do it with all rows and not a selection and
therefore it is even more easy)

http://www.vb-tips.com/default.aspx?ID=dcad9a66-1366-4d61-8d32-1a580eb893b2

I hope this helps,

Cor
 
Hi,

Use the datagrid's select method to select rows.

Dim cm As CurrencyManager =
CType(Me.BindingContext(DataGrid1.DataSource), CurrencyManager)
For x As Integer = 0 To cm.Count - 1
DataGrid1.Select(x)
Next

Ken
 

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