0

I am creating a Setup for my .Net Application using WIX. I want to check the existence of a file before installing my WIX SET UP as a Dependency. If that file not exist then a message should be displayed. Any help would be appreciated.

Kara
  • 6,115
  • 16
  • 50
  • 57
User
  • 351
  • 1
  • 8
  • 20

1 Answers1

1

To check for the existence of a file you can use the FileSearch-element in combination with the DirectorySearch-element. For an example you can take a look at How To: Check the Version Number of a File During Installation (you don't have to use the version part for your needs).

For displaying the dialog you can create your own SpawnDialog like described here. Another alternative would be to add the text as property to the Welcome-dialog and set the property based on your findings. Still another way would be to include a second Welcome-dialog and then invoke the needed one as described in this stackoverflow-question.

Community
  • 1
  • 1
taffit
  • 1,979
  • 22
  • 23