I am searching for Notepad in 2 locations like this: <Property Id='NOTEPADEXE'> <DirectorySearch Id='NotePadContainer' Path='[WindowsFolder]' Depth='0'> <FileSearch Id='NotepadFileWin' Name='notepad.exe'/> </DirectorySearch> <DirectorySearch Id='NotePadContainer' Path='[SystemFolder]' Depth='0'> <FileSearch Id='NotepadFileSys' Name='notepad.exe'/> </DirectorySearch> </Property>
On most systems Notepad is in both locations so property is initialized to the location of the last find, As shown here in MSI log: AppSearch: Property: NOTEPADEXE, Signature: NotepadFileWin MSI (c) (E0:58) [11:27:24:164]: PROPERTY CHANGE: Adding NOTEPADEXE property. Its value is 'C:\Windows\notepad.exe'. AppSearch: Property: NOTEPADEXE, Signature: NotepadFileSys MSI (c) (E0:58) [11:27:24:165]: PROPERTY CHANGE: Modifying NOTEPADEXE property. Its current value is 'C:\Windows\notepad.exe'. Its new value: 'C:\Windows\system32\notepad.exe'. Action ended 11:27:24: AppSearch. Return value 1. Questions: can I and how can I avoid searching another location if program was already found in one location? If file was found in the first location but not in the second, would it cause the property to be unset? Thanks for any input! ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users