Official Forum for Programming in Objective-C (the iPhone Programming Language) - Stephen Kochan

Old Stuff => Chapter 7 - More on Classes => : JRIH December 04, 2016, 06:49:37 PM

: Problems implementing initial program in Ch. 7
: JRIH December 04, 2016, 06:49:37 PM
Using Objective-C 6th edition and Xcode 6.3.
When I try to type in the initial program, into the different files: main.m Fraction.h and Fraction.m, I get error messages all over the place.
The Fraction.m file is actually named NSObject+Fraction.m. and inside it says to #import "NSObject+Fraction.h".
in main.m, when I put in Fraction *myfraction = [[Fraction alloc] init];, i get a warning that says "Fraction is undeclared".  I did put in the entire program before looking at the warnings.
These are just a couple of examples of many.
I followed the chapter 2 and Chapter 7 instructions, but nothing is going right.  I hope you can help me and let me know any further information that you may need.

Sorry, the copyright must be in the template.
Please notify this forum's administrator that this site is missing the copyright message for SMF so they can rectify the situation. Display of copyright is a legal requirement. For more information on this please visit the Simple Machines website.