Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

Unable to load DLL nianlys.dll after upgrading Measurement studio support for Visual Studio 2017

Hello team,

 

Recently we have installed the beta version of NI to support Measurement studio for Visual Studio 2017. After the upgrade we have updated all the references accordingly. The .Net Winforms application was packaged and installed on client machine, we are seeing the below runtime exception.

 

System.DllNotFoundException: Unable to load DLL 'nianlys.dll': A dynamic link library (DLL) initialization routine failed. (Exception from HRESULT: 0x8007045A)     at NationalInstruments.Analysis.Internal.s.d(Double[] A_0, IntPtr A_1, Double& A_2)     at NationalInstruments.Analysis.Math.Statistics.Mean(Double[] inputData)   

 

We used to have the same issue prior to the upgrade to Visual Studio 2017 using Visual Studio 2013, upon doing some research in previous posts, we learned to add the merge module nianlys.msm / nianlys_x64.msm to the setup project, doing so resolved this run time exception. Now after the upgrade we are running into the same issue again and we are not able to find the merge module for nianlys.msm to add to our setup project. Seems after the upgrade to Visual studio 2017 NI has removed this merge module or replaced with any other merge module.

 

This is a show stopper issue for us. Kindly help in resolving ASAP.

 

Thanks,

Baba

 

0 Kudos
Message 1 of 19
(5,432 Views)

Please ensure you are building for the appropriate build type:

https://forums.ni.com/t5/Measurement-Studio-for-NET/nianlys-dll-unable-to-be-found-on-Windows-7/td-p...

 

Depending on your OS version you will need to include different things:

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000019W6SSAU&l=en-US

 

Dane S.
Product Support Engineer
National Instruments
0 Kudos
Message 2 of 19
(5,412 Views)

Thank you Dane.

 

I did follow the steps and instructions given in the links provided in your reply. Still the issue is not resolved. I did add the LV140000_BLASLAPACK.dll as my target machine is Windows 10. Added a special folders 'System Folder' and 'Program Files Folder' to the deployment project and my application and deployment project are all pointing to 64 bit machines. Deployed my setup project as an Administrator.

 

I am trying to understand why the merge modules mkl.msm and nianlys_x64.msm are missing from the beta version of the Measurement studio for Visual Studio 2017, maybe that's the issue or if not what are the merge modules that needs to be included for the nianlys.dll?

 

Attached are the setup project and application project properties and the .msm modules added to the setup project.

 

 

0 Kudos
Message 3 of 19
(5,368 Views)

I might try doing an XCopy to copy the appropriate assemblies over to the deployment computer:

http://zone.ni.com/reference/en-XX/help/375857A-01/xml/netdeploymentfiles/

 

Also you mentioned you are using a beta, is this the Beta of Measurement Studio? If so these actually have their own forums that you should have been sent a link to which will have better resources to support and answer questions than the normal Measurement Studio Forums.

Dane S.
Product Support Engineer
National Instruments
0 Kudos
Message 4 of 19
(5,360 Views)

Thank you Dane.

 

Yes, this is a beta version of Measurement Studio 2017. I will post this issues onto the said forums. 

0 Kudos
Message 5 of 19
(5,358 Views)

Dane, could you provide me the link to post my issue to the Beta version community discussion forum?

0 Kudos
Message 6 of 19
(5,355 Views)

Did you ever find a solution to this? I have the EXACT same problem as you (except that I'm using the released version of MS2019, not beta). I am a longtime user of measurement studio and along the way started getting the could not load nianlys.dll message. Found through much searching that I could resolve this by adding the nianlys.msm and nianlys_x64.msm to my setup project. However, now that I have installed Measurement Studio 2019, they are no longer available for me to include in my setup project and therefore, the unable to load nianlys.dll error has returned.

 

Thanks,

Mike

0 Kudos
Message 7 of 19
(4,787 Views)

Have you tried the steps in the following KnowledgeBase Article?

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000019W6SSAU&l=en-CA

0 Kudos
Message 8 of 19
(4,749 Views)

This is not the problem or the solution. This is a DIFFERENT problem that causes the same error message to be displayed. I tried these suggestions many years ago when the problem surfaced for the first time. They weren't the solution at that time either. After searching and working with NI, we (NI support engineers and I) came to the understanding that the solution for the problem was that I needed to include a merge module in my setup project (nianlys.msm in the x86 case and nianlys_x64.msm in the x64 case). This merge module correctly installed nianlys.dll and it's dependencies as well as wrote the information to the registry to allow nianlys.dll to be found. This was the solution for many years and worked well. The new problem that the original poster has found and that I have now found as well is that for some reason the nianlys.msm and nianlys_x64.msm merge modules are no longer included as part of the Measurement Studio installation as of Measurement Studio 2019. 

I have just found that adding the OLD nianlys.msm and nianlys_x64.msm from Measurement Studio 2015 to the setup project still solves the problem however I am very surprised that this works and I expect that it will quit working at some point in the very near future when NI makes some change in Measurement Studio that breaks this surprising behavior.

 

If the merge modules are no longer required, then NI needs to make the user community aware of how to get nianlys.dll and it's dependencies properly installed. If the merge modules ARE required, then NI needs to get them back into the installation of Measurement Studio. I opened a support request on my subscription (ref# 7776737) but as evidenced by the fact that the support engineer and I talked about this issue for an hour or two but he is still sending the same irrelevant document that you sent, I don't think that the front line support engineers are going to be able to understand the issue enough to resolve it. I think it will need to be elevated to the Measurement Studio R&D engineers to be able to be understood and resolved. I don't have a high degree of confidence that this will happen though as the only thing that keeps being suggested over and over is that old solution that was only useful for solving a different older problem.

0 Kudos
Message 9 of 19
(4,744 Views)

Hi,

there was no straight forward solution to my problem(for the beta version). The only suggested solution was to clear everything from my machine do a clean re-installation of older NI tools and add the merge modules to the project. I have not updated the MS2019 release version yet, as I had no confidence that this issue will not resurface again  Smiley Wink. I would be loosing plenty of development time running around the solution again. Our plan is to use a completely new machine and install the NI MS2019 version and build the project and see if no issue exists. 

0 Kudos
Message 10 of 19
(4,737 Views)