Change TargetDirectory
Solved
Qt Creator and other tools
-
If user choose non-empty TargetDirectory, how I can change this line via adding subfolder?
For example, user choose in TargetDirectoryPage
TargetDirectoryLine = 'c:\Some'
I want in this case make something like
TargetDirectoryLineEdit.setText(targetDirLine + "/" + "ProductName")
and follow to install app to this folder 'c:\Some\ProductName'.
But I do not know how catch - when I can change TargetDirectory.
IFW 3.2
-
I did so:
Controller.prototype.ComponentSelectionPageCallback = function() { var targetDir = gui.pageById(QInstaller.TargetDirectory).TargetDirectoryLineEdit.text; var files = QDesktopServices.findFiles(targetDir, "*.*"); if (files.length!=0) { installer.setValue("TargetDir", targetDir + "\\" + installer.value("ProductName")); } }