How to increase the number of input options in dialog box?
1 view (last 30 days)
Show older comments
How to increase number of input options or lines in dialog box?
eg: if the number of elements is 2 then it should ask
enter length
length 1 __
length 2 __
and if the number of elements is 3 it should ask
enter length
length 1 __
length 2 __
length 3 __
(ei the number of input length lines should increase with respect to the number of elements)
0 Comments
Answers (1)
Geoff Hayes
on 30 Jan 2019
N = 3;
prompts = {};
for k = 1:N
prompts = [prompts sprintf('length %d',k)];
end
results = inputdlg(prompts,'enter length');
0 Comments
See Also
Categories
Find more on Logical in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!