Re: Global Variables
Re: Global Variables
- Subject: Re: Global Variables
- From: Shawn Erickson <email@hidden>
- Date: Fri, 8 Apr 2005 13:23:13 -0700
On Apr 8, 2005, at 1:10 PM, R T wrote:
extern CSAmt = setFloatValue:aFlt;
Huh? You have define CDAmt as an instance (member) variable of the
class Core, it only exists inside instances of your class Core.
If you want to create an instance of your class "Core" and have its
"CSAmt" ivar set to a float from a control then get the float like you
did and use the "setCSAmt:" method you provided (at least you listed it
in the interface).
[someInstanceOfCore setCSAmt:[AmtField floatValue]];
...or just maybe...
someInstanceOfCore->CSAmt = [AmtField floatValue];
Looking at your code and question I think you need to take some time to
better understand Objective-C messages and objects, etc.
Likely start by reviewing the following...
<http://developer.apple.com/referencelibrary/GettingStarted/GS_Cocoa/
index.html>
<http://developer.apple.com/documentation/Cocoa/Conceptual/ObjectiveC/
OOProgramming/chapter_2_section_1.html>
<http://developer.apple.com/referencelibrary/API_Fundamentals/Cocoa-
fund-date.html>
Also I strongly you review and follow the coding outlines discussed in
the following...
<http://developer.apple.com/documentation/Cocoa/Conceptual/
CodingGuidelines/index.html>
If you are working in Cocoa which it looks like you are it is best to
ask on the Cocoa-Dev list.
<http://www.lists.apple.com/cocoa-dev>
-Shawn
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden