AdvShell - to use instead of standart Visual Basic function "Shell"

FEATURES:
  1 - return ExitCode of called process;
  2 - signal of events for load application, quit application,
      execute application and errors on loading;
  3 - modal execution for called process (optional);
  4 - for console applications: capture StdOutput stream and transfer
      it to caller;
  5 - automatically searching executable file for load 
      extension-associated file.

INSTALLATION and USING
  - copy aShellEx.DLL to WINDOWS\SYSTEM\ directory
  - register it with RegSvr32.exe
  - open yours Visual Basic programming shell and create new 
    Standart EXE project - call Menu->Project->References and 
    check in available references "Advanced 'Shell' function"
  - also you may open 'TestProject.vbp' and introduce yourself in 
    advShell library using. 

'AdvShell' - is a method of 'AdvShellClass' class, instancing as 
'GlobalMultiUse'. It don't mean to declare variable "As AdvShellClass" or
"As New AdvShellClass" in yours project. But it is necessary for receiving 
notifications from 'AdvShellClass'. You may use this code (in form code module):

-----------------BEGIN EXAMPLE -------
Option Explicit

Private WithEvents ps As AdvShellClass

Private Sub Form_Load() 
Set ps = ProcessNotification 
End Sub

----------------END EXAMPLE ----------

AdvShellClass: METHODS:
[Object.] AdvShell(appstr, [comstr],[WorkDir],[WinStyle],[NoWait],
	[CaptureConsole],[WaitInterval],[dwProc],[dwThread]) As Long

Named arguments are available. Sintax:

Object - optional. AdvShellClass object 
appstr - Required.(String) Name of executable file or associated file. May
	   include full path and drive (optionally).
comstr - optional. String expression specifies command line arguments. if "appstr"
	 parameter specifies non-executable file, the final call will be looked  as:
	  'associated exe-file' 'command-line arguments' 'file,specified in APPSTR parametr'
	Default - empty string 
WorkDir - optional. String expression specifies working directory. If don't 
	specified, the current directory will be used.
	Default - empty string 
WinStyle - optional. Expression as VbAppWinStyle enum specifies Window style of
	   created process. Default - 'vbNormalFocus' 
NoWait - optional. Boolean. If "True", AdvShell does not wait for completion of
	 called application.
	 Default - 'False' 
CaptureConsole - optional. Boolean. If 'True' the StdOutput of console 
	application be redirected and transferred to caller 
	(by 'InProcessConsole' event see below). 
	Default - 'False' 
WaitInterval - optional. The integer expression determines an interval 
	(in milliseconds) between checks of a condition of the loaded program. 
	On expiration of an interval the event ' InProcess' is excited.
	default - 1 
dwProc,dwThread - optional. Variant (Long) expressions to receive the primary 
	process	and primary thread handlers

The function return -1, if not it was possible to load the program. Exit Code 
of the loaded program otherwise returns.
------------------------------------------

AdvShellClass: Properties:

AppDir,AppTitle,WorkDir,ComLine - read-only string properties returnes real 
	parameters of last calling of application with AdvShell 
Bisy - read-only,boolean. If 'True' - AdvShell in process. Otherwise -'False' 
ForseExitProcess - WRITE-ONLY, boolean. You can set it in 'True' to finish 
	application immediately.
ProcessNotification - read-only. Returns the reference to globally defined 
	AdvShellClass object.
-----------------------------------------

AdvShellClass: Events:

LoadProg - without parameters. Notifies, that the called application is loaded. 
ReturnProg(RetCode as Long) - Notifies, that the called program was finished 
	with a code 'RetCode' 
InProcess - without parameters. raised after the expiration of an interval, 
	specified in 'WaitInterval'
InProcessConsole(consolestr as string) - if 'CaptureConsole' is 'True' this 
	event transfer console output in 'consolestr' argument. Otherwise this 
	event do not raise.
ErrorLoading(RetCode as Long) - There was any error on load application.

-----------------------------------------

==========================================

aShellEx.Dll had been made in two variants: for VB5 (in dir 'VB5') and 
for VB6 (in dir 'VB6')

If you have any questions, ask me via email: u_green@chat.ru 

With best regards, 
Sergey E. Greenberg
