LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

OpenSource Project for a .NET Datagrid for LabVIEW

Solved!
Go to solution

You will need a minor change to allow delete to work.  

One possible cause for the delete functionality not working is that you need to have a row selected.

This means either having the SelectionMode set to FullRowSelect or means that you have previously clicked on the row headers which are to the right of the columns.

You will have to enabled that selection mode (there is a property) and show row headers so you have something to select.  Once the row is selected, you can delete it with the DEL key as you desire. Easy to do.

You should be able to add a row at the end of the list, scroll down or tab from the last column.

0 Kudos
Message 21 of 30
(1,083 Views)

Very good, thank you Mike !

Another challenge  I have is, how can I add a checkbox to the column header?

I know that it is possible... but I`m  not really familiar with it...

Please see the attached picture, I`ve created a method in the Data Table class which is called Add_ColHeaderCheckbox.

And I read that I have to insert the checkbox at position -1, but I don`t know how to link them in Labview.

Best wishes

0 Kudos
Message 22 of 30
(1,063 Views)

That one I don't know, sorry.  You'll have to dig into some good searches for what you need (use the term datagridview) as there are tons of great online c# examples showing how to do these things.  From those samples, you can find the properties/methods you need to set to achieve what you want.  That's how I developed most of this and it will teach you how to customize the datagridview in LabVIEW with some new wrapper methods that you need.

0 Kudos
Message 23 of 30
(1,045 Views)

Thank you for your resoponse.

0 Kudos
Message 24 of 30
(1,042 Views)

Hi, i downloaded Datagrid for Labview and I open the example vi that comes with it ("Example Simple DataBinding.vi") to test if it meets my needs.

Running this vi I see the good capabilities of the control, but I notice a delay from when the vi start to when the datagrid is loaded with data.

So I raised the number of rows and the delay becomes higher. Then I set # of rows to 1000 (which is a common amount of rows in my applications) and I measured a delay of about 15 seconds (from start to datagrid completely loaded). For my kind of applications it is too much to wait 15 second to fill a "table" with 1000 rows. Anyway when loaded the datagrid performs fast as expected.

 

Is there a way to speed up the loading data into datagrid?

Is there a special configuration that I should have missed to avoid this huge delay?

 

Thanks

Andrea

0 Kudos
Message 25 of 30
(766 Views)

A few things you can do.  Use less of the special type columns like combos, image, links, checks, these are all much slower than strings/numerics. 15 seconds is really slow, when I run the default app with 1000 rows, it is done in about 4 seconds, slow but tollerable still.  With these other changes, done in about 1.5 seconds so a dramatic improvement. 

 

In the DataGridView: Initialize.vi you can change the row and column autosizing to use only the headers or NONE and it will speed up dramatically as well.  This is a very nice convenient feature, but costly to performance, so change some of those properties and test your speed to get it faster.  Good luck.

 

Massimo1167 posted this idea to gihub to also have a minor speed up on drawing columns.  Its fairly minimal though so I've not implemented it since the main idea of gridview is to have one VI to use by default, not more than that which his suggestion would require.  https://github.com/unipsycho/LabVIEWdotNetDataGrid/issues/22

0 Kudos
Message 26 of 30
(760 Views)

Hi Mike,

 

This is Alexander, sales from NI Taiwan. One of our local system integrator would like to use your toolkit. He has some questions as the following:

  • Will this toolkit needs a run-time license for it's free?
  • During the evaluation, the customer needs to use "Copy and Paste Row", "Edit Row", "Add or Delete Row Etc", "Disable Columns Sort", "Read DataTable". However, he has problem studying by his own. If possible, he would like to ask for more examples by paying some fee. Is it possible for this kind of support?

Kindly let me know your comment or suggestion. Thanks for your help.

 

Best regards,

Alexander

0 Kudos
Message 27 of 30
(632 Views)

I've P.M. you regarding your questions for options, as I'm unable to do much support on it right now, being too busy.

0 Kudos
Message 28 of 30
(621 Views)

Is it possible to prevent the user from editing columns, that is to use it as a pure display?

0 Kudos
Message 29 of 30
(451 Views)

Hi mark, sorry I've been too busy to look at this.  This would be possible, columns have to be each be set though, the good thing, is there are many properties you can set in this way.  See the attached VI for column sortable as an example, you can then change this to set any of the properties, in your case, read only.  Good luck!  The VI in 2016

j6CPHr

0 Kudos
Message 30 of 30
(380 Views)