Saving to TXT from standalone executable
古いコメントを表示
Hi all, I've successfully compiled a Matlab program to a standalone executable for Mac OS, but there's only one bug remaining. The program needs to be able to read from and write to a text file. After compiling, this function no longer works, nor does the text file show up anywhere in the "distrib" or "src" directories. Does anyone know what I might be doing wrong?
採用された回答
その他の回答 (1 件)
Kaustubha Govind
2011 年 6 月 24 日
0 投票
Are you including the data file (to read from) under "Other/Additional files" in DEPLOYTOOL? This will package the file in the CTF along with your compiled application and make it available to it at runtime.
Regarding the writing, do you specify a path where the file must be created? It is possible that you application is writing to the folder where the corresponding CTF is extracted (which is inside $TEMP, unless you have specified MCR_CACHE_ROOT - see Overriding Default CTF Archive Embedding Using the MCR Component Cache for details).
カテゴリ
ヘルプ センター および File Exchange で Standalone Applications についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!