Rob van der Woude's Scripting Pages

News Archives 2019


[ Back to the current news page... ]


• I added a note on CALL's unexpected escaping behaviour: it automatically inserts escape characters even in doublequoted strings.
• I added a fix by Martin Brinkmann for Thunderbird mail not opening links to my Tweaks page.

Thanks Martin
• A minor update for MessageBox.exe: its help text has been modified, because the old text was not clear enough about unescaping text for linefeeds.
WMIGen.exe has been updated: it now has an integrated WQL Query Editor.
WMIGen's integrated WQL query editor
• A bug in WMIGen.exe's MSDN search for methods has been fixed.
• When I had to install Windows 10 on my wife's computer I decided to not reinstall Wordperfect. I first converted all WordPerfect documents to Word documents with WordPerfect and WPD2Doc.vbs, next I installed Windows 10 (and not WordPerfect), and finally I wrote WPD.exe and registered it for the .wpd extension (WordPerfect Documents).
Now whenever my wife doubleclicks a WordPerfect document, WPD.exe searches the folder for a Word document with the same name, and opens that Word document instead.
If more than one matching Word documenty is found (e.g. a *.doc and a *.docx) a popup warning message is displayed.
WMIGen.exe has a new feature: you can now limit the generated code and query results to one or multiple selected properties only.
New command line switches allow you to choose how to select and deselect properties, see the program's Help for details.
• Henry Nettles reported a bug (and proposed the solution) in DropDownBox.exe: the checks for duplicate arguments that I had modified at the last minute were causing error messages when using one of the /R* switches.

Thanks Henry
• A minor update to GetHDDStatusGUI.ps1: when started, it will hide the console, and when finished it will restore the console (but minimized).
GetHDDStatusGUI.ps1 is a new Windows-only GUI version of GetHDDStatus.ps1.


• A tiny update for GetHDDStatus.ps1: credits for the icon extraction by Thomas Levesque were added.
LoginDialogWinForm.ps1 is a new script demonstrating the use of Windows Forms in PowerShell.
It was built with the help of the PoshGUI form editor.
Of course, for login dialogs in PowerShell, you wouldn't want to create your own form, rather use PowerShell's built-in Get-Credentials cmdlet, demonstrated in LoginDialog.ps1.


• I added an example of batch code using on-the-fly PowerShell code to show a MessageBox.
• Darin Schnetzler found a reliable way to use complex one-liners in batch files, e.g. run several commands, and jump to error handling code at the first failure:
(command1) && (command2) && (command3) || (ECHO Error)
This is explaned on my Conditional Execution page.

Thanks Darin
• On my batch file comments page, some code was shown where a comment would mysteriously break a batch file.
Vasco Rato sent me the explanation. As always: quite logical, once you've seen it.

Thanks Vasco
• Recommended reading: The ultimate guide to desktop Linux security by Jon Watson
• Another update for Shell32Icons.exe: besides the small icon in its title bar and the large icon in its main window, the new version also shows the selected icon in the System Tray (a.k.a. Notification Area).
• Another update for GetHDDStatus.ps1: in Linux the desktop notification was unpredictable at best, because the notify-send command cannot send notifications to other users, whereas the script requires root access to check the disks.
The solution is to start the new version without root acces; the script will restart itself with root access, and create a temporary shell script with the notify-send command; the temporary script will then be run by the original non-root script.
Shell32Icons.exe, a tool to view and select available icons in shell32.dll, had a major update: besides the small icon in its title bar, it now also displays the large icon in its window.


GetHDDStatus.ps1 had a major update: not only will it show the disk status in the console, but as a system tray message/desktop notification as well.
• The previous release of DialogBoxes.dll proved to be less final than I had expected...
Wolfgang Struensee found a lot of errors, especially in the sample code provided by the DLL itself.
So a new almost final beta release is available, version 0.18.
Each dialog now has a SampleCode( ) method, to provide a demo in VBScript. I used this for testing this latest release, the test script __test_sample_code.vbs is included in the download.
Each dialog's Help( ) function now also accepts an optional integer argument (0 for false, 1 for true) to provide the help text in HTML format instead of plain text, i.e. Help( 1 ) to get help text in HTML.

Thanks Wolfgang
Bin2Vbs.vbs, a script to convert a binary file to VBScript that can recreate that binary file, had a major update.
Whereas the first version would read a binary file 1 byte at a time, and then update the "recreation script" for 1 byte at a time, the new version reads 1024 byte before updating the script for these 1024 bytes all at once.
It may well be possible to process larger chunks, but VBScript has a line length limit, and I would rather keep on the safe side.
The larger chunks make the creation of the "recreation script" much faster, the main effect on the "recreation script" itself is not speed but size: about 70% size reduction compared to the old version!
And as an added bonus, the new "recreation scripts" also restore the file's timestamp.
• The  final  not so final beta version of DialogBoxes.dll has been released.
All dialogs are available as COM-visible classes, with additional "wrapper" functions for those who prefer a "classic command line approach".
Each dialog has its own Help( ) method, with a brief description and a list of properties and methods, plus VBScript sample demo code.
The common methods CheckUpdate( ) and Credits( ) and ListProperties( ) can be accessed from any of the DialogBoxes objects.
• The latest version of DialogBoxes.dll includes ColorSelectBox and SystemTrayMessage.
• To correctly show the VBScript generated help for DialogBoxes.dll in its web page, I wrote UTF8removeBOM.exe, which removes the BOM from a UTF-8 encoded text file.
• The DialogBoxes DLL for COM scripting now has its own project page.
The planned fourth beta has become an alpha version:
I started rewriting the code for each dialog, steering away from the "classic" command line approach, as used in VBScript's native MsgBox( ) function.
Instead, the new version uses a "class approach", where you can set properties by name (or not set them if the default property value is acceptable).
After registering the DLL with the accompanying DialogBoxes.rereg.bat you can get extensive help, including sample scripts, using the following VBScript code:
Set objDateTimeBox = CreateObject( "RobvanderWoude.DateTimeBox" )
WScript.Echo objDateTimeBox.Help( )
Set objDateTimeBox = Nothing

Set objDropDownBox = CreateObject( "RobvanderWoude.DropDownBox" )
WScript.Echo objDropDownBox.Help( )
Set objDropDownBox = Nothing

Set objFontSelectBox = CreateObject( "RobvanderWoude.FontSelectBox" )
WScript.Echo objFontSelectBox.Help( )
Set objFontSelectBox = Nothing

Set objPrinterSelectBox = CreateObject( "RobvanderWoude.PrinterSelectBox" )
WScript.Echo objPrinterSelectBox.Help( )
Set objPrinterSelectBox = Nothing
FontSelectBox.exe has been updated: today I finally understood the purpose of the "scriptsonly" property, and modified the help text accordingly.
• The third beta of DialogBoxes DLL for COM scripting is available.
InputBox has been added, input validation has been improved, GetHelp( ) function gives even more details, and MaskLanguageTable( ) has been added to display available mask options for InputBox.
• The second beta of DialogBoxes DLL for COM scripting is available.
Besides the MessageBox and DropDownBox dialogs, the PrinterSelectBox has been added too.
And the GetHelp( ) function gives more details about each dialog's arguments and returned strings and the DLL's helper commands.
• Happy New Year! May all your happy dreams come true!
(Picture, by yours truly: Grey heron and Cumberland slider side by side in the Botanic Garden of Zaandam, Netherlands, this Christmas)



Archived News pages
Archived news from 2018
Archived news from 2017
Archived news from 2016
Archived news from 2015
Archived news from 2014
Archived news from 2013
Archived news from 2012
Archived news from 2011
Archived news from 2010
Archived news from 2009
Archived news from 2008
Archived news from 2007



page last modified: 2020-02-05; loaded in 0.0561 seconds