Helpful RTFM pointers greatfully accepted.
Temporary files
Posted 21 February 2001 - 00:23
Posted 22 February 2001 - 00:56
"If this column is null the installer does not register the component and the component cannot be removed or repaired by the installer. This might be intentionally done if the component is only needed during the installation, such as a custom action that cleans up temporary files or removes an old product. It may also be useful when copying data files to a user's computer that do not need to be registered. "
Despite the earlier comments in the article on the Component Table, the ComponentID *is not* the primary key for the table. It is not even included in the key.
With regard to the Binary Table, I have been able to insert text files into the Binary Stream as readily as EXE files. Once they are in there, you can use the MsiDB.exe tool to dump them back out to known locations. I have not yet tried this from a custom action, but it may be possible to enumerate through the _Streams Table to locate your data and then use MsiRecordReadStream to put the contents into a buffer.
Also, depending on the structure of your table, you can design your own custom tables and import them directly into the MSI database. So long as you follow the standard method of defining columns and have the format lines of the IDT file correct, you should be able to put virtually *any* tab delimited text file into a table that you can import to the MSI database. Then, if you want to, you can edit the column entries with ORCA. The table won't relate to others in the scheme of things, but your data will be there. If you do this, you can use the MsiDatabaseExport to dump the table back out to an IDT file, strip off the format lines, and have your data available for use. You will have to be a little careful about how you name your columns so that you don't run afoul of the referential integrity checks.
I imagine you have already thought about passing the data as command line arguments.
Please let me know if you have any questions about these methods. I have not tested all of them exhausively.
Posted 22 February 2001 - 13:48
Quote |
use MsiRecordReadStream to put the contents into a buffer. |
If you are using InstallShield, an InstallScript function StreamFileFromBinary can be found somewhere in the samples folder.