Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Mockup & CodeGen, iPhone & iPad
($9.99)

Make your own iPhone apps
and run them live!
(free)

Manu
($0.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum

View Single Post
Old 07-04-2009, 05:51 PM   #5 (permalink)
NewiPhoneDeveloper
Registered Member
 
Join Date: Jul 2008
Posts: 459
Default

Quote:
Originally Posted by dsinc14 View Post
What do i need to fill in with my data.



- (int)getRandomNumberint)from toint)to {

return (int)from + arc4random() % (to-from+1);
}
I usually create a NSMutableArray in my .h file, like:

Code:
NSMutableArray *nameOfMyArray;

//below } of @interface in your .h file @property:

@property (nonatomic, retain) NSMutableArray *nameOfMyArray;
in your .m, first synthesize:

Code:
@synthesize nameOfMyArray;

//if you have a viewDidLoad method, allocate space for your array there and add the items:

nameOfMyArray = [[NSMutableArray alloc] initWithObjects:@"nameOfImage1Without_without.png", @"nameOfImage2Without.png", nil];

//don't forget to release your array inside the dealloc method:

- (void)dealloc {
    [nameOfMyArray release];
    [super dealloc];
}
NewiPhoneDeveloper is offline   Reply With Quote
 

» Advertisements
» Stats
Members: 158,835
Threads: 89,209
Posts: 380,641
Top Poster: BrianSlick (7,129)
Welcome to our newest member, Aubrey69
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 03:10 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.