# Invalid mex file error

**URL:** <https://mworks.discourse.group/t/invalid-mex-file-error/427>\
**Category:** Support\
**Created:** [December 22, 2016, 8:13pm UTC](https://mworks.discourse.group/t/invalid-mex-file-error/427 "2016-12-22T20:13:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [December 22, 2016, 8:13pm UTC](https://mworks.discourse.group/t/invalid-mex-file-error/427/1 "2016-12-22T20:13:06Z")

</div>

Hi I want to read a recorded data set by mwork. I have installed it and it is working but for my reading the data in matlab I have got the following error. please let me know what can I do.  
Invalid MEX-file ‘./…Desktop/MWorks 2/+mworks/mwfeval.mexmaci64’: dlopen(/…/Desktop/MWorks 2/+mworks/mwfeval.mexmaci64, 6):  
Symbol not found: \_\_ZN2mw5DatumC1EP13\_\_ScarabDatum  
Referenced from: /…/Desktop/MWorks 2/+mworks/mwfeval.mexmaci64  
Expected in: /Library/Frameworks/MWorksCore.framework/Versions/A/MWorksCore  
and just to make it clear the last file which is named as expected "/Library/Frameworks/MWorksCore.framework/Versions/A/MWorksCore"does exist on the path :

thanks

---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [December 23, 2016, 6:13pm UTC](https://mworks.discourse.group/t/invalid-mex-file-error/427/2 "2016-12-23T18:13:28Z")

</div>

Hi,

An MWorks MEX file works only with the version of MWorks that it was compiled against. I’m guessing that you copied the MEX file from one MWorks version and are now trying to use it with a different version.

You should only use the MATLAB files installed in /Library/Application Support/MWorks/Scripting/Matlab. If you want those files to be accessible from another path, try creating a symbolic link in the desired location.

Cheers,  
Chris Stawarz

---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [July 19, 2022, 10:00pm UTC](https://mworks.discourse.group/t/invalid-mex-file-error/427/3 "2022-07-19T22:00:25Z")

</div>


