LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

.NET 4.0 Support

Solved!
Go to solution

I installed LabWindows/CVI 8.5 and have used it for several months for creating .NET controllers for assemblies that are Microsoft .NET 2.0 platform.

Now, the provider of the assembly has upgraded to .NET 4.0.

I tried to generate the controller by pointing to the new assembly but an error message appears:

"Error occured while generating .NET controller code. Error in the application"

 

Does LabWindows/CVI 8.5 support .NET 4.0 assemblies?

 

Thanks!

 

Bye!

Ivan

 

0 Kudos
Message 1 of 13
(4,767 Views)

Hi Ivan,

 

CVI 8.5 doesn't support .NET 4.0 Framework.

 

Have a nice day,

Simone

______________________
Simone S.
Academic Field Engineer - Med Region
0 Kudos
Message 2 of 13
(4,747 Views)

...And does CVI 2010 support .NET 4?

0 Kudos
Message 3 of 13
(4,744 Views)

Hello Ivan -

 

Because of some changes in the new version of the CLR that is a part of .NET Framework 4, you must now place a config file next to cvi.exe.  I've attached the config file below.  Once you've placed this file in CVI's installation directory (usually <program files>\national instruments\cvi85), you should be able to generate wrappers for .NET Framework 4 assemblies.

 

Also, note that any applications you create that call into .NET Framework 4 assemblies must also have this config file.  You should copy the config file I've attached below, rename it to <your app name>.exe.config, and then place it in the same directory as your exe.

 

We've created a bug report (ID 283065) to better support .NET Framework 4 for future versions of CVI.

 

Let me know if you have any questions,

 

NickB

National Instruments

0 Kudos
Message 4 of 13
(4,716 Views)

OK! ...but I cannot see the attachment.

Could you please send it one more time?

0 Kudos
Message 5 of 13
(4,695 Views)

oops... You can't see it because I forgot to attach it.  My apologies 🙂

 

NickB

National Instruments

Message 6 of 13
(4,692 Views)

Emm... I made a step forward but it's still no working.Smiley Sad

CVI is now able to analyze the contents of the assembly...

 

undefined

 

 

...but, when I press OK the following message appears:

undefined

 

Any idea?

 

Thank you!

0 Kudos
Message 7 of 13
(4,670 Views)

Hmm... It's not entirely clear why that error message would be shown.  Something is throwing a NotImplementedException as we're generating the wrapper for this code, but it's not from our layer.  Do you think you could post the assembly to our ftp site ftp://ftp.ni.com/incoming (it's write-only and behind our firewall) so that we can take a look in the debugger?

 

Thanks -

 

NickB

National Instruments

0 Kudos
Message 8 of 13
(4,662 Views)

Hi!

 

I just uploaded to your FTP server. It's in a zip called NET4Problem.zip.

The assembly Electrolux.CTI.CycleManager.dll is the one i would like to access from CVI.

 

The other assemblies in the zip: CycleManager depends on the other dlls in that directory.

The subdir ConfigFiles is used at runtime by the assemblies Bases,dll and Selectors.dll.

 

Thank you very much!

 

Regards

Ivan

0 Kudos
Message 9 of 13
(4,642 Views)

Hi!

I have to make a clarification:

 

 

  • I tested the solution with LabWindows/CVI 8.5 (i.e., version 8.5.0 (279)) and I confirm that it does not work.
  • I now tested with the LabWindows/CVI 2009 (i.e., version 9.1.1(450)) and it works!

 

 

Did you mean that the cvi.exe.config should have worked also with 8.5?

For us, it would be better to work with 8.5 and fix the problem on that version.

 

Thank you very much!

 

Best Regards

Ivan Muzzolini

Electrolux

0 Kudos
Message 10 of 13
(4,631 Views)