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 > iPhone SDK Development Forums > iPhone SDK Development

Reply
 
LinkBack Thread Tools Display Modes
Old 08-15-2010, 07:07 PM   #1 (permalink)
Registered Member
 
Join Date: Aug 2010
Posts: 5
fabie1 is on a distinguished road
Question Text in an app

Hi,

I'm new here and i'm new to iPhone/iPad development.
I'm almost done reading Apress' "Beginning iPhone development (3)" and I'm really making progress. Now I have one, probably stupid, question. When you have an app with a lot of text, just like a story, how do you include it in your app? Do you have it hardcoded into the app (doesn't sound like the best idea to me), do you have a txt file and load it into an NSString, an array, a dictionary? I really don't know what's the best approach here and I'd appreciate some advice.

So it's (a lot of) text that's gotta be included in the app (not coming from the Internet) and it should be easily readable.

Thanks,

Fabian
fabie1 is offline   Reply With Quote
Old 08-15-2010, 07:13 PM   #2 (permalink)
Registered Member
 
Join Date: Jun 2010
Posts: 42
Jackson13 is on a distinguished road
Smile

I have a bunch of quizzes for my app. I have each quiz in its own txt file and then it is loaded into an array in order to be previewed. I started off with it being hardcoded and it took a really long time. Now with just one quiz view controller it is so much easier and dynamic.
Jackson13 is offline   Reply With Quote
Old 08-15-2010, 07:27 PM   #3 (permalink)
Registered Member
 
Join Date: Aug 2010
Posts: 5
fabie1 is on a distinguished road
Default

Ok thanks! So you load the data from the txt file into a NSArray and then present in a UITextView? Thanks for helping me out! Btw, your app looks cool, maybe I'll buy it later
fabie1 is offline   Reply With Quote
Old 08-16-2010, 07:20 PM   #4 (permalink)
Registered Member
 
Join Date: Jun 2010
Posts: 42
Jackson13 is on a distinguished road
Smile

Yeah. So I have the UITextview and I just keep appending the question and answers. It is just so much easier and if you want to change something you just change the text file, no code. And thanks for the comment about my app.
Jackson13 is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 348
5 members and 343 guests
bignoggins, Chickenrig, givensur, linkmx, PlutoPrime
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,657
Threads: 94,118
Posts: 402,894
Top Poster: BrianSlick (7,990)
Welcome to our newest member, jenniead38
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 12:46 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0