MATLAB SIMULINK 7 - GRAPHICAL USER INTERFACE Guia do Utilizador Página 602

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 759
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 601
12 Code a Programmatic GUI
function pushbu tton _callback(hObject, eventdata, var1, va r2)
plot(var1,var2)
When you run this GUI by pressing the push button, you see a line graph of
myvar appearing as a magenta dashed line, similar to the following (graphs
candifferduetousingthe
rand function to generate data).
Because the value of myvar was copied into the callback when it was set,
clicking the button always produces the same plot, even if the value of
myvar
changes in the base workspace.
For m ore information, see “D efining Callbacks as a Cell Array of Strings
—SpecialCase.
12-16
Vista de página 601
1 2 ... 597 598 599 600 601 602 603 604 605 606 607 ... 758 759

Comentários a estes Manuais

Sem comentários