dcsimg
A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: [RESOLVED] IF statement - AS2 Migration

  1. #1
    Member
    Join Date
    Jul 2007
    Posts
    77

    resolved [RESOLVED] IF statement - AS2 Migration

    Simple problem... hopefully

    Code:
    var newVar1 = 1
    var newVar2 = 4
    
    if((newVar==1)and(newVar2==4)){
    	trace("hello world")
    }
    the above works in AS2 but not AS3... what am I missing?

    www.ugonna-nwosu.com
    If at first you don't succeed... Try not to look suprised.

  2. #2
    Will moderate for beer
    Join Date
    Apr 2007
    Location
    Austin, TX
    Posts
    6,801
    You are missing the fact that you should have told us what the error message was.

    Also, try using "&&" instead of "and".

  3. #3
    Member
    Join Date
    Jul 2007
    Posts
    77
    works. thanks
    www.ugonna-nwosu.com
    If at first you don't succeed... Try not to look suprised.

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