I want to have a dynamic variable in actionscript //skey is a label which should contain the xml node VALUE skey.text = 'reftables_additem_load_dataprovider.lastResult.DATARESULTS.VER_DATA.' + stringfunctions.toString(); Alert.show(skey.text);
Currently it shows reftables_additem_load_dataprovider.lastResult.DATARESULTS.VER_DATA.VEHI\ CLE_SKEY which is correct behavior but now how do i use that text as a dynamic variable like? heres my current code var stringfunctions:String = new String(); var searchfor_skey:Number = new Number(); stringfunctions = columnData.field; //search for primary key searchfor_skey = stringfunctions.indexOf("SKEY", 0); if(searchfor_skey != -1){ //we got the skey column now store the value in the text box for http service later when saving ! skey.text = reftables_additem_load_dataprovider.lastResult.DATARESULTS.VER_DATA. + searchfor_skey.toString(); Alert.show(skey.text); //shows just string Alert.show(reftables_additem_load_dataprovider.lastResult.DATARESULTS.VE\ R_DATA.VEHICLE_SKEY); //WORKS showing value? }