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 11-03-2010, 11:20 AM   #1 (permalink)
Registered Member
 
Join Date: Jan 2010
Location: MA
Posts: 126
nd049 is on a distinguished road
Default Setting TextView to Non-Editable

Hi Everyone,

In one of my apps I'm working on, I have a TextView that I want to be set to non-editable. In I.B. I unchecked the Editable field for it, but that didn't work. So in my ViewDidLoad I did:

Code:
        chatScreen.font = [UIFont fontWithName:@"Georgia" size:16];
	chatScreen.editable = NO;
Which I figured would definitely work, but it didn't again. I've looked and looked but nothing seems to be working. It is vital that it can't be edited because it is a messaging app, so I can't have the users editing each message that other users sent!

Any help would be greatly appreciated!

Last edited by nd049; 11-03-2010 at 05:44 PM.
nd049 is offline   Reply With Quote
Old 11-03-2010, 08:19 PM   #2 (permalink)
Registered Member
 
Join Date: Jan 2010
Location: MA
Posts: 126
nd049 is on a distinguished road
Default

Anyone have any ideas?
nd049 is offline   Reply With Quote
Old 11-03-2010, 08:31 PM   #3 (permalink)
Indie Developer
 
iSDK's Avatar
 
Join Date: Jul 2010
Posts: 1,346
iSDK is on a distinguished road
Send a message via AIM to iSDK
Default

Go into IB and set the textfield as Non Editable.
iSDK is offline   Reply With Quote
Old 11-03-2010, 08:58 PM   #4 (permalink)
Registered Member
 
Join Date: Jan 2010
Location: MA
Posts: 126
nd049 is on a distinguished road
Default

Quote:
Originally Posted by iSDK View Post
Go into IB and set the textfield as Non Editable.
I already did that and it still is editable... and I set it in the code... just doesn't make sense.
nd049 is offline   Reply With Quote
Old 01-20-2011, 03:01 AM   #5 (permalink)
Registered Member
 
Join Date: Nov 2010
Posts: 25
metallicatony is on a distinguished road
Default

[textView setEditable:NO];

helped. Though the compiler gives a warning that UITextView may not respond to setEditable message, the textView did not switch to editable mode (and the keyboard never showed up) when i tested my code.
metallicatony is offline   Reply With Quote
Reply

Bookmarks

Tags
editable, uitextview

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
12 members and 336 guests
7twenty7, chiataytuday, condor304, Creativ, Domele, dreamdash3, laureix68, LEARN2MAKE, mistergreen2011, mottdog, palme2elie, Paul Slocum
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,660
Threads: 94,119
Posts: 402,896
Top Poster: BrianSlick (7,990)
Welcome to our newest member, laureix68
Powered by vBadvanced CMPS v3.1.0

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