Highlighted

Create Object Array

Avatar

Guest

13-05-2008

I am trying to do a simple task that I thought would be very easy and quick to do but I have run into problems



I am trying to get the user to input a number and based on that number make a text field to become visible based on it. So if the user input 3 the first 3 textfields would become visible. I have 10 textfields and I don't need any error handling yet as I can do that later but this is my code:

var x=NumericField1.rawValue;



for(var i=0; i<=x; i++)



{



TextField1[i].presence="visible";



}



I think my problem is creating the object array as all I did was double clicked in the library to create the textfields and the names come up as TextField1 then in the grey shaded area right beside it is the number 0. The next one is called TextField1 with 1 greyed out beside it.

Can anyone help me out?

Thanks

Replies

Highlighted

Avatar

Guest

28-05-2008

SO IF YOU TRY IN JAVASCRIPT THIS WON'T WORK SO DO THIS IN "FORMCALC"

i=NUMIRICFIELD.RAWVALUE;

TextField1[i].presence="visible";



PLEASE DO THIS IN FORMCALC &FEEDBACK ME



MOAL4@WINDOWSLIVE.COM