Live Script Controls in (For) Loop
Hello,
Is there a way to create a dynamic input field using live script controls? I want to populate the livescript with N controls (ex. "Edit Field") inputs prior to the user providing input values. The user specifies N, and the live script then generates N controls.
I assume have to embed the control in a (for) loop. I am not hard coding any controls, at the moment. I prefer to have the controls embedded in the live script and not have to use a inputdlg box.
Thank You.
N = 2;
for i = 1:N
fprintf("Livescript Input %d n",i)
%LIVESCRIPT CONTROL HERE ("EDIT FIELD")
end
% N POPULATED CONTROLS HERE
% USER ENTERS N INPUTS HEREHello,
Is there a way to create a dynamic input field using live script controls? I want to populate the livescript with N controls (ex. "Edit Field") inputs prior to the user providing input values. The user specifies N, and the live script then generates N controls.
I assume have to embed the control in a (for) loop. I am not hard coding any controls, at the moment. I prefer to have the controls embedded in the live script and not have to use a inputdlg box.
Thank You.
N = 2;
for i = 1:N
fprintf("Livescript Input %d n",i)
%LIVESCRIPT CONTROL HERE ("EDIT FIELD")
end
% N POPULATED CONTROLS HERE
% USER ENTERS N INPUTS HERE Hello,
Is there a way to create a dynamic input field using live script controls? I want to populate the livescript with N controls (ex. "Edit Field") inputs prior to the user providing input values. The user specifies N, and the live script then generates N controls.
I assume have to embed the control in a (for) loop. I am not hard coding any controls, at the moment. I prefer to have the controls embedded in the live script and not have to use a inputdlg box.
Thank You.
N = 2;
for i = 1:N
fprintf("Livescript Input %d n",i)
%LIVESCRIPT CONTROL HERE ("EDIT FIELD")
end
% N POPULATED CONTROLS HERE
% USER ENTERS N INPUTS HERE live script, control, loop, user MATLAB Answers — New Questions