Best way to implement a multi-view workflow in App Designer, MatLab 2016b

7 ビュー (過去 30 日間)
Amund Grorud
Amund Grorud 2017 年 5 月 25 日
回答済み: J Philps 2017 年 5 月 31 日
I'm creating my first app with App Designer, and have a question about the preferred way to have implement a multi-view workflow. I'm going to process some images through multiple manipulations (that has to be done in a specific order) and I'm thinking I'll use a next button to go to the next page of settings. I can't seem to find any examples that use more than one view (that doesn't use tabs) on the matlab.com/examples page.
The alternatives I have as far as I know are these:
  • each window is a unique app, calling on each other sending the picture forth/back.
  • a new window (UIFigure) is opened each time I need new settings.
  • I clear the UIFigure for buttons each time and show the next ones.
I'm just hoping to avoid a complete redo of the program and want to get it right the first time.

回答 (1 件)

J Philps
J Philps 2017 年 5 月 31 日
Another option would be to keep track of all the buttons in each 'page' of settings (maybe through a struct or something similar) and toggle the visibility of those ui objects based on which page of settings you are currently utilizing.
For example, to set a button called Button to be invisible, you can use the following line of code:
app.Button.Visible = 'off';
This will be easier than actually clearing all of the buttons each time, since all of the callbacks and other functionality will remain, they will just be invisible. When you want the button to appear again, you can just set the visible property back to 'on:
app.Button.Visible = 'on';

カテゴリ

Help Center および File ExchangeDevelop uifigure-Based Apps についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by