Macro Component

Introduction

A Macro Component is an ordinary DataVeil macro definition that is saved as a Component (XML file) so that its definition can be centralized and used by any DataVeil project.

Please refer to Macros for a detailed description of DataVeil macros.

 

Create a Macro Component

Creating a Macro Component (XML file) is almost identical to creating an in-project macro definition.

The only difference is that the component's Create Macro form does not have a Name field for the macro name. Instead, the file name of a Macro Component is used as the macro name.

To create a Macro Component, open the Components tab in the main GUI view, and then select the Macros tab.

Click on 'Create...' and the 'Create Macro' dialog shall appear.

 

Let's create a Macro Component called #rate with a value of 50 that shall be used from masking projects on any DBMS type.

Therefore, click on 'Add...' and then specify the value 50 and ensure DBMS value of Default is selected.

 

Click OK, and OK again.

The Save dialog shall now appear and will open at Component Home. The name that you specify as 'File name' shall become the macro name of this Macro Component. Do not specify the '#' character when saving the file; however, always use the '#' character whenever referencing macro names in masking projects.

 

Click 'Save'. The Macro Component is saved and becomes visible in the Components->Macros tab.

 

Using a Macro Component

A Macro Component is simply a DataVeil macro that is defined at the highest level scope (Component level). Apart from this, a Macro Component is used in exactly the same way as a macro at any other level.

Please refer the Macro section for macro usage details.