Link to home
Start Free TrialLog in
Avatar of Curtis Shull
Curtis ShullFlag for United States of America

asked on

loadVariables syntax error?

I cannot seem to find the syntax error that Flash's debugger is complaining about.

**Error** Symbol=menu, layer=Layer 1, frame=1:Line 18: ')' or ',' expected
         loadVariables("GetDetails.asp?Record=" add String(CurrentRecord), this)

Total ActionScript Errors: 1        Reported Errors: 1

The loadVariables statement worked fine in Flash 7 - soon as I converted to 8 this error surfaced. Any help is appreciated.

Avatar of Curtis Shull
Curtis Shull
Flag of United States of America image

ASKER



I tried this too!

**Error** Symbol=menu, layer=Layer 1, frame=1:Line 18: ')' or ',' expected
         loadVariables("GetDetails.asp?Record=", add String(CurrentRecord), this)
Avatar of jack_p50
jack_p50

the "add" operator is now deprecated. to add two strings use the "+" operator. in your case:
loadVariables("GetDetails.asp?Record=" + String(CurrentRecord), this)
loadVariables("GetDetails.asp?Record=" + String(CurrentRecord), this);
seifip i posted the same line
sry... havent read it before =D
For string concatenation, Flash MX still supports "add". But Flash 8 no longer does, use "+".

However, that error sounds more like you for got to close a ")" on a previous line.

Check whatever has "( )", just before the loadVariables(). Either an "if" statement, function call, or function header. And just make sure all the parentheses are closed.

Cheers
MuXx
ASKER CERTIFIED SOLUTION
Avatar of seifip
seifip

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial