Set IP Address Programmatically Using LabWindows ™/CVI ™

Updated Nov 26, 2024

Reported In

Software

  • LabWindows/CVI

Operating System

  • Windows

Issue Details

I am trying to set the IP address of my computer programmatically in LabWindows. However, I could not find any libraries available in it. Is it possible to set the IP address of my computer programmatically using LabWindows?

Solution

There are several methods to change the IP address programmatically in LabWindows. These methods requires calling the command prompt and pass the arguments to change the IP address in LabWindows. 

  1. Using system() system function in ANSI C Library
  2. Using LaunchExecutable or LaunchExecutableEx
  3. Using CreateProcess function in WIndow's Win32 DLL
  4. Creating .NET controller that uses System.Diagnostics assembly