From: David Bolin on 16 May 2010 04:59 Hello Ive got a gui program that has a table in it. In the gui code, how do i refer to the table if i want to write an 'if' statement about it? Ive tried using its tag but it keeps telling me its an underfined variable and i cant use hObject cos there are lots of hObjects in the code. Im soo stuck. Thankyou
From: Steven Lord on 17 May 2010 10:32 "David Bolin" <cruelsinger(a)gmail.com> wrote in message news:hsoc4o$csb$1(a)fred.mathworks.com... > Hello > > Ive got a gui program that has a table in it. I assume this is a uitable object? > In the gui code, how do i refer to the table if i want to write an 'if' > statement about it? > Ive tried using its tag but it keeps telling me its an underfined variable > and i cant use hObject cos there are lots of hObjects in the code. Im soo > stuck. If your table is in fact a uitable object, and it's handle is included as part of the handles structure, then extract the appropriate properties of the uitable and use those extracted properties in your IF statement. For example, if your uitable's tag is MyTable, then: data =get(handles.MyTable, 'Data'); if iscell(data) % extract data from the cell else % extract data from the matrix end -- Steve Lord slord(a)mathworks.com comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ
|
Pages: 1 Prev: How to calculate image hash as a bit sequence of 0's and 1's Next: R square statistics problem |