We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpOther Libraries › Loading XML with the Exported Application
Page Index Toggle Pages: 1
Loading XML with the Exported Application (Read 701 times)
Loading XML with the Exported Application
Jul 19th, 2007, 9:33pm
 
Hello,

I am just using the basic xml library to load in some simple variables, they set a stage size, grid size, etc... it all works fine when being run through processing but once I Export the Sketch as a Java Application the xml (and entire data folder) disappears and the application always takes on the values of when the application was exported.

Is there any way to leave the app configurable in this way? would proXML library do the same? is there something I'm doing wrong?

thank you,
Re: Loading XML with the Exported Application
Reply #1 - Jul 19th, 2007, 10:32pm
 
check out
http://processing.org/reference/environment/index.html#Sketchbook
for more information about how the data folder works. this is also available as the first item under the help menu, titled "getting started".

any xml file that you add to your sketch will be bundled with the sketch when exported.

in your case, if you don't want the file to be included, don't place it in the data folder, place it in the sketch's directory (next to the .pde file). then when you upload, you'll be able to change the file as you wish, because it won't be embedded in the jar file that is created on export.
Re: Loading XML with the Exported Application
Reply #2 - Jul 19th, 2007, 11:09pm
 
I took it out of the data folder and it works fine now. Thank you!
Re: Loading XML with the Exported Application
Reply #3 - Jan 23rd, 2008, 11:57pm
 
Hi

First post here and total programming newbie. Graphic Designer giving this a go.

I am trying to do this (as stated with the XML-file) with a .txt-file that I need to be accessed (and changed) after I export the application. I tried moving the file and changing the path to the .txt-file to:
1. outside the data folder
2. up yet another level (i.e outside the current sketch folder)
and it works fine while being in the PDE, but not after exporting the application.

Anyone?

Tried hard to find this by searching here and "manually" looking through different threads... And going through the EXCELLENT book Processing by Reas and Fry. Thanks a million for making this wonderful thing anyway!

Regards
/Johan
Page Index Toggle Pages: 1