Mitch Fawcett wrote: > An application I wrote requires its users to install a .prc and three .pdb > files filled with sample data. In order to make the install as foolproof as > possible I want to roll the .pdb data into the .prc so there is only one > file for the user to install. Then, when the user runs the program for the > first time, the data will be unpacked and put into the proper format.
Steve and Ben pretty much covered the DmCreateDatabaseFromImage option. Note that this only works with databases that fit in a single resource, so it's limited to 64K. As Ben pointed out, you'll end up with two copies of the data. Of course you could delete the resource from the app after you instantiate it, but you're still storing both temporarily, so you'll need some extra space. If any of your databases are larger than 64K, you can store the pdbs in parts and use ExgDBRead to instantiate the database from these parts. You could even delete the parts as you read them (much like the destructive read mode provided by FileStreams), but due to a bug in ExgDBRead, this won't help much. The temporary space requirement is similar to DmCreateDatabaseFromImage. Finally, there are third party products that you could use. I don't know the details, but I'd start by browsing PalmGear. Some of these tools are aimed at end users; others are aimed at developers. -- Danny @ Palm -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/tech/support/forums/
