So I've been trying to get to grips with MATLAB GUIs and looked at:
But when I try to run this code, I get the following errors:
Error using movegui (line 99)
unrecognized input argument
Error in simple_gui2 (line 52)
movegui(f,'center')
I can't see what's wrong with how movegui is being used.

 Risposta accettata

Geoff Hayes
Geoff Hayes il 15 Nov 2014

0 voti

David - which version of MATLAB are you using?
The code that you are trying to use (from the given link) was developed with MATLAB R2014b. If I try to run the same code on R2014a, I see the same error as you. This is because of how handles to figures are now managed in R2014b. Rather than being a graphics handle (resembling a double like 172.343434) it appears to be more like a structure/object with properties.
If you want to find something similar for your version of MATLAB, then go to archived MATLAB documentation, choose the appropriate version, and search for whatever it is you are interested in. For example, a similar simple GUI for R2014a can be found at R2014a - creating a simple programmatic GUI .

1 Commento

David
David il 15 Nov 2014
I am using R2013a and just looked up the documentation for this version which is giving me code that works. Thanks!

Accedi per commentare.

Più risposte (0)

Categorie

Scopri di più su App Building in Centro assistenza e File Exchange

Richiesto:

il 15 Nov 2014

Commentato:

il 15 Nov 2014

Community Treasure Hunt

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

Start Hunting!

Translated by