BasicNoUIObjGetMacroCaption Event |
Occurs when a macro/module's caption is needed.
Namespace: WinWrap.Basic.ServerAssembly: WinWrap.Basic.Server (in WinWrap.Basic.Server.dll)
Syntaxpublic event EventHandler<GetMacroCaptionEventArgs> GetMacroCaption
Public Event GetMacroCaption As EventHandler(Of GetMacroCaptionEventArgs)
public:
virtual event EventHandler<GetMacroCaptionEventArgs^>^ GetMacroCaption {
void add (EventHandler<GetMacroCaptionEventArgs^>^ value);
void remove (EventHandler<GetMacroCaptionEventArgs^>^ value);
}
Value
EventHandlerGetMacroCaptionEventArgsImplements
IBasicNoUIGetMacroCaption
Remarks
The event handler receives an argument of type
GetMacroCaptionEventArgs.
Property
|
Description
|
---|
Caption
|
Initialized to the value of the file name.
Change this to show a non-standard caption.
|
Caption, provides the macro/module name.
Its first character will always be '*'.
If the macro/module name is a special name for your application
change it to the macro/module's caption.
Otherwise, do nothing.
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
Use the real file name associated with file name '*...' as the caption:
private void basicIdeCtl1_GetMacroCaption(object sender, GetMacroCaptionEventArgs e)
{
e.Caption = MyMacros(e.Caption).FileName;
}
Private Sub BasicIdeCtl1_GetMacroCaption(ByVal sender As Object, ByVal e As GetMacroCaptionEventArgs) Handles BasicIdeCtl.GetMacroCaption
' return the actual file name as the "caption"
e.Caption = MyMacros(e.Caption).FileName
End Sub
private: System::Void basicIdeCtl1_GetMacroCaption(System::Object ^ sender, GetMacroCaptionEventArgs ^ e)
{
e->Caption = MyMacros(e.Caption)->FileName;
}
See Also