Bugs item #1703013, was opened at 2007-04-18 07:40 Message generated for change (Comment added) made by heaths You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=642714&aid=1703013&group_id=105970
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: candle Group: v3.0 Status: Open Resolution: None Priority: 5 Private: No Submitted By: Lorne Laliberte (lornelaliberte) Assigned to: Nobody/Anonymous (nobody) Summary: IniFile @Directory doesn't support properties Initial Comment: The documentation for the Directory attribute says this: "Name of a property, the value of which is the full path of the folder containing the .ini file. Can be name of a directory in the Directory table, a property set by the AppSearch table, or any other property representing a full path." ...but the "any other property representing a full path" part doesn't seem to hold true. I've tried it using custom properties set using a Type 51 custom action, and I've tried it using system folder properties such as [WindowsFolder] and [ProgramFilesFolder], but both generate the same light error 94 (e.g. "Unresolved reference to symbol 'Directory:WindowsFolder' in section 'Fragment:'"). It will work if I add a <Directory> element for the folder property, but from the Windows Installer documentation it seems it should work for properties too. For example, if I use this: <IniFile Id="INIRemove" Action="removeLine" Directory="ProgramFilesFolder" Name="abc.ini" Section="MySection" Key="RemoveThis"/> ...it will only work if there is a corresponding entry like this: <Directory Id="ProgramFilesFolder" Name="ProgramFilesFolder"> According to the MSI docs, though, it should work even without that directory entry. ---------------------------------------------------------------------- Comment By: Heath Stewart (heaths) Date: 2007-04-19 08:00 Message: Logged In: YES user_id=1335104 Originator: NO I'm aware of the what the documentation says. The column type is an Identifier (also in the docs). The docs state a property - not a formatted stirng with a property in it. The Property table's Property column is also an Identifier. When Windows Installer bulds its directory tree, it does so using the Directory table but then each Directory can be treated as a property, which both type 51 (which only sets a *property*, BTW - notice the connection) and type 35 can set. [ProgramFilesFolder] is not an identifier or property, is a string with a property in it. ProgramFilesFolder is the property identifier, which also is the directory identifier you need to define in the Directory table. Again, this is further supported by the fact I said before: a directory cannot have a NULL parent except for TARGETDIR. Thus, even your standard directories like ProgramFilesFolder have to be authored in, but Windows Installer will resolve those directories to shell locations. ---------------------------------------------------------------------- Comment By: Lorne Laliberte (lornelaliberte) Date: 2007-04-19 07:44 Message: Logged In: YES user_id=1705700 Originator: YES See the "a property set by the AppSearch table, or any other property representing a full path" part. The MSI documentation for DirProperty indicates the same thing by the way -- which sounds to me that you should be able to use the identifier of any property that resolves to a full path. In other words, thanks, but I know what the current limitation in Wix is, my point is that the restriction is incorrect. :) It should either support both, or it should be handled more like the other tables with DirProperty columns (e.g. CopyFile, RemoveFile) which have a Property attribute in addition to the Directory attribute. ---------------------------------------------------------------------- Comment By: Heath Stewart (heaths) Date: 2007-04-18 16:16 Message: Logged In: YES user_id=1335104 Originator: NO The IniFile table's DirProperty is of type Identifier, not Formattable or its derivatives, which means you'd put in ProgramFilesFolder instead of [ProgramFilesFolder], for example. Even then, the ProgramFilesFolder must exist in your Directory table. So, as such, WiX requires that you author it so that the ProgramFilesFolder ends up in the Directory table and Windows Installer can build the directory tree. Rows in the Directory table can't have a foreign key to a parent that doesn't exist in the Directory table. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=642714&aid=1703013&group_id=105970 ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ WiX-devs mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/wix-devs
