Welcome to WebmasterWorld Guest from 54.226.189.112

Forum Moderators: open

Message Too Old, No Replies

Variable Instance Names

Use a variable as an instance name.

     

MartinWeb

2:42 pm on Aug 29, 2009 (gmt 0)

5+ Year Member



Hello. I am attempting to use a variable in an instance name.

platforms=1;
while(platforms<3){
platformNum = "platform"+platforms;
platformX=_root.var(platformNum)._width;
}

I attempted the above code, but I am told that a '.' is expected after the operator. If you have any ideas, please help. Thanks.

 

Featured Threads

Hot Threads This Week

Hot Threads This Month