Quick Start
Developing .Net Plug-ins
To start developing .Net plug-ins for Vine for Windows you need:
- Vine for Windows client. It includes all interop libraries needed to use Vine COM methods from a .Net plug-in.
- Add a reference to Interop.VINTAGELib.dll located in the application folder of the Vine for Windows client. Do not generate and use a VINTAGELib interop assembly from the type library.
- Before you can use a compiled plug-in you will need to install it to the Vine database using the Vine Web Administrator’s console. You should consult the Vine administrator about this.
Some Guidelines
Visual Elements
- If you want push buttons in (.net) plugin forms look similar to push buttons in Edit Displayer you need to set the FlatStyle property to FlatStyle.System.
Using Event Handlers
C++ COM event handler code can see multiple C# event receivers as one which causes problems with events like StartEditObject as the C++ code cannot stop the event sending when some handler have handled the event and did set the DoEdit to false. Because of this all of such handlers should FIRST check that the last bool parameter is set to True (e.g. DoEdit==true) and only then proceed with the rest of the code:
Basically, all those handlers should start with code similar to:
if (DoEdit == true)
{...
Some events that need that check:
- StartConnectingObjects
- StartDisconnectingObjects
- StartEditObjectInWindow
- StartOpenObjectInWindow
- StopEditObjectInWindow
- StartCloseObjectInWindow
- StartDeleteObject
- StartQuit
- StartQuit2
- StartEditObjectInWindow2
- StartEditObjectInWindowWithSample2
All these routines should first check if some previous handler have already cancelled / processed the event by checking its ref bool last parameter.
For example, StartQuit2 does have only one bool: doQuit. If it is set to false, then the quit is cancelled. StartConnectingObjects have ref doConnect bool. If it is set to false then the connect is cancelled by plugin. All those routines have similar ref bool to stop the operation
Comments
0 comments
Please sign in to leave a comment.