matlab2012 gui打包,matlab中GUI程序的打包

1.首先对Compiler进行适当的配置,方法是在Matlab命令窗口输入:

Mbuild –setup

2.将M文件编译为独立可执行文件的语法是:

>>mcc –m myfunctionname.m

myfunctionname.exe就是最后的可执行文件的名称。

3.将/MATLAB701/toolbox/compiler/deploy/win32中的MCRinstaller.exe安装到要运行该程序的计算机上

4.将编译生成的相相关文件拷贝到同一目录下,运行myfunctionname.ext即可执行程序

5.此时程序会出现command窗口,影响美观。

有人写好了包避免它的出现,下载地址为:http://www.mathworks.com/matlabcentral/fileexchange/3909

注意它的说明文件:

This program will hide the command window of compiled programs in all versions of Microsoft Windows. To use, change the name in the "suppress.ini" file to the name of your MATLAB EXE file, then run "suppress.exe". You may rename "suppress.exe", but you may not rename "suppress.ini" without editing and recompiling the source code. The files "suppress.exe", "suppress.ini", and your EXE file must all be in the same directory. This utility was created using NSIS (http://nsis.sf.net/). The default settings will run the "test.exe" program included in the ZIP file.

需要将suppress.ini内的路径更改,然后执行suppress.exe即可。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值