Project Provider Framework
The Project Provider Framework is an unsupported API used to extend LabVIEW in various ways, mostly relating to the project interface. While NI does not provide official support for Project Providers, nor guarantee their stability in future versions, they have provided some documentation as well as a community forum for the framework; this was originally only available to NI-approved developers but has since been opened to the general public.
Features
Things that can be done using Project Providers:
- Add Menu Items (globally or per specific item types)
- Add Toolbar Buttons
- Add Items to the Project Tree
- Add Right-Click (Popup or Context) Menu Items
- Customize the Double-Click Behavior of an Item
- Modify the Name or Icon of an Item in the Project Tree
- Save More Information Related to an Item
- Drag and Drop Items to and Within a Project
Primary vs Secondary Providers
Providers can be either a Primary or a Secondary Provider.
- A Primary Provider puts one or more new item types into the project tree.
- A Secondary Provider adds additional functionality to existing items, but is not responsible for creating or managing those items.
Therefore, a Secondary Provider does not cause new items to be displayed in the tree but attaches to items shown by other Primary Providers.
Project Provider INI File
A Project Provider is defined by an INI file located in the [LabVIEW 20xx]\resource\Framework\Providers\GProviders
directory in the LabVIEW installation directory. This file contains paths to "interface VI's", which determine the locations of other VI's that implement the plugin's functionality.
[Provider] SupportedType={D60740D6-F254-4BBC-5675-8858F35B810E} GlobalItemInterfaceVI=..\SecondaryProviderExample1\SecondaryProviderExample1_Global_Interface.vi ItemInterfaceVI=..\SecondaryProviderExample1\SecondaryProviderExample1_Item_Interface.vi ProviderInterfaceVI=..\SecondaryProviderExample1\SecondaryProviderExample1_Provider_Interface.vi IsPrimary=0 LicenseName=None InterfaceVersion=1.0 Signature=J7W9927AAAAAA5TBNTSSTTLWR29CNT9X
The INI files can contain the following keys:
Keys | Description |
---|---|
SupportedInterface | Indicates which interfaces are supported by the provider. |
SupportedType | Specifies a GUID that represents the type of project item type. (See ProjectItems)
Must be formatted as follows: {XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX} For a Secondary Provider, this can point to the Alias of the item type it wants to attach to instead of the GUID. |
Alias | Is a unique string that like the GUID, is used to identify the project item type (applies to Primary Providers only). |
IsPrimary |
|
ItemInterfaceVI | Defines the VI that enumerates the “Item” interface. |
ProviderInterfaceVI | Defines the VI that enumerates the “Provider” interface. |
GlobalItemInterfaceVI | Defines the VI that enumerates the ”Global” item interface. |
CreateNewWizardInterfaceVI | Defines the VI that enumerates the “CreateNewWizard” interface. |
SourceControlInterfaceVI | Defines the VI that enumerates the “SourceControl” interface. |
DeployInterfaceVI | Defines the VI that enumerates the “Deploy” interface. |
BuildInterfaceVI | Defines the VI that enumerates the “Build” interface. |
CreateNewWizardHost | (Primary providers only) Defines which “New” menu to add to e.g., Source, Build. |
InterfaceVersion | Specifies the interface version used by the provider. Currently, this must be set to 1.0. |
Signature | Digital signature – generated by NI. (Or See Below) |
Supported Types
The SupportedType key in a Primary Provider’s INI file acts as the type ID of the item it creates. If it is a new type this GUID must be in the form of: {XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}
The SupportedType key in a Secondary Provider’s INI file defines which item type is supported (or Alias in the case of Primary Providers).
See ProjectItems for the list of LabVIEW Item Types.
Supported Interfaces
Primary Providers specify their supported interfaces by including them in their INI file. Secondary Providers specify their supported interfaces through:
- Implicitly inheriting the Interfaces through the Primary Provider they support as defined by the SupportedType key
- Explicitly defining the Interfaces through the regular keys in the INI file just as the Primary Provider does
Signature
For LabVIEW to load a project provider, its INI file must contain a valid "signature" consisting of an enciphered MD5 hash of certain other values in the INI file, generated using a signing tool provided by NI. This is an artifact from before the framework was officially made public, though the method of generating the signature had been reverse-engineered and was publicly known before that point.
Algorithm
What follows is an explanation of how the "signature" is determined. If you are using the official signing tool (or an unofficial one) you do not need to know this, but it might be useful for tool developers or anyone curious.
First, take the values (not the keys) in the INI file in order, and concatenate them. Only include the values for keys in this list (rule of thumb: string values, not Boolean or numeric values, and don't include the Signature key of course):
- "InterfaceVersion"
- "LicenseRestrictions"
- "LicenseVersion"
- "LicenseName"
- "Alias"
- "SupportedType"
- "SupportedInterface"
- "CreateNewWizardHost"
- "BuildInterfaceVI"
- "DeployInterfaceVI"
- "SourceControlInterfaceVI"
- "CreateNewWizardInterfaceVI"
- "GlobalItemInterfaceVI"
- "ProviderInterfaceVI"
- "ItemInterfaceVI"
Do not include spaces or other delimiters between values in the concatenated string. Take the MD5 hash of this string, and apply the following substitution cipher to each of the digits:
Change: 0123456789ABCDEF To: T3C5K7W9SBNRJLX2
Finally, for each pair of two consecutive digits, switch them. For example, CRTTR3X7 would become RCTT3R7X.
Interface VIs
The framework specifies a list of interfaces that providers must implement. Each interface VI is a list of paths to dispatch VIs that point to each of the required methods that the providers must implement. Only the methods that the provider will provide need to be implemented. The VIs implementing these methods must conform to the particular Connector Pane but the contents can be completely customized. Once a provider-based event occurs the provider framework will run the appropriate VI if a method has been customized for that event in the provider. For example if Item.OnSelect has been implemented, it will be called when the project item is selected. The Interface VIs:
- Build
- CreateNewWizard
- Global
- Item
- ProjectDeployItem
- Provider
- SourceControl
Build Interface Methods
Primary Providers Only Defines events that apply to builds, i.e. items under Build Specifications, in the project tree. These include:
![]() |
Methods need definitions |
Method | Definition |
---|---|
Invoke | |
Preview | |
IsRunnable | |
Run | |
On-Duplicate |
CreateNewWizard Interface Methods
Primary Providers Only Defines events that occur while adding items of new types to the project tree.
Method | Definition |
---|---|
Finalize | Description: Called after the new item has been created.
Inputs:
Outputs: None |
GetCreateNewWeight | Description: Called when the appropriate New menu is being constructed.
Inputs:
Outputs:
|
GetNewItemInfo | Description: Called whenever right-clicked on an item that supports this New menu.
Inputs:
Outputs:
|
IncludeItem | Description: Called when the appropriate New menu is being constructed.
Inputs:
Outputs:
|
Init | Description: Called to initialize the wizard.
Inputs:
Outputs:
|
Invoke | Description: Called when an entry added to a New menu by this provider is selected.
Inputs:
Outputs:
|
Global Interface Methods
Defines global-level events that are not tied into a specific object type.
Method | Definition |
---|---|
Init | Description: Called every time the provider is loaded. This happens when LabVIEW.exe runs and whenever a project explorer window is created (open, new, etc.). It should be used to construct menus and do any other initialization tasks. If licensing is not integrated, the check should be performed here (in addition to any licensing-based initialization).
Inputs:
Outputs: None |
OnCommand | Description: Called when executing global menu and toolbar commands. Should be used to define or call button/menu behaviors.
Inputs:
Outputs: None |
OnUpdateCommand | Description: Called during framework update operations. Building menus calls this for each customized menu item. When in the project window, this is called in a loop to make sure all the menus are in the most recent state.
Inputs:
Outputs: None |
Exit | Description: Not currently called.
Inputs:
Outputs: None |
Item Interface Methods
Defines events that occur to individual items in the project tree.
Method | Definition |
---|---|
CanDelete | Description: Determines if the project item can be deleted
Inputs:
Outputs:
|
CanDoHelp | Description: Determines if the project item supports help.
Inputs:
Outputs:
|
CanDoProperties | Description: Determines if the project item supports properties.
Inputs:
Outputs:
|
CanDragToExternalWindow | Description: Called when the project item is dragged to an external window.
Inputs:
Outputs:
|
CanDragToProjectWindow | Description: Called when an item is dragged into the project window.
Inputs:
Outputs:
|
CanDropExternalData | Description: Called when an item from an external window is dragged onto this item.
Inputs:
Outputs:
|
CanDropItem | Description: Called when another project item is dragged to the item.
Inputs:
Outputs:
|
CanRename | Description: Determines if the project item can be renamed.
Inputs:
Outputs:
|
Exit | Description: Not currently called.
Inputs:
Outputs: None |
GetAddCategories | Description: TBD
Inputs: None Outputs: None |
GetCreateNewCategories | Description: TBD
Inputs: None Outputs: None |
Init | Description: Called when initializing a single item in the project.
Inputs:
Outputs: None |
NotifyChanged | Description: Called when the item is modified (item created or modified, file created or modified, item added or renamed, item added to or modified for SCC).
Inputs:
Outputs: None |
OnCommand | Description: Called when a menu entry installed by the provider is selected on a single item.
Inputs:
Outputs: None |
OnDblClick | Description: Called when the user double-clicks on an item in the project tree.
Inputs:
Outputs: None |
OnDelete | Description: Called when the project item is deleted.
Inputs:
Outputs: None |
OnDoHelp | Description: Called when Help... is selected from the popup menu for the project item.
Inputs:
Outputs: None |
OnDoProperties | Description: Called when Properties is selected from the popup menu for an item.
Inputs:
Outputs: None |
OnDropFiles | Description: Called when one or more files are dragged from the explorer and dropped on a project item.
Inputs:
Outputs: None |
OnDropItem | Description: Called when another project item is dropped on the item.
Inputs:
Outputs: None |
OnPopupMenu | Description: Called right before the project item's popup menu is displayed—menu can be modified before display.
Inputs:
Outputs: None |
OnRename | Description: Called when the item is renamed.
Inputs:
Outputs: None |
OnSelect | Description: Called when the project item is selected in the project tree.
Inputs:
Outputs: None |
OnUnselect | Description: Called when the project item is unselected in the project tree.
Inputs:
Outputs: None |
OnUpdateCommand | Description: Called to update the specified command right before it is about to be displayed in a menu or popup.
Inputs:
Outputs:
|
OnWizardComplete | Description: Notifies the project item that the Create New Wizard process is finished.
Inputs:
Outputs: None |
PrefersFPHeap | Description: Determines if item wants the VI Front Panel or Block Diagram reference when WasDroppedOnVI is called.
Inputs:
Outputs:
|
ValidateRename | Description: Determines if the new name is valid for the project item.
Inputs:
Outputs:
|
WasDroppedOnItem | Description: Called when the project item was dropped on another project item in the tree.
Inputs:
Outputs: None |
WasDroppedOnVI | Description: Called when the project item is dropped on an open VI (either front panel or block diagram).
Inputs:
Outputs:
|
ProjectDeployItem Interface Methods
Defines events that support deploying of an item in the project tree.
![]() |
Methods need definitions |
Method | Definition |
---|---|
GetSupportedCommands | |
GetDeployState | |
NotifyCommandCompleted |
Provider Interface Methods
Defines events that occur to multiple items in the project tree.
Key | Description / Inputs / Outputs |
---|---|
InitItems | Description: Called when multiple items in the project are bound.
Inputs:
Outputs: None |
LoadComplete | Description: Called when the project has finished loading.
Inputs:
Outputs: None |
LoadCompleteWithWarnings | Description: Same as LoadComplete except save warnings are optionally returned.
Inputs:
Outputs:
|
NotifyChanged | Description: Called when changes occur involving multiple items (create, add, etc.)
Inputs:
Outputs:
|
OnCommand | Description: Called when a command is invoked on multiple items (menu or toolbar).
Inputs:
Outputs: None |
OnPopupMenu | Description: Called right before the project items' popup menu is displayed—can modify menu.
Inputs:
Outputs: None |
OnSaveForPrevious | Description: Called when a project is being saved to a previous version—gives provider a chance to modify property bag to match the previous version.
Inputs:
Outputs: None |
OnSaveForPreviousEx | Description: Same as OnSaveForPrevious except the provider is also passed to the method.
Inputs:
Outputs: None |
OnSaveForPreviousWithWarnings | Description: Same as OnSaveForPreviousEx except save warnings are optionally returned.
Inputs:
Outputs:
|
OnSaveProject | Description: Called when the project is being saved.
Inputs:
Outputs: None |
OnUpdateCommandBegin | Description: Called before UpdateCommand is called for each command in the toolbar or menu.
Inputs:
Outputs: None |
OnUpdateCommandEnd | Description: Called after UpdateCommand is called for each command in the toolbar or menu.
Inputs:
Outputs: None |
Shutdown | Description: Called when the project shuts down.
Inputs:
Outputs: None |
Startup | Description: Called when the project is created.
Inputs:
Outputs: None |
SourceControl Interface Methods
Defines events that apply to source code control functionality.
![]() |
Methods need definitions |
Method | Definition |
---|---|
GetRequiredFiles | |
GetDependents | |
GetCallers |
Documentation and Examples
- LabVIEW Project Provider Dev Guide
- API Descriptions
- Interface VI Descriptions
- Examples in LabVIEW 2009 (32-bit)