Link to home
Start Free TrialLog in
Avatar of PSTCAT
PSTCATFlag for United Kingdom of Great Britain and Northern Ireland

asked on

1084 Syntax Error: Expecting rightparen before and.

In flash CS3 I am getting this error when trying to preview my project.

Here is my code:
 
System.useCodepage = true;
send_btn.onRelease = function() {
	my_vars = new LoadVars();
	my_vars.sender = email_box.text;
	my_vars.subject = subject_box.text;
	my_vars.message = message_box.text;
	if (my_vars.sender != "" and my_vars.subject != "" and my_vars.message != "") {		
                my_vars.sendAndLoad("mailer.php", my_vars, "POST");
		gotoAndStop(2);
	} else {
		error_clip.gotoAndPlay(2);
	}
	my_vars.onLoad = function() {
		gotoAndStop(3);
	};
};
email_box.onSetFocus = subject_box.onSetFocus=message_box.onSetFocus=function () {
	if (error_clip._currentframe != 1) {
		error_clip.gotoAndPlay(6);
	}
};

Open in new window


The error is for this line...

 if (my_vars.sender != "" and my_vars.subject != "" and my_vars.message != "") { 

Open in new window



I can't see an error there though....Any thoughts?

Thanks.
-Ben Toms
ASKER CERTIFIED SOLUTION
Avatar of Carnou
Carnou
Flag of United States of America image

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
Avatar of PSTCAT

ASKER

That's worked perfectly. Thank you!