SharedObject issue

Hi,

i have a crazy issue with ShareObject.
my preloader retrieve data from FlashVar and should forward them (thanks ShareObject) to my main swf file.

however, the main movie/swf file, receive no data as ShareObject.

here is the code of my preloader:


// retrieve data from FlashVars
var lng = root.loaderInfo.parameters.lng;
var theme = root.loaderInfo.parameters.theme;

//create the local Shared Object
var mySo:SharedObject    = SharedObject.getLocal("Settings");
var SoResult;

if(lng != null && theme != null)
{
    mySo.data._lg = lng;
    mySo.data._theme = theme;
    SoResult = mySo.flush();
}

here is my main mvie/swf file code which retrieve this ShareObject:


//create the local Shared Object
var mySo:SharedObject;
mySo = SharedObject.getLocal("Settings");
var lg:String;
var theme:String;

if(mySo.data._lg != null && mySo.data._theme != null)
{
    lg = mySo.data._lg;
    theme = mySo.data._theme;
}

but “lg” is undefined as also “theme” :frowning:
I’ve checked if data send to preloader via FlashVars were correctly received by my preloader and it’s ok.

So, where could be the problem ?

thanks a lot,

A.