Copyright: ® Mark Kiehl


Help Contents
Contents

Basics

Summary

Features

Installation

Reference Information

The INI File: WLM.INI

The License Tracking File: WLM.LIC

The Log File:  WLM.LOG

The Menu Configuration File:  WLM.CFG

Program Limitations

Known Problems/Bugs

Version/Revision History

File Descriptions

Disclaimer

Acknowledgments


Summary

WLM is a menu program for Windows which is designed to replace program manager and provide program usage tracking and restriction capabilities for local area networks.  The programs may be installed locally, on the fileserver, or both.  You specify the number of licenses allocated for each program, even unlimited.  Software access denials are logged to a file for documentation.  Works with all programs written to run in the Windows environment and DOS applications via. PIF files.  Automatically recovers license counts when a user reboots a PC.  Supports automatic startup of programs (like Program Managers startup group) and much more!  It is provided as is for free and is considered Freeware.  Feel free to distribute to anyone as long as it is distributed complete with all files and documentation.


Features

WLM should work on any local area network simply because it does not use any network specific features.   Most license agreements state that you may install the software on as many PC's as you like as long as the software cannot be used at more than one place at any one time (like a book).  WLM is designed to satisfy that restriction, but also provides the capability to not restrict a particular application if necessary.  WLM could be setup to run on a PC not connected to a LAN if you happen to like the drop down menu access better than Program Managers icons.  Users of a particular program which has just been denied access to another user will be notified that another user is waiting to use it.  This is helpfull reminder for those users who load everything and do nothing.

You may place a separator bar between drop down menu items in order to group them.    Menu items can be disabled easily within WLM.CFG (grayed out visibly in menu) for each PC individually, or from a centrally located single file depending on your installation.  Modification of the menu items may be disabled on a per installation basis (for those annoying users who just can't keep their hands off anything but real work).

The 'About' menu selection will show the amount of both the USER and GDI resources (Program Manager doesn't do that!) and the amount of total free RAM in Windows.  The title bar of WLM will blink to warn the user if a pre-specified minimum amount of resources or RAM is exceeded.

A 'File Run' menu item allows users to run software not included in the menu, but also prevents them from running any software monitored by the menu program (listed in the WLM.LIC file).  You may also install programs using this command.

Allows automatic load of programs on startup (like Program Manager's startup group).  You may specify the application to load as minimized or maximized, with & without focus.

When you exit WLM.EXE any currently running applications are unloaded and you are given the option to save the current data for each application if necessary.  You will not get a special window which pops up and confirms that you want to exit like Program Manager does (annoying).


Installation

The setup.exe program included will install WLM.  The following are the manual instructions for installation which can be used to troubleshoot problems.

Edit and replace the line SHELL=PROGMAN.EXE with SHELL=WLM.EXE in the SYSTEM.INI located in the windows directory with Notepad, edlin or any other ASCII editor.

Copy WLM.EXE and WLM.INI to the Windows directory (i.e. c:\windows).

Copy XTASK.DLL and VBRUN300.DLL to the Windows SYSTEM directory (usually

C:\WINDOWS\SYSTEM).  This is where all *.DLL files are normally located.

Create a read/write/sharable directory on the fileserver which is available to everyone at all times.  Copy the license tracking file (WLM.LIC) to this directory.  Edit the LicenseFile=statement in WLM.INI to reflect its location.  All users will share/use this same file.

Copy WLM.CFG to a directory available to the PC node only - example:  C:\WINDOWS.  Edit the WLMFile= statement in WLM.INI to reflect its name and path.

Edit the LogFile= in WLM.INI to reflect the location in which you want the error log file to be written to.  A good place for this is in the same directory in which WLM.LIC is written to (on the fileserver) so that you may review it easily from time to time from any PC.  WLM will create the file if it does not exist.

Edit the RebootFile in WLM.INI to reflect the location in which you want the reboot track file to be located.  This file is created as needed by WLM.  The location or name of this file MUST BE UNIQUE for each PC.  If the PC has a local hard disk then use a common name and write it somewhere like the Window's directory.  If you are using a common directory on the hard disk then you must specify a unique filename for each PC.


The INI File: WLM.INI

The [Paths] section contains drive, path, and file references for all files accessed by WLM for it's internal needs.

[Paths]

CFGFile=c:\vb\wlm\setup\install\WLM.CFG

LogFile=c:\vb\wlm\setup\install\wlm.log

LicenseFile=c:\vb\wlm\setup\install\wlm.lic

RebootFile=c:\vb\wlm\setup\install\wlm.reb

ConfigFile=c:\vb\wlm\setup\install\wlm.cfg

MsgFile=c:\win30\wlm.msg

[Warnings]

UserResources=20	{Minimum % user resources}

GDIResources=20	{Minimum % GDI resources}

MinRAM=4096	{Minimum RAM}


The License Tracking File: WLM.LIC

The license tracking file (WLM.LIC) stores the application name, the number of licenses currently in use, and the maximum number of licenses available.  You turn off tracking of an application simply by setting maximum number of licenses to zero (0).  WLM automatically recovers licenses when a PC is rebooted by keeping track of the applications loaded by each PC.  File format for the license file is as follows:

Appl 1, Max Licenses, Licenses used, User Waiting, AppCode

Appl 2, ...

Appl:  The name of the application including its extension.

Max Licenses:  The maximum number of licenses to be allocated to this application.  Set to

zero (0) to disable tracking.

Licenses used:  Normally set to zero (0) when first setup.  You can open the file while in use and see how many licenses are being used later if you want.

User Waiting:  Indicates when another user is waiting to use an application currently loaded at this computer.  True/False.  Note that it only shows the message once unless the user loads/unloads another application.

AppCode:  A unique number assigned by WLM and updated/corrected as necessary.  Must be a multiple of 256 (Ex. 256, 512, 768, ...)  Duplicates are not allowed.

Note that if you change the size of the license file (WLM.LIC) while WLM is in use at other PC's they will receive an error when they close any application on their PC & be forced to exit Windows.  However this will not cause any serious problems and the users will be able to resume normal use once Windows is reloaded.  So don't modify the license file except after hours.


The Log File:  WLM.LOG

Any errors which occur are written to a log file (WLMlog.txt) and will contain the date, time, identifier for the node (NODE= in WLM.CFG), and the error message.  Usually the only statements which will appear here are denials to an application because the number of licenses allocated has been reached.  You can use WLMlog.txt to justify the purchase of additional copies of software since WLM does all of the usage tracking for you.  The second most frequent error to

appear would be a notice that a certain application was unable to run due to an error in its setup (usually path, name, etc.), or if a user has rebooted a PC and licenses were recovered.


The Menu Configuration File:  WLM.CFG

Use the NODE= to create a unique identifier for the PC in which you are running WLM locally.  This allows you to identify from which PC errors came from when they are written to WLMlog.TXT

Use the TITLE= to specify a title for your menu.

Use SecureSoftwareUse= to enable or disable restrictions to software.  If set to -1 (true) then the user will be denied access to an application when the maximum number of licenses is about to be exceeded (normal setup for most users).  Set to 0 (false) when you want to give specific users (actually users of that PC) the ability to override the software restriction.  When this happens the user is notified that they will be violating the license agreement and this violation is logged intoWLMlog.TXT.  This option was added for the case when you don't want to restrict a certain individual no matter what happens (like your boss).

The format for WLM.CFG is as follows:

AppName, MenuCaption, MenuLevel, Enabled, WState, LoadOnStartup,AppFilename,StartupDir

  AppName - the name or description of the application to appear in the drop down list.

MenuCaption - Caption for menu (WLM uses first menu item only), use & for ALT-key accesses "-" for a separator bar to follow the current menu item.

MenuLevel - 0 for buttons, 1-7 for drop down menus.

Enabled - 0 = false, -1 = true  NOTE:  cannot disable first menu item in any sub-menu, the program will ignore the request if you do.

WState:  the window state you wish the application to be when loaded.

           1,5,9 = normal w/ focus

           2 = minimized w/ focus

           3 = maximized w/ focus

           4,8 = normal w/o focus

           6,7 = minimized w/o focus

LoadOnStartup:  -1 = load on startup, 0 = don't load on startup (typical)

AppFilename - the drive:path:filename for the application along with any parameters the application may use.

StartupDir - the drive:path you wish to set as the default before running the program.  Most applications will use the default directory when opening and saving files.

Example:  Word,&Applications,5,-1,1,0,C:\WORD20\WINWORD.EXE,F:\

Loads WINWORD.EXE, startup directory is F:\, menu caption is 'Applications, Menu level is 5, menu item enabled, window state is normal, application not loaded on startup.

The setup option under 'File' in WLM allows you to edit this information while in the menu, but any additions or deletions will not take effect until the menu is reloaded.

You may have multiple occurrences of the same application anywhere in the menu.


Program Limitations

WLM does not detect software which has been executed outside of its control (such as using File Manager).  This feature may be added in the future as an enhancement.

The menu supports up to eight buttons and up to 8 drop down menus.  I'm not sure if their is a limit to the number of drop down menu item, but my testing indicates you'll run out of screen space first.  The number of programs tracked in the dynamic array is only limited by the memory of the system.


Known Problems/Bugs

Pctools V7.0 installs COMMKBD.DRV into the SYSTEM.INI file.  This will cause and error and should not be used.

If you change the size of the license file (WLM.LIC) while WLM is in use at other PC's they will receive an error when they close any application on their PC & be forced to exit Windows. However this will not cause any serious problems and the users will be able to resume normal use once Window's is reloaded.  So don't modify the license file except after hours.


Version/Revision History

1.0  First version installed on Novell LAN

1.1  Add application startup

2.0  Creation of menus from WLM.LIC

Load all menu items from WLM.LIC

  - add field: Indent index

  - use AppName for menu caption

  - add field: MenuName (for each app)

2.1  Added correction in KeyDown event for WLM form so that any

     ExitCode added to KeyCode would be stripped and not screw up

     the intended AppCode.  This seems to make AutoSketch and others

     work just fine.

     Added routine to ExitWLM to warn all applications that Windows is

     about to end & cause Windows to then end.

2.2  Changed WLM.INI to WLM.CFG

     WLM.INI tells WLM where WLM.CFG & WLM.LIC are & allows them to be changed.    Startup form added w/ hourglass effect.

     Windows directory detected & used to locate WLM.INI

     Completed 3/23/93

2.3  Added startup caption & loading progress information to frmLoadWLM.

2.4  Added recovery/update of LicenseFile (WLM.LIC) from a reboot of a PC.  6/93

2.5  Removed restriction to list number of appliations as first line in WLM.LIC  6/27/93.

2.6  Enabled Run command & checked for monitored application (& prevent monitored from

      running) 7/14/93.  Tested and confirmed fact that WLM.CFG can have less menu items and

in a different order than WLM.LIC.

3.0  Major revisions which removed the AppCode correspondence between the license file

(WLM.LIC) and the config file (wlm.cfg).  Optimized for speed and reduction in errors.

3.1  Minor bug fixed.  12/4/93

3.2  Major bug in procedure which setup menus.  Caused problems with sixth or seventh menu.

3.31       Amount of menus expanded.  Status line added and resource/memory checking added.

       New INI file access added (replaced old method).

3.32  Added additional checking and correction of AppCode.  Help access added.

3.35  Added display of GDI & User resources along with free RAM.


File Descriptions

WLM.EXE	The main program.

WLM.INI	Initialization file read by WLM.EXE.  Must be in Window's directory.

WLM.CFG	ASCII file which contains setup information for the menus.

WLM.LIC	ASCII file used by WLM.EXE to track license use for all instances of WLM.

WLM.LOG	Created by WLM.EXE to log errors and restrictions to applications.

WLM.WRI	Documentation for WLM.

XTASK.DLL	DLL file used by WLM.  Must be in Window's SYSTEM directory.

VBRUN300.DLL DLL file needed by any Visual Basic 3.0 program.  Must be in Windows SYSTEM directory.

INSTALL.BAT    An optional file useful for installing WLM at multiple PC's.  Needs to be edited to fit your needs.

WLM.HLP	This help file

SETUP.EXE	Installation program for WLM.


Disclaimer

 *** USE THIS SOFTWARE AT YOUR OWN RISK ***

           Be sure to test thoroughly in your environment.

           No warrantees extended, no support promised.

           Please report any problems back to the author.


Acknowledgments

Name:      xTask.dll

Purpose:   Monitoring termination of other tasks;

                Mapping between hTask and hInstance.

Version:   1.0

Date:      15 Nov 92

Requires:  Windows 3.1

Author:    Pieter Stam (CompuServe 100065,603),  Pontis Consulting (U.K.)

Ownership: Public.  Free usage & redistribution.