MATLAB Answers

How to use user input to change properties like title, axes limits in App Designer?

78 views (last 30 days)
I am trying to use App Designer and want to link a text edit field to a label or axes limits. How can I do this?

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 30 Jan 2019
The following documentation provides an example of using the value of a 'uieditfield' to change the value of a 'uilabel' element. Using a similar approach, you can update the title of a plot since the Title property accepts a string as an input:
For updating the x and y axis limits, you could use an 'uieditfield' that accepts numeric input and use that value to update the axis limit properties. For information on creating an edit field which accepts numeric input, refer here:
To access and change the properties of an axes, you can use the following syntax, 'app.UIAxes.PropertyName'. For more information on the various properties of an 'uiaxes' that you can access/modify, refer to the following documentation page:

More Answers (0)

Tags

No tags entered yet.

Products


Release

R2018b

Community Treasure Hunt

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

Start Hunting!