From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Scrollbar in Tree Control = wonky

The TREE control scrollbar seems to have some ill-thought-out behavior.

 

1... Run the example TREE ENHANCEMENTS (Examples - Building UIs - Displaying Data - General )

2... Choose a folder on your machine with a few (3-5) folders in it but lots of files and folders contained within those folders.

3... Select the PATTERN as appropriate.

4... Run the VI.  Your files should show up in the list, then the list collapses.

5... Expand the folders, so that there are more items in the list than it can display at one time.

6... The scrollbar appears (that's sensible).

7... Scroll down so that items disappear off the top.

8... Right click and choose CLOSE ALL ITEMS

 

--- I would expect the control to automatically move back up to the top, so you could see something, but it doesn't.

9... Play with the scrollbar thumb.  Not exactly sensible.

 

Here is a JING to watch, showing this behavior.

The code that populates this tree is copied from the example (and modified to remove file extensions).

Once the tree is populated, the code is doing nothing (except waiting for a QUIT button).

 

Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


Blog for (mostly LabVIEW) programmers: Tips And Tricks

0 Kudos
Message 1 of 5
(2,436 Views)

Hi Steve,

 

I agree that something is not right after watching your jing cast. Can you post a vi that can reproduce this? Also what version of LabVIEW are you using?

Joe Daily
National Instruments
Applications Engineer

may the G be with you ....
0 Kudos
Message 2 of 5
(2,400 Views)

Just run the example I mentioned.  It's not code that does it - it's the behavior of the tree control itself.

 

But you need to structure the folders so that you have a few (< # lines in tree) root-level folders, and many (> #lines in tree) sub-folders/files, whatever.

 

When you collapse the tree, I would expect the scrollbar to adapt to the new situation, and possibly disappear.  Instead, it's working on old information, I suppose.

Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


Blog for (mostly LabVIEW) programmers: Tips And Tricks

0 Kudos
Message 3 of 5
(2,383 Views)

It's LabVIEW 2010  version 10.0 (32 bit).

Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
Culverson.com


Blog for (mostly LabVIEW) programmers: Tips And Tricks

0 Kudos
Message 4 of 5
(2,382 Views)

Hi Steve,

 

I created a Corrective Action Request# 283502 on this. This should be fixed in a later version of LabVIEW

Joe Daily
National Instruments
Applications Engineer

may the G be with you ....
0 Kudos
Message 5 of 5
(2,356 Views)