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. QtIFW: Custom uninstall scripts
Forum Updated to NodeBB v4.3 + New Features

QtIFW: Custom uninstall scripts

Scheduled Pinned Locked Moved Unsolved Installation and Deployment
2 Posts 2 Posters 1.3k 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
    Schenk
    wrote on last edited by Schenk
    #1

    Hi,

    how can i call custom uninstall scripts for each component.
    I had two approaches:

    1. In the Component script:
    Component.prototype.createOperations = function()
    {
        component.createOperations();				
    	QMessageBox.information("asasas", "asasa", "Hall", QMessageBox.Ok);	
    		
    	if(installer.isInstaller()){
    		QMessageBox.information("asasas", "asasa", "isInstaller", QMessageBox.Ok);	
    	}
    	
    	if(installer.isUninstaller()){
    		QMessageBox.information("asasas", "asasa", "isUninstaller", QMessageBox.Ok);	
    	}		
    }
    

    The isInstaller-condition is called every time when i install my application. When i call the Maintanance-tool and remove everything, the isUninstalled-condition will not be called. Also the MessageBox with "Hall" is not called in the uninstaller.

    1. UNDOEXEC in the EXECUTE-command
      This does not work for uninstaller. I think i misunderstood this option.

    Thank you for your help.
    best regards

    UPDATE:
    UNDOEXECUTE works. But why is the isUninstaller-condition never called?

    RatzzR 1 Reply Last reply
    0
    • S Schenk

      Hi,

      how can i call custom uninstall scripts for each component.
      I had two approaches:

      1. In the Component script:
      Component.prototype.createOperations = function()
      {
          component.createOperations();				
      	QMessageBox.information("asasas", "asasa", "Hall", QMessageBox.Ok);	
      		
      	if(installer.isInstaller()){
      		QMessageBox.information("asasas", "asasa", "isInstaller", QMessageBox.Ok);	
      	}
      	
      	if(installer.isUninstaller()){
      		QMessageBox.information("asasas", "asasa", "isUninstaller", QMessageBox.Ok);	
      	}		
      }
      

      The isInstaller-condition is called every time when i install my application. When i call the Maintanance-tool and remove everything, the isUninstalled-condition will not be called. Also the MessageBox with "Hall" is not called in the uninstaller.

      1. UNDOEXEC in the EXECUTE-command
        This does not work for uninstaller. I think i misunderstood this option.

      Thank you for your help.
      best regards

      UPDATE:
      UNDOEXECUTE works. But why is the isUninstaller-condition never called?

      RatzzR Offline
      RatzzR Offline
      Ratzz
      wrote on last edited by Ratzz
      #2

      @Schenk said in QtIFW: Custom uninstall scripts:

      But why is the isUninstaller-condition never called?

      Because you never called the if condition in the constructor of Controller
      Refer Controller Scripting
      Use Controller Scripting as suggested in the 2nd comment https://stackoverflow.com/a/33170889

      Works for me
      alt text

      --Alles ist gut.

      1 Reply Last reply
      1

      • Login

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