Thread Subject: field and structure calling

Subject: field and structure calling

From: ching l

Date: 18 Jul, 2008 20:30:21

Message: 1 of 6

Did I misunderstand the use of field and structure?
Can someone point out my mistakes please.


%% PLAY AUDIO
function select_audio_Callback(hObject, eventdata, handles)

handles.randValue = rand;
wavplay(samples{ceil(length(samples)*handles.randValue)}{:}) ;

guidata(hObject, handles);

%%------------------------------

%% ANSWER

function answer_faster_Callback(hObject, eventdata, handles)

%% write answer in text with the corresponded audio
csvwrite(num2str (get(handles.randValue, 'Value')),[1]);

guidata(hObject, handles);

Subject: field and structure calling

From: Bruno Luong

Date: 18 Jul, 2008 20:42:02

Message: 2 of 6

"ching l" <chinglnc@hotmail.com> wrote in message
<g5qugt$77j$1@fred.mathworks.com>...

> Can someone point out my mistakes please.
>

Here:

get(handles.randValue, 'Value')

Subject: field and structure calling

From: ching l

Date: 18 Jul, 2008 21:08:02

Message: 3 of 6

"Bruno Luong" <b.luong@fogale.fr> wrote in message
<g5qv6q$f1p$1@fred.mathworks.com>...
> "ching l" <chinglnc@hotmail.com> wrote in message
> <g5qugt$77j$1@fred.mathworks.com>...
>
> > Can someone point out my mistakes please.
> >
>
> Here:
>
> get(handles.randValue, 'Value')

a bit more hint?

Subject: field and structure calling

From: Bruno Luong

Date: 18 Jul, 2008 21:20:03

Message: 4 of 6

"ching l" <chinglnc@hotmail.com> wrote in message
<g5r0ni$f2$1@fred.mathworks.com>...

>
> a bit more hint?

toto.pocketmoney=1000;

% Question: How do you retrieve 1000 from toto?
% Bruno

Subject: field and structure calling

From: ching l

Date: 18 Jul, 2008 21:27:02

Message: 5 of 6

"Bruno Luong" <b.luong@fogale.fr> wrote in message
<g5r1e3$9fm$1@fred.mathworks.com>...
> "ching l" <chinglnc@hotmail.com> wrote in message
> <g5r0ni$f2$1@fred.mathworks.com>...
>
> >
> > a bit more hint?
>
> toto.pocketmoney=1000;
>
> % Question: How do you retrieve 1000 from toto?
> % Bruno

hey, I GOT IT!!!

THANKS FOR THE HINT!!!

Subject: field and structure calling

From: Bruno Luong

Date: 18 Jul, 2008 21:36:02

Message: 6 of 6

"ching l" <chinglnc@hotmail.com> wrote in message
<g5r1r6$dd6$1@fred.mathworks.com>...
> "Bruno Luong" <b.luong@fogale.fr> wrote in message

>
> hey, I GOT IT!!!
>

You got toto's pocketmoney???

Bruno

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
gui ching l 18 Jul, 2008 16:35:05
field ching l 18 Jul, 2008 16:35:05
structure ching l 18 Jul, 2008 16:35:05
rssFeed for this Thread

Contact us at files@mathworks.com