Using .NET in LabVIEW

If you have .NET class libraries from previous work, but now need to work in LabVIEW, you can easily use those libraries in your LabVIEW applications.

In the LabVIEW functions window look for .NET under Connectivity.

LvFunctions

Place the Constructor VI on your block diagram. A window will pop up to let you browse to the .NET dll you want to use. After selecting the dll, you then select which class from the dll that you want to use. Use the Property Node and Invoke Node VIs to utilize the .NET object.

The following image shows a LabView block diagram for using the Calc.dll which was created in previous blog post.

LvBlockDiagram

The following image shows the LabVIEW front panel for the application.

LvFrontPanel

The front panel here shows the error in control and error out indicator. If this is your top level VI, you may want to hide these by right clicking on them, selecting Advanced then Hide Control or Hide Indicator. A properly written application would also have some error checking and handling built in.

Tags:

One Response to “Using .NET in LabVIEW”

  1. sourceforge « Bill's Electronics & Software Development Notes Says:

    [...] Bill's Electronics & Software Development Notes « Using .NET in LabVIEW [...]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s


Follow

Get every new post delivered to your Inbox.