Using DLLs

If you have some functionality in a Dynamic-Link Library (DLL) or need to build some functionality that Warewolf does not have natively, a quick way to do this is to use a DLL.

To create a Connector to a DLL so that it can be consumed inside your Warewolf service:

  1. To start, create a new service by clicking the new service button in the toolbar.New Services Icon in WarewoldScroll down in the Tool Box until you find the Resources category. Drag the DotNetDLL Connector tool onto the design surface and connect it to the Start node.
  2.  You can either select a Source from the drop down list or create a new one.
  3. If you are creating a new source, Click New.  There are two primary options in the New DotNet Plugin Source window.
    1. Enter the path of the DLL that you want to use by typing the full path in the Assembly textbox, or
    2. Load a DLL from the Global Assembly Cache (the GAC). Click on the ellipses (…) on the far right of the GAG Assembly. Use the filter textbox to help you search for your assembly. Click on the Assembly that you want and then click Select.
  4. Once you have selected your Source from either the Assembly or the GAC, click Save on the main toolbar. Name and your source and save.
  5. Navigate back to your service and open the DotNet DLL Connector by double clicking the blank area at the top of the tool. Select a Source from the Source drop down list.
  6. Select the Classname from the Classname drop down list.
  7. Select the Constructor, if applicable, or leave it set to default (.ctor).
  8. To set the Object Name, expand the constructor to full view by clicking on the small expand arrows.
  9. Select the Action from the Action drop down list.
  10. Add the Input Data or Variable you want to use as input. This will be used at run time. To pass in Null when the value is empty, select Empty is Null.
  11. Add the Output Variable.
  12. It is time to run this source. Click Done and then click the Debug button on the toolbar. In the debug window, click Debug to view your output.
  13. In the Output window at the bottom right, you will find your output. Click the small expand arrows to see the expanded view. If you press F6 it will debug again and present different values for each action.
  14. To reuse this connector as a service in its own right, simply Save a workflow service with this as the only step.

Not what you were looking for? Ask our expert users in the Community Forum.

FacebookTwitterLinkedInGoogle+Email
Updated on July 19, 2017

Was this article helpful?

Related Articles

Enjoying Warewolf?

Write a review on G2 Crowd
Stars