Hi,
I want to display a table column in an automation script as a drop down so a user can select a value.
How do I display column 3 in a drop down if I don’t know what the key will be for the row?
I have no problem displaying other columns using GetTableDisplayKeys and GetTablePrimaryKeys but can’t seem to display column 3 for example.
I’m testing with GetTableKeyMappings but can only seem to store the indices in a variable rather than a table.
*edited to show table picture so it formats correctly*
I have a screen grab of the script to show some of what i've been testing but it may not be specifically useful!
Thanks,
Ross
Hi Ross,
Values of other columns can be retrieved with the "element. GetParameterByPrimaryKey()" method using the primary keys of the rows.
Example:
var keys = element.GetTablePrimaryKeys(8100);
foreach (var key in keys)
{
var cellValue = element.GetParameterByPrimaryKey(8102, key);
// do something with cellValue, i.e. adding it to a list
}
Thanks for the response Tom, much appreciated!