フィルターのクリア

what is the alternative of cd in .executable app ?

4 ビュー (過去 30 日間)
Kaustubh hike
Kaustubh hike 2021 年 9 月 3 日
回答済み: Rik 2021 年 9 月 3 日
Hi,
I am converting mdf into mat, for the same I have created executable app. while executing following commands, the currently dictionary should be the folder having .mdf files . If I do that by puting cd command then it gives error while running the executable app.
What can be solution?
doscmd = ['"' converterfile '" -C:' convtype '.dll -IF:"' inifile '" "' files{f} '" ' tempconvfilename];
[status, result] = dos(doscmd);
  2 件のコメント
Rik
Rik 2021 年 9 月 3 日
Did you try the Matlab cd, or the system cd? You should be able to add it to your system call.
Kaustubh hike
Kaustubh hike 2021 年 9 月 3 日
Hi @Rik
Thanks for teh response
How to do that ? ( adding it to system call)
Its matlab cd now , currently it looks like below
cd(pathTargetFiles);
All files are there under 'pathTargetFiles' which I am converting by using this app.

サインインしてコメントする。

採用された回答

Rik
Rik 2021 年 9 月 3 日
You can use && to execute another command if the first one completes successfully:
doscmd = [...
'cd /d "' pathTargetFiles '" && ' ...
'"' converterfile '" -C:' convtype '.dll -IF:"' inifile '" "' files{f} '" ' tempconvfilename];
[status, result] = dos(doscmd);
The /d switch allows switching between partitions as well (in case either pathTargetFiles or your system happen to be on something other than C).

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeApplication Deployment についてさらに検索

製品


リリース

R2021a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by