load a Resource file template and search/replace a file
load a Resource file template and search/replace a file
- Subject: load a Resource file template and search/replace a file
- From: "Wayne Shao" <email@hidden>
- Date: Mon, 19 May 2008 00:28:29 -0700
Hi,
I would like to use some template (an XML file with some variables to be
replaced) in my Resources. At run time, I would like to load it and replace
the variables to produce a tmp file.
Newbie questions: Are there any good examples on how I should do the
following?
- load the template from resource file
- search and replace the file to produce another file.
- tmp file ( I know how to do this part).
My template file is an XML for a job description. It has two variables to
be replaced. e.g, INPUT_PATH, OUT_DIR will be replaced with real path.
<xml ....
<job>....
....
<file_path>INPUT_PATH</file_path>
.....
<output_dir>OUT_DIR</output_dir>
.....
</job>
Thanks,
--
Wayne Shao
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden