untelon
05-15-2007, 07:23 PM
Hello.
So, again, I am at a stand still and would appreciate any help. Here's the situation. I have a UI that generates controls based on an array... call it a dynamic UI. So if my array has 5 elements (which happen to be integers), 5 intField controls are created, and so on.
Certain validation needs to occur when a user changes the value of each of these integers. I use a call to -cc "validateData()". Each intField is given a unique name (made up like so : string $range = "entryPoint" + $x; where $x is a counter etc.). In the form it looks like so:
intField -v $someValue[$x] -cc "valiateData()" $range;
All of these works fine... But here's my problem. When -cc is invoked, I cannot tell which one of the intFields a change occurred to. I tried passing $x or the string that defines the filed's name as an argument that would reveal the affected element's identity, but $x is 0 (which makes sence after the creation of the UI), and $range gives me a "string not declared" error.
So here's my question:
How do I know which element in my UI was modified when the elements were dynamically created? (Without having to check each one, of course). Is there a "call back, parent, or id that I could query?
Thanks much.
Jim
So, again, I am at a stand still and would appreciate any help. Here's the situation. I have a UI that generates controls based on an array... call it a dynamic UI. So if my array has 5 elements (which happen to be integers), 5 intField controls are created, and so on.
Certain validation needs to occur when a user changes the value of each of these integers. I use a call to -cc "validateData()". Each intField is given a unique name (made up like so : string $range = "entryPoint" + $x; where $x is a counter etc.). In the form it looks like so:
intField -v $someValue[$x] -cc "valiateData()" $range;
All of these works fine... But here's my problem. When -cc is invoked, I cannot tell which one of the intFields a change occurred to. I tried passing $x or the string that defines the filed's name as an argument that would reveal the affected element's identity, but $x is 0 (which makes sence after the creation of the UI), and $range gives me a "string not declared" error.
So here's my question:
How do I know which element in my UI was modified when the elements were dynamically created? (Without having to check each one, of course). Is there a "call back, parent, or id that I could query?
Thanks much.
Jim
