flash can communicate with flash through fscommand function call which looks like something like
Code:
//flash program
trace(fscommand("getScreenWidth"));
//JavaScript program
fscommand(arg) {
if (arg == "getScreenWidth") {
return screen_width_resolution;
} else if (arg == "getScreenHeight") {
return screen_height_resolution;
}
}
of course, you have to get the value of the screen resolutions for the JavaScript program...