How can I declare a string with quotes in Actionscipt 3 like this:
var str1:String="(SayText "Hello world.")";
Some symbols like < can be taken care as <.quotes
Did you mean quotes instead of parenthesis? Your example string doesn't work because of the double quotes whithin your String.
You either have to escape the quotes within the String or you need to put the String within single quotes.
var str1:String = "(SayText \"Hello world.\")";
var str2:String = '(SayText "Hello world.")';