Okay I've tried various things to try and get this to work, but all I've got so far is a not quite functionally useable script. The deletion script works beautifully, but while the row state script -works- it doesn't quite work the way I want it to, and I'm hoping there's a way to clean it up a bit.
dt << New Column ( "Row State 1",
Row State,
Set Formula ( If( :Alarm ID == "'00000D06", Color State(70))),
);
dt << New Column ( "Row State 2",
Row State,
Set Formula ( If( :Alarm ID == ("'000000B2"| "'000000BE"| "'0000013C"| "'0000013D"),
Color State(6))),
);
dt << New Column ( "Row State 3",
Row State,
Set Formula ( If( :Alarm ID == ("'0000000E"| "'00000144"| "'0000000A"| "'00000021"|
"'00000025"| "'00000027"| "'000000E9"| "'00000145"| "'000001E1"| "'00000F7C"),
Color State(1))),
);
dt << New Column ( "Row State 4",
Row State,
Set Formula ( If( :Alarm ID == "'00000E6E", Color State(38))),
);
dt << New Column ( "Row State 5",
Row State,
Set Formula ( If( :Alarm ID == ("'00000D3B"| "'00000230"| "'00000D42"), Color State(73))),
);
dt << New Column ( "Row State 6",
Row State,
Set Formula ( If( :Alarm ID == ("'0000003B"| "'00000072"| "'00000E8C"), Color State(37))),
);
dt << New Column ( "Row State 7",
Row State,
Set Formula ( If( :Alarm ID == "'00000DB6", Color State(78))),
);
dt << New Column ( "Row State 8",
Row State,
Set Formula ( If( :Alarm ID == "'00000E99", Color State(75))),
);
dt << New Column ( "Row State 9",
Row State,
Set Formula ( If( :Alarm ID == ("'00000E68"| "'00000E71"| "'00000E72"| "'00000E9A"),
Color State(72))),
);
dt << New Column ( "Row State 10",
Row State,
Set Formula ( If( :Alarm ID == ("'0000004E"| "'0000005C"| "'0000011C"| "'00000143"|
"'00000148"| "'000001D9"| "'00000DE9"| "'00000E41"), Color State(12))),
);
dt << New Column ( "Row State 11",
Row State,
Set Formula ( If( :Alarm ID == "'00000D2F", Color State(19))),
);
dt << New Column ( "Row State 12",
Row State,
Set Formula ( If( :Alarm ID == "'00000D2D", Color State(28))),
);
Basically, select row containing specific value in column Alarm ID and set the row state to the color selected. What I -want- it to do, is set the row state and highlight the row the color of the row state, presumably I can do that with an append after all the row states are set.
What this does, it creates a row state but doesn't apply it, I have to apply it manually, also it creates an individual row state for each line, which gets cluttered quickly, I suspect I may be able to use the else to at least remove lines that are not present, which would help. It also appears that the lines with multiple options is not actually working, I was hoping I could get that to work so I wouldn't have to make 1 line per code.
Hopefully someone can help me out, still plugging away at it when I get time, thanks!