Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Change TargetDirectory

Change TargetDirectory

Scheduled Pinned Locked Moved Solved Qt Creator and other tools
installer frameinstaller fw
2 Posts 1 Posters 719 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    Vitali
    wrote on last edited by Vitali
    #1

    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

    1 Reply Last reply
    0
    • V Offline
      V Offline
      Vitali
      wrote on last edited by
      #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"));
        }
      }
      
      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved