How to pass values from GUI to workspace

Antworten (2)

Jan
Jan am 4 Dez. 2012

0 Stimmen

To which workspace? Each function has its own one. Do you mean the base-workspace, which is available in the command window? Then:
assignin('base', 'A', 123 + 17)
Please note, that using such remote-creation of variables frequently will make it much harder to debug your program. Imagine you have tweo different GUIs which assign the same variable. Then it is impossible to find the function, which has applied the last changes.

Kategorien

Mehr zu Mathematics finden Sie in Hilfe-Center und File Exchange

Produkte

Tags

Gefragt:

am 4 Dez. 2012

Community Treasure Hunt

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

Start Hunting!

Translated by