06-27-2014 01:30 PM
I am looking for ideas on how to impliment the following:
I am redesigning a program that will take data from Labview and place this data into an comma-delimited text file on another file server. One of my many "mini-projects" is to take a square and make it into a N x N square. Think of a large square that has smaller squares inside of it. There are two pieces if information that need to be handled & displayed on the U on each square: The identification number info and the samples value from a external serial device. I am having issues displaying the N x N square. I'd like to make this dynamically if possible. I want to start small, like a 2x2 square.
Has someone done something like this and if so, where do I even start?
Thanks,
Eric
Solved! Go to Solution.
06-27-2014 01:37 PM - edited 06-27-2014 01:41 PM
I really didn't understand what you meant by N x N square. Do you mean to form N number of rows and columns with some value? Please explain
If possible can you show a picture of what you are looking for?
06-27-2014 01:42 PM
You got it. I need to hold two pieces of information within each row and column:
I want to display both pieces if information on the UI; like a grid.
06-27-2014 01:44 PM
Start with a 2-D array of a cluster that contains the controls for the values you want to display. Use the "Replace Array Susbset" to place your data. It won't work if you specify a location that is out of bounds, so you'll have to pre-define your array size, first. (This may seem tricky at first, but you shouldn't have any problems obtaining this if you just think about it a little bit.) You can resize the array control to display all your data with the array property node.
06-27-2014 01:44 PM
The below VI should get you an idea although I do not like how it's implimented. Is there a better way?
06-27-2014 03:21 PM
billko,
I've been successful manipulatuing the columns and rows in my test vi, but how do I go about writing data to the Array Cluster? The VI is in 2012.
Thanks,
Eric
06-27-2014 03:52 PM
@Eric1977 wrote:
billko,
I've been successful manipulatuing the columns and rows in my test vi, but how do I go about writing data to the Array Cluster? The VI is in 2012.
Thanks,
Eric
You got the idea, but the control should be an indicator, since you want to display data. The input to that indicator will be your data. 🙂
06-27-2014 04:08 PM
Well, that's not necessarily true; at least for the string.
At times, my users will need to update the Mold ID string as molds get replaced and get saved back to a MS Access database to be used at a later date so I cannot use indicators as you suggested.
06-27-2014 04:59 PM
@Eric1977 wrote:
Well, that's not necessarily true; at least for the string.
At times, my users will need to update the Mold ID string as molds get replaced and get saved back to a MS Access database to be used at a later date so I cannot use indicators as you suggested.
Sorry, I just assumed that this was for information only. In that case, you can keep it as a control, but do the original data popualtion with a local variable. I'm not sure of your skill level. Do you already have a plan for the rest of the stuff?
06-30-2014 07:17 AM
I do. I am just not sure of how to populate the data per the Replace Array Subset like you suggested. When I try to add data to the Array Cluster, it does not appear to add any data.