Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Can I include an xml with my Air android app?

New Here ,
Jan 12, 2021 Jan 12, 2021

I am trying to include an xml that will be installed with the android app so that my user can save their username in the xml. is there a way to achieve this. I tried including the xml in the publish settings but android is not reading the xml.

This is my xml load function if needed.

var File1:String = File.applicationDirectory.nativePath;
var xmlLoader = new URLLoader();
xmlLoader.load(new URLRequest(File1.split("/").join("\\") + "\\config.xml"));
xmlLoader.addEventListener(Event.COMPLETE, xmlLoaded);

function xmlLoaded(e:Event):void{
	loginPanel.rememberMe.enabled = true;
	myXML = new XML(e.target.data);
	if(parseInt(StringUtils.between(myXML.toString(),"<Saved>","</Saved>")) == 1)
	{
		loginPanel.rememberMe.selected = true;
		var User:String = StringUtils.between(myXML.toString(),"<User>","</User>");
		loginPanel.username.Input.text = User;
	}
}

 

TOPICS
ActionScript , Code , Tablet
319
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jan 16, 2021 Jan 16, 2021

Thank you Ill try you're suggestion and post back soon.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 05, 2021 Feb 05, 2021
LATEST

this ended up working perfect I just got it implemented last night thank you again

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines