Updating Older API Programs

Release 3 and later of the N7621B software utilizes both the Microsoft .Net 4.0 and .Net 3.5 dll components. Release 3 and later also utilizes certain dll components based on the Windows platform and installed N7621B version. For these reasons, older API programs need to be modified.

When the N7621B software is installed on 64-bit operating systems, the Multitone API may not correctly handle function calls from other 32-bit applications.

If you want to use an API program that was written for N7621 versions 2.x and earlier, you will need to make the following updates:

  1. Update the project's app.config configuration file
    1. Make sure your project/solution has an app.config file. If app.config exists, proceed to step 1.b. If not, add a configuration file to the project:
      1. In Visual Studio's Solution Explorer, right-click the project and select Add > New Item...
      2. In the Add New Item dialog, select Application Configuration File from the list and click Add.
    2. Add the following line to the app.config configuration file:
      <startup useLegacyV2RuntimeActivationPolicy="true">

      You can find an example app.config file at C:\Program Files\Keysight\Signal Studio\Multitone Distortion\bin\. It contains the following:
      <?xml version="1.0"?>
      <configuration>
      <startup useLegacyV2RuntimeActivationPolicy="true">
      <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/>
      <requiredRuntime version="v4.0.20506" />
      </startup>
      </configuration>
  2. Change the project's Platform target and Target framework settings
    1. In Visual Studio's Solution Explorer, right-click the project and select Properties
    2. In the Build tab, set Platform target: to Any CPU
    3. In the Application tab, set Target framework: to .NET Framework 4