Topic: Plugin Syntax - %ProgramFolder%  (Read 361 times)

0 Members and 1 Guest are viewing this topic.

Plugin Syntax - %ProgramFolder%
« on: September 25, 2017, 12:07:08 AM »

bob.omb

  • Chef
  • ***
  • Location: USA
  • Date Registered: Jul 2017
  • Posts: 179
Is there any way to set this to the root of the drive? 

Code: [Select]
[Variables]
%ProgramTitle%=Malwarebytes Toolset
%ProgramEXE%=MBTSLauncher.exe
%ProgramFolder%=Malwarebytes Toolset_Prg
%SetupFile%=%SetupFilex86%
%SetupFilex86%=Malwarebytes Toolset.7z
%SetupFilex64%=Malwarebytes Toolset.7z

I tried the following but error occurred during build

Code: [Select]
[Variables]
%ProgramTitle%=Malwarebytes Toolset
%ProgramEXE%=MBTSLauncher.exe
%ProgramFolder%=.\
%SetupFile%=%SetupFilex86%
%SetupFilex86%=Malwarebytes Toolset.7z
%SetupFilex64%=Malwarebytes Toolset.7z

Re: Plugin Syntax - %ProgramFolder%
« Reply #1 on: September 25, 2017, 04:19:55 AM »

Lancelot

  • Gena Baker
  • Grand Chef
  • *****
  • Date Registered: Sep 2010
  • Posts: 7529
Is there any way to set this to the root of the drive? 

You can, but NOT a good idea.

you have to work on [Process] section, practice with syntax, it works same with batch files (.cmd) , line by line.

with
%ProgramFolder%=Malwarebytes Toolset_Prg

replace these lines
Code: [Select]
If,Not,ExistDir,%Target_Prog%,DirMake,%Target_Prog%
If,ExistDir,%Target_Prog%\%ProgramFolder%,Shellexecute,Hide,cmd.exe,"/C rd /s /q #$q%Target_Prog%\%ProgramFolder%#$q"
If,ExistDir,%Target_Prog%\%ProgramFolder%,Call,DirDelete,%Target_Prog%\%ProgramFolder%
DirCopy,%ProjectTemp%\TempExtractFolder\%ProgramFolder%\%ProgramFolder%,%Target_Prog%

Code: [Select]
If,Not,ExistDir,%TargetDir%,DirMake,%TargetDir%
If,ExistDir,%TargetDir%\%ProgramFolder%,Shellexecute,Hide,cmd.exe,"/C rd /s /q #$q%TargetDir%\%ProgramFolder%#$q"
If,ExistDir,%TargetDir%\%ProgramFolder%,Call,DirDelete,%TargetDir%\%ProgramFolder%
DirCopy,%ProjectTemp%\TempExtractFolder\%ProgramFolder%\%ProgramFolder%,%TargetDir%

+
You also need to fix shortcut for new location.....
or maybe better not to create at all.....

+
and no need ScrollBox_RunFromWhere since you override....


**
Tip:
There are some Malware plugins on server:
Downloads\AppYGS\Security\Antivirus\Malware ....

**
Tip:
There is small green play button on plugins to test,
and see log how it works.


****
Overall, unless it is a special case, it is NOT a good idea at all.
« Last Edit: September 25, 2017, 05:27:49 AM by Lancelot »

 

Powered by EzPortal