A Component
is the atomic unit of install in the Windows installer so that is what you'll want to Condition
. Assuming the Directory/@Id
of the folder in question is AudioFiles
you could do something like:
<Component Id="cmpAUDIOFOLDER" Guid="PUT-GUID-HERE"
Directory="AudioFiles">
<!-- If the AudioFiles directory starts with a double backslash, it's a network
share, so share it with everyone. -->
<Condition>AudioFiles << "\\"</Condition>
<CreateFolder />
<util:FileShare Id="fsAudioFiles" Description="Audio files" Name="AudioFiles">
<util:FileSharePermission User="Everyone" GenericAll="yes" />
</util:FileShare>
</Component>