Curious about getting external variables into flash

I am curious how to pass variables into flash, I didnt want to just cold ask so I tried to do a little research. I just wanted some reinforcement weather these are the only ways

**1 - Getting from query string
***var sVar1:Object =”getQueryParamValue”, “var1″);

**2 - Passing at time of creation of swf w/ javascript
****var so = new SWFObject(”movie.swf”, “flashMovie”, “250″, “150″, “8″, “#FFFFFF”);
so.addVariable(”var1″, getQueryParamValue(”var1″));
so.addVariable(”var2″, getQueryParamValue(”var2″));