🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.next.programmer
Article #394

class problem

#394
From: A. Jetha
Date: Sat, 01 Aug 1992 19:11
47 lines
1640 bytes
THANKS to everybody that sent me messages on the following problem.

>This may seem like a dumb question, but how do you call a method in a
>CustomClass from another method in the same CustomClass??
>
>Eg.
>              CustomClass has 2 methods.
>              - helloThere
>              - seeYouTommorow
>
>              When I'm in, or done with, helloThere, how can I call
>              seeYouTommorow from within helloThere?
>
>I hope someone can help.
>Thanks

For some reason the compiler was telling me "CustomClass does not respond
to seeYouTommorow method"  when I used [self seeYouTommorow];

My problem was 2-fold.

1  the actual method name was 
              - seeYouTommorow:sender

              This was overcome by using:
              [self seeYouTommorow:self];

2  the second line of code was:

              value1=[sender floatValue];  (value1 is a global variable)

              To correct this problem I moved value1 into helloThere, and
              removed it from seeYouTommorow.
              This resolved my problem.

Thanks once again for all the responces, I appreciate it!!!!

PS Unfortunately I didn't know how to spell 'tomorrow', but now I do.
   Thanks for the correction.

A.J.
ajetha@gpu.utcs.utoronto.ca
or try 
ajetha@utcs.utoronto.ca

              
Technical Details
Message-ID: <BsBJyG.BKH@gpu.utcs.utoronto.ca>
Path: arc1-ca.pugleaf.net!sparky!uunet!usc!cs.utexas.edu!torn!utgpu!ajetha

Show Full Headers
Complete Article Headers
Newsgroups: comp.sys.next.programmer
Path: arc1-ca.pugleaf.net!sparky!uunet!usc!cs.utexas.edu!torn!utgpu!ajetha
From: ajetha@gpu.utcs.utoronto.ca (A. Jetha)
Subject: class problem
Message-ID: <BsBJyG.BKH@gpu.utcs.utoronto.ca>
Organization: UTCS Public Access
Date: Sat, 1 Aug 1992 19:11:04 GMT
Lines: 47