Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. QT Installerframework is altering my string slashes
QtWS25 Last Chance

QT Installerframework is altering my string slashes

Scheduled Pinned Locked Moved Unsolved Installation and Deployment
installer fw
1 Posts 1 Posters 418 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.
  • S Offline
    S Offline
    Sally
    wrote on 19 May 2020, 13:55 last edited by Sally
    #1

    Hi,

    I'm trying to creating a bundle for my software with the QT installer framework. I have a couple of .msi files that I want to install and everything goes fine during installation.

    However when i try to uninstall these .msi files with the maintaincetool I get the following error:
    Created warning message box "installationErrorWithRetry": "Installer Error", "Error during uninstallation process:\nExecution failed (Unexpected exit code: 1619): "msiexec /x C:/Program Files (x86)/Company/Repository/Installer/Setup.msi /q"" .

    Noticeable is that the string does use the correct windows style slashes during the installation as seen below:
    [7042] - arguments: msiexec, /i, C:\Program Files (x86)\Company\Repository\Installer\Setup.msi, /passive, HOST_ID=200, UNDOEXECUTE, msiexec, /x, C:\Program Files (x86)\Company\Repository\Installer\Setup.msi, /q

    I made the following script for instalation:

    // Utility function like QString QDir::toNativeSeparators(const QString & pathName) [static]
    var Dir = new function () {
        this.toNativeSeparator = function (path) {
            if (installer.value("os") == "win")
                return path.replace(/\//g, '\\');
            return path;
        }
    };
    
    function Component()
    {
    }
    
    Component.prototype.createOperations = function()
    {
    	component.createOperations();
    							
    	var packageInstaller =  Dir.toNativeSeparator(installer.value("TargetDir") + "/Installer/Setup.msi") ;	
    	
    	component.addElevatedOperation("Execute", "msiexec", "/i", packageInstaller, "/passive", "HOST_ID=200", 
    									"UNDOEXECUTE", "msiexec", "/x", packageInstaller, "/q" );
    }
    

    I would like to use the msi file to uninstall the program and not the GUID as posted in this thread: using-msi-files-in-qt-framework-installer

    1 Reply Last reply
    0

    1/1

    19 May 2020, 13:55

    • Login

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