Multi Commander > Script

Script Documentation Updated

(1/2) > >>

Mathias (Author):
The Documentation for the new MultiScript functions added in v4.3 and for some other that was added before are now updated.

ArraySort

UnpackFile
PackFile
MakeDir
FileExists

PathMakeRelativeMC
PathMakeAbsoluteMC
PathTranslatePath

TranslateEnvString

ChkSum_Calculate

Also the list with all the Custom Commands have been updated

Ulfhednar:
Excellent, look forward to trying these functions.  8)

Do you intend to add the 'overwrite' function to the custom commands?  Or are the more 'advanced' options restricted to MS?

Mathias (Author):
Maybe in the future. But for now it is not possible because the CustomCommands are using the functions from the 'middle' layer (same way the UI talk to the engine) and there is no way to set that yet.

Ulfhednar:
I suspected that might be the case.  I guess it doesn't matter if one has a script assigned to a button  ;)
I altered what we discussed before http://forum.multicommander.com/forum/index.php/topic,1200.0.html to use the script unpack command & being able to call the unpack function with these options works very well.


--- Code: ---// get & extract zips
@var $root = GetSourcePath();
@var $arrFiles = FindFiles( $root + "*.zip");
@var $count = arrayCount($arrFiles);
@var $zipFiles = "";
@var $zip;
@var $n1;

// Create ; separated list with all zip files to unpack
for( $n1 = 0; $n1 < $count ; $n1++ )
{
 $zip = $arrFiles[ $n1];
 $zipFiles += $zip;
 $zipFiles += ";";
UnpackFile( $zip, $root, "*.*" , "OVERWRITEALL, USEEXISTINGQUEUE" );
}
--- End code ---
Thanks for expanding the scripting side, as I slowly learn it, it gets more & more useful.

With TranslateEnvString is this only for returning the OS environment or can it be used with other things.  I am trying to imagine how it can be used...

Mathias (Author):

--- Quote from: Ulfhednar on June 18, 2014, 11:32:01 ---With TranslateEnvString is this only for returning the OS environment or can it be used with other things.  I am trying to imagine how it can be used...

--- End quote ---
Other things ? no it is if system Environment string like %PATH% , %WINDIR% and all other you see in a command prompt when typing "set"

Navigation

[0] Message Index

[#] Next page

Go to full version