LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

modifying index display of array

Hi all,
 
I have written an UI (LV7.1) that communicates with a controller which can handle many identical devices. Because the number of connected devices is unknown I choose to put the controls of the devices into an array of clusters. I use an event structure where I check for changes in one of the values of the array. This works fine. The only thing that I would like to change is the index display of the array for the simple reason that the first element of the array has index 0 whereas the first device connected to the controller has ID 1. This causes confusion for the user.
 
What would be the best workaround? I assume that there is no way to let the index display start at 1. Should I hide the index display and replace it by a numeric controller connected to an event case that writes the appropriate index number to the Index Values property node? Ore are there easier solutions?
 
Ture
LV7.1
Message 1 of 5
(3,413 Views)


@ture wrote:
Should I hide the index display and replace it by a numeric controller connected to an event case that writes the appropriate index number to the Index Values property node? Ore are there easier solutions?

This is probably the easiest solution.

You could also add an extra element to the cluster that contains the correct device ID so the array index does not need to be abused for this. Now you can hide the array index and e.g. simply show the array scroll bar, for example.

Message 2 of 5
(3,411 Views)
Isn't the array scroll bar a feature of LV8.x?
 
Ture
LV7.1
Message 3 of 5
(3,403 Views)


@ture wrote:
Isn't the array scroll bar a feature of LV8.x?
 
Ture
LV7.1



A bold YES ! The scrollbar for Array is a feature of LV 8 & up only.

Anyway, you had already arrived at the correct destination. Smiley Wink

Use a Numeric control that starts at 1 for the Array Index Display.

- Partha ( CLD until Oct 2027 🙂 )
0 Kudos
Message 4 of 5
(3,382 Views)
You can have a scrollbar in 7.x by customizing the array, but it doesn't usually work perfectly.

___________________
Try to take over the world!
Message 5 of 5
(3,373 Views)