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

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

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

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum

View Single Post
Old 03-18-2010, 05:21 PM   #1 (permalink)
cye
14 Year Old App Developer
 
Join Date: Mar 2010
Location: Texas
Posts: 242
cye is on a distinguished road
Default Need help with copying text from UITextView to an array.

when i run it in the simulator i always get terminating_due_to uncaught_exception, this block of code seems to be the problem.

qInput and aInput are UITextViews
and q and a are mutable arrays
Code:
- (IBAction)inputPressed:(id)sender
{
        int i = 1;
	q = [[NSMutableArray alloc]initWithCapacity:20];
	a = [[NSMutableArray alloc]initWithCapacity:20];

	[[q objectAtIndex:i]setText:qInput.text];
	[[a objectAtIndex:i]setText:aInput.text];	
	
	
	i++;
}
whats wrong?




canzhi
cye is offline   Reply With Quote
 

» Advertisements
» Online Users: 640
22 members and 618 guests
7twenty7, cdbeshore, CMSLdesign, dansparrow, e2applets, EvilElf, fiftysixty, Free App Monster, Gaz, gbenna, jbro, jeroenkeij, Kieren Harrold, nestochi, NetGuru, networ, padsoftware, raymng, Rudy, SLIC, taylor202
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,544
Threads: 94,068
Posts: 402,680
Top Poster: BrianSlick (7,989)
Welcome to our newest member, CMSLdesign
Powered by vBadvanced CMPS v3.1.0

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