I just tried the example of 'magic square'. I use microsoft visual studio 2010 as my compiler. I tested the example on my PC with XP and notebook with win 7. They happened the same problem (error code = 2). Please tell me how to fix it. Thanks.
The following is the error information.
LINK : fatal error LNK1181: cannot open input file 'Documents\MATLAB\xlmagic\src\xlmagic.def' D:\PROGRA~1\MATLAB\R2011B\BIN\MEX.PL: Error: Link of 'D:\MYDOCU~1\MATLAB\XLMAGIC\SRC\xlmagic_1_0.dll' failed. Error: An error occurred while shelling out to mbuild (error code = 2). Unable to build executable. Warning: mcc failed to create Excel Add-in "d:\My Documents\MATLAB\xlmagic\src\xlmagic.xla", you can manually create the Add-in by importing the .bas file into Excel.
Best Answer