A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: Dynamically Create Variable

  1. #1
    Member
    Join Date
    Apr 2002
    Posts
    49
    Hi all,
    Is there any way for me to create a variable dynamically with the variable name given dynamically.
    For example,
    I need to create a variable where the variable name is retrieve from value input into input box by user.

  2. #2
    Member
    Join Date
    Apr 2002
    Posts
    49
    I had found out the solution,
    anybody wish to know can refer example given below:

    var name="eg";
    this[name] = "try"; //this.eg = "try"
    trace(eg);

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center