Application compiler: Command line Input type options missing

4 ビュー (過去 30 日間)
Deepa Maheshvare
Deepa Maheshvare 2021 年 8 月 3 日
コメント済み: Kojiro Saito 2021 年 8 月 4 日
I am using Application compiler for generating a standalone application. I'm following the documenttaion available here
I don't find the `Command line Input type options` shown here ( ) above Additional installer options.
I'm using 2021a.
Could someone help me with this? I'd like to include `Command line Input type options` to pass input arguments to the executable file.


Kojiro Saito
Kojiro Saito 2021 年 8 月 3 日
編集済み: Kojiro Saito 2021 年 8 月 3 日
"Command line input type options" will be shown if m file is a function.
In the documentation example which you mentioned, the magicsquare.m file is a function.
function m = magicsquare(n)
if ischar(n)
m = magic(n);
It seems that your main.m is a script file.
For detail about script vs function, this document will be helpful.
  4 件のコメント
Kojiro Saito
Kojiro Saito 2021 年 8 月 4 日
This document(Developing Classes — Typical Workflow) will be helpful.
There various ways to implement your class.
Simple way is the following.
classdef classname
properties (SetAccess = private)
function val=classname(arg)
function out = main(arg)
myClass = classname(arg);
out = myClass.Number;
By the way, it's getting going away from the original question, so if you have further question, it's better to post it as another question.


その他の回答 (0 件)

Community Treasure Hunt

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

Start Hunting!

Translated by