LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Progress bar within a tree cell - is it possible?

Hi all,

 

Before I go to the effort of creating an XControl, which will no doubt take many hours to perfect, or delving into the cagey world of .NET calls again, I thought I'd ask the question just in case this is natively possible in LabVIEW:

 

Can you embed items, such as progress bars, into the cells of multicolumn listboxes, tables and trees?

 

I'm guessing not, because the built-in datatype is string, and other than symbols there's no apparent support for other datatypes.

As an illustration, this mockup shows what I need to present:

 

bars_in_cells.jpg

 

Has anyone achieved this? Is there a simple way, other than having a number of floating, programmatically positioned progress bar controls on the screen? (Don't even go there)

 

Thank you for reading this, and thanks in advance for your help!

Thoric (CLA, CLED, CTD and LabVIEW Champion)


0 Kudos
Message 1 of 17
(3,569 Views)

 


@Thoric wrote:

 

Is there a simple way, other than having a number of floating, programmatically positioned progress bar controls on the screen?


 

Use a string to represents the progress bar. You use a single char (O, -, =, |, etc.) and keep adding more as time progresses. I have no idea how clear this would be.


___________________
Try to take over the world!
Message 2 of 17
(3,560 Views)

text_in_cells.jpg

 

Thank you for the suggestion, tst, I do have a habit of missing the obvious sometimes, and I think this might just work for me. Indeed, using ASCII table characters and a fixed-width font I can create the impression of a progress bar, but it does lack two elements I'm trying to maintain: aesthetics, and the superimposed text. It's not like the Window's style my client will be expecting, and I have ideas about the superimposed text which make it quite useful so I'd like to keep it.

Not to give up hope though: Is there perhaps a more graphically appealing option someone might be aware of?

Thoric (CLA, CLED, CTD and LabVIEW Champion)


0 Kudos
Message 3 of 17
(3,546 Views)

One more option, based on your example here - don't use a tree. Just use a 1D array of clusters with the label and the scrollbar. This assumes, of course, that you have a linear list and won't allow you to collapse sections, but that might be OK for you.


___________________
Try to take over the world!
Message 4 of 17
(3,531 Views)

Hi Thoric,

 

I don't think so but your question got me thinking... how about a different font... bar code font.

 

Don't waste time on that idea.

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 5 of 17
(3,525 Views)

You can get the coordinates and dimensions for a specific cell in the tree control, then move a progress bar to that location and set the size to match.  This is a lot easier if you don't have a scrollbar (you don't have to worry about moving it) but with some work you should be able to achieve the interface you want.

Message 6 of 17
(3,512 Views)

Hi tst and Ben,
Unfortunately I do need the tree for its collapsible capabilities (child items etc.)
I'll look into the barcode font idea, or perhaps some other font that has large blocks.
In the meantime I've been toying with capturing snapshots of a customised progress bar control in a subvi and placing the pictures strategically about the tree control. It just might work...

Thoric (CLA, CLED, CTD and LabVIEW Champion)


0 Kudos
Message 7 of 17
(3,510 Views)
Hi nathand,
Yes, I'm working on something not too disimilar to that which you've described. I'm hoping to have one single (transparent) picture control with images of various different progress bars on it, taken from a subvi snapshot. It's coming together - I'll post the results here if it works.
Thoric (CLA, CLED, CTD and LabVIEW Champion)


Message 8 of 17
(3,500 Views)

 


@Thoric wrote:

 

...but it does lack two elements I'm trying to maintain: aesthetics, and the superimposed text. It's not like the Window's style my client will be expecting, and I have ideas about the superimposed text which make it quite useful so I'd like to keep it.

Two solutions (?) - change the cell BG color to change its appearance (at least somewhat) and have the text as part of the text of the progress bar. You would probably also want to make the text bold.

 


___________________
Try to take over the world!
Message 9 of 17
(3,482 Views)

 


@tst wrote:

 

 

Two solutions (?) - change the cell BG color to change its appearance (at least somewhat) and have the text as part of the text of the progress bar. You would probably also want to make the text bold.

 


That is true, and I'll use those ideas if I have to revert to ASCII-character progress bar mock-ups, thanks.

 

Thoric (CLA, CLED, CTD and LabVIEW Champion)


0 Kudos
Message 10 of 17
(3,467 Views)