luo zhiyong Posted June 16, 2021 Report Share Posted June 16, 2021 Hello, all, I meet a problem related on ActiveX class. The VI's function is write Array to mat file by call MatIO ActiveX class, Program as below, the function will work at Win7 system Operator account but not on Admin account, Also it isn't work on Win server 2016 system. Error -2147221164 occurred at Class not registered in MATWriteString.vi->DataLogger Convert Binary File to Matlab Format.vi->DataLogger Diagnostic.vi This error code is undefined. Undefined errors might occur for a number of reasons. For example, no one has provided a description for the code, or you might have wired a number that is not an error code to the error code input. Additionally, undefined error codes might occur because the error relates to a third-party object, such as the operating system or ActiveX. For these third-party errors, you might be able to obtain a description of the error by searching the Web for the error code (-2147221164) or for its hexadecimal representation (0x80040154). Enviroment: winserver 2016(64 bit) Matlab compiler runtime version(32 bit): 7.17(I installed 64bit version doesn't work too). the system can't find matio ActiveX class, I don't know how to register this ActiveX or is it supported on Winserver 2016 system? It will gratitude that can get your support. Thank you Quote Link to comment
ShaunR Posted June 16, 2021 Report Share Posted June 16, 2021 You can register ActiveX controls using regsvr32.exe (located in windows/system32). Quote Link to comment
Rolf Kalbermatter Posted June 16, 2021 Report Share Posted June 16, 2021 (edited) 3 hours ago, luo zhiyong said: Hello, all, the system can't find matio ActiveX class, I don't know how to register this ActiveX or is it supported on Winserver 2016 system? It will gratitude that can get your support. Thank you Note that LabVIEW does not officially support Windows Server OS. I believe it will generally work, but ActiveX is definitely one of the areas I have my suspicions. Windows Server does quite a bit with security policies to lock the computer down for more security. ActiveX may very well be one area that is very much affected by this. Have you talked with MatLab if they fully support Windows Server editions? In any case, ActiveX needs to be installed and that also means modifications to the registry and the installer can choose if he wants to make the component available system wide or just for the current user. Your component may be such a case, or Windows Server may enforce ActiveX registration on a per user base, or maybe even disallow ActiveX installation into the Admin account without some special command line switch. We don't know and we don't generally use Windows Server. They are usually maintained by IT staff and they tend to be very unhappy about anyone wanting to install anything on "their" systems, so it basically never happens. Edited June 16, 2021 by Rolf Kalbermatter Quote Link to comment
dadreamer Posted June 16, 2021 Report Share Posted June 16, 2021 Also take into account the bitness of your ActiveX libraries, that you're going to use. If you want to use 32-bit libraries, then you invoke "%systemroot%\SysWoW64\regsvr32.exe" in your command shell. For 64-bit libraries you invoke "%systemroot%\System32\regsvr32.exe" to register. That is true on 64-bit Windows. Better do this manually and, of course, with administrator privileges (otherwise it may not register or may report "fake" success). Quote Link to comment
luo zhiyong Posted June 18, 2021 Author Report Share Posted June 18, 2021 On 6/16/2021 at 5:29 PM, ShaunR said: You can register ActiveX controls using regsvr32.exe (located in windows/system32). Thanks, I try to using regsvr32.exe to register this ActiveX controls related this link:https://docs.microsoft.com/en-us/previous-versions/troubleshoot/visualstudio/foxpro/register-activex-control-manually, but even I can't find the the .ocx file for Matio, so I think it is installed by matlab compiler. I Think I need ask Matlab Team. Quote Link to comment
luo zhiyong Posted June 18, 2021 Author Report Share Posted June 18, 2021 On 6/16/2021 at 5:44 PM, Rolf Kalbermatter said: Note that LabVIEW does not officially support Windows Server OS. I believe it will generally work, but ActiveX is definitely one of the areas I have my suspicions. Windows Server does quite a bit with security policies to lock the computer down for more security. ActiveX may very well be one area that is very much affected by this. Have you talked with MatLab if they fully support Windows Server editions? In any case, ActiveX needs to be installed and that also means modifications to the registry and the installer can choose if he wants to make the component available system wide or just for the current user. Your component may be such a case, or Windows Server may enforce ActiveX registration on a per user base, or maybe even disallow ActiveX installation into the Admin account without some special command line switch. We don't know and we don't generally use Windows Server. They are usually maintained by IT staff and they tend to be very unhappy about anyone wanting to install anything on "their" systems, so it basically never happens. Thanks your kindly help, this is very useful, I think i need ask Matlab team if the ActiveX is support or not on winserver2016. because the original Vi's function is only write array/number(.bin file) to .mat file, I really want to find a new/official way to do this function, the ActiveX is hard to migration and get further support. Quote Link to comment
mcduff Posted June 18, 2021 Report Share Posted June 18, 2021 MAT files are now just H5 files(HDF). Look at the library https://h5labview.sourceforge.io/ and find the example for writing a MAT file. You just need to add a special header in the beginning. I assume the dlls needed will work on Windows server, but am not sure. 1 Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.