BasicNoUIObjMacroBegin Event |
Occurs when a macro has been started or module has been loaded.
Namespace: WinWrap.Basic.ServerAssembly: WinWrap.Basic.Server (in WinWrap.Basic.Server.dll)
Syntaxpublic event EventHandler<MacroEventArgs> MacroBegin
Public Event MacroBegin As EventHandler(Of MacroEventArgs)
public:
virtual event EventHandler<MacroEventArgs^>^ MacroBegin {
void add (EventHandler<MacroEventArgs^>^ value);
void remove (EventHandler<MacroEventArgs^>^ value);
}
Value
EventHandlerMacroEventArgsImplements
IBasicNoUIMacroBegin
Remarks
The event handler receives an argument of type
MacroEventArgs.
Property
|
Description
|
---|
FileName
|
The file name that is beginning execution.
|
Setting the Run property to True or using the
LoadModule method cause this event.
This event occurs after the macro/modules's variables have been initialized
and after its initialize procedure has been run.
Macro/Module Paths
Macro/module paths are typically file paths.
However, it is sometimes useful to work with macros/modules that are not
stored as files.
A macro/module path is of the form:
Part
|
Description
|
---|
'*'
|
Paths that being with '*' are non-file system macro/modules.
The application provides the methods for reading and writing these files.
Paths that begin and end with '*' are hidden from the IDE.
User's can't step into or otherwise inspect the contents.
|
'**'
|
Paths that begin with '**' are non-file system modules.
The application provides the methods for reading and writing these files.
Running an event-driven module loads it using LoadModule.
|
path
|
This is the identity of the macro/module.
|
Example
Print the file name that's starting execution:
private void basicIdeCtl1_MacroBegin(object sender, MacroEventArgs e)
{
Debug.WriteLine("Loading/Starting " & e.FileName);
}
Private Sub BasicIdeCtl1_MacroBegin(ByVal sender As Object, ByVal e As System.EventArgs) Handles BasicIdeCtl.MacroBegin
Debug.WriteLine("Loading/Starting " & e.FileName)
End Sub
private: System::Void basicIdeCtl1_MacroBegin(System::Object ^ sender, MacroEventArgs ^ e)
{
Debug::WriteLine(L"Loading/Starting " + e->FileName);
}
See Also