LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Calling DOTNet 4.0 from LV8.2.1

Hi
 
I got some C# dlls that I have to use in LabVIEW.
It is written in dotNET 4
It works fine in LV2012, but I shall use it in LV 8.2.1.
 
When I use it in LV8.2.1 I get the following error.:

 

 

Error 1172 occurred at Error calling method VesTest.Common.Utils.SoftwareUpload.Strategies.PhoenixSoftwareUpload.AutoIpDetectingPhoenixSoftwareUploadStrategy.Upload of ObjectId handle: 
 
 0xC9911C4 for obj 0x8AB23E[VesTest.Common.Utils.SoftwareUpload.Strategies.PhoenixSoftwareUpload.AutoIpDetectingPhoenixSoftwareUploadStrategy] in domain [8.2.1 SWupload project.lvproj for Run] and thread 6368,
 
 (System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
Inner Exception: System.Configuration.ConfigurationErrorsException: 
 An error occurred creating the configuration section handler for GeneralUserSettings: 
  Could not load file or assembly 'Vestas.Firecrest.Common, Version=4.1.0.90, Culture=neutral, PublicKeyToken=null' or one of its dependencies.
  The system cannot find the file specified. (C:\Users\bjaj\AppData\Roaming\Firecrest\Firecrest.config line 😎
 
Inner Exception: System.IO.FileNotFoundException: Could not load file or assembly 'Vestas.Firecrest.Common, Version=4.1.0.90, Culture=neutral, PublicKeyToken=null' or one of its dependencies.
The system cannot find the file specified.)
 
in 8.2.1 SWupload.vi
 
Possible reason(s):
 
LabVIEW:  A .NET exception occurred.
 
There is a txt-file that the error refer to. Here is the text from it and line 8 in red:
 
<?xml version="1.0" encoding="utf-8"?>
<configuration>
    <configSections>
        <section name="AutoSyncReleasePackagesSettings" type="Vestas.Firecrest.ConfigurationManagement.AutoSyncReleasePackagesSection, Vestas.Firecrest.Common, Version=4.1.0.90, Culture=neutral, PublicKeyToken=null" />
        <section name="CleanUpSection" type="Vestas.Firecrest.ConfigurationManagement.CleanUpConfigurationSection, Vestas.Firecrest.Common, Version=4.1.0.90, Culture=neutral, PublicKeyToken=null" />
        <section name="CleanUpUserSettings" type="Vestas.Firecrest.ConfigurationManagement.CleanUpUserSettingSection, Vestas.Firecrest.Common, Version=4.1.0.90, Culture=neutral, PublicKeyToken=null" />
        <section name="ConfigurationSettings" type="Vestas.Firecrest.ConfigurationManagement.ConfigurationSettingsSection, Vestas.Firecrest.Common, Version=4.1.0.90, Culture=neutral, PublicKeyToken=null" />
        <section name="GeneralUserSettings" type="Vestas.Firecrest.ConfigurationManagement.GeneralUserSettingsSection, Vestas.Firecrest.Common, Version=4.1.0.90, Culture=neutral, PublicKeyToken=null" />
        <section name="ShowIPSelectorSettings" type="Vestas.Firecrest.ConfigurationManagement.ShowIPSelectorSection, Vestas.Firecrest.Common, Version=4.1.0.90, Culture=neutral, PublicKeyToken=null" />
        <section name="ShowWelcomeDialogSettings" type="Vestas.Firecrest.ConfigurationManagement.ShowWelcomeDialogSection, Vestas.Firecrest.Common, Version=4.1.0.90, Culture=neutral, PublicKeyToken=null" />
    </configSections>
    <AutoSyncReleasePackagesSettings AutoSyncReleasePackagesOnStartup="false" />
    <CleanUpSection LastCleanUpDate="12/19/2012 11:24:23" />
    <CleanUpUserSettings PromptBeforeCleanUp="Yes" HistoricalDataOverwriteOnConnect="NotSpecified"
        TimeBetweenCleanUp="60.00:00:00" MaxDiskQuota="10737418240" />
    <GeneralUserSettings PromptBeforeExit="true" />
    <ShowIPSelectorSettings ShowIPSelectorOnConnect="true" />
    <ShowWelcomeDialogSettings ShowWelcomeDialogOnStartup="true" />
</configuration>
 
 
I have placed the file "LabVIEW.exe.config" in the LV 8.2.1 directory with this content:
 
<?xml version ="1.0"?>
<configuration>
   <startup useLegacyV2RuntimeActivationPolicy="true">
      <supportedRuntime version="v4.0.30319"/>
   </startup>
</configuration>
 
Does anyone knows what to do?
 
Thank in advance
Bjarne
0 Kudos
Message 1 of 4
(2,680 Views)

Hi Bjarne

 

The trick with including a LabVIEW.exe.config was public introduced and documented with LabVIEW 2010, but due to the similarities in the LabVIEW Core these commands should also work fine in LabVIEW 2009.

 

But I'm pretty sure you wont have much luck with using this in LabVIEW versions prior to 2009, i.e. LabVIEW 8.2.1

 

 

Best Regards

Anders

0 Kudos
Message 2 of 4
(2,636 Views)

Hi Anders

 

Thank you.

I thought so, but lived with little hope that it could be doneSmiley Sad

 

Regards Bjarne

0 Kudos
Message 3 of 4
(2,633 Views)

You are welcome.

 

I won't say for sure that it is impossible, but at least I have search for internal workarounds but I haven't been able to find any, so I don't think it is possible.

 

 

Best Regards

Anders Rohde 

0 Kudos
Message 4 of 4
(2,630 Views)