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 05-25-2011, 12:41 AM   #1 (permalink)
Registered Member
 
Join Date: May 2011
Posts: 5
developer.921 is on a distinguished road
Question Highlight the text in UItableView Cell

I searched for a text in my data that user writes in search bar and displayed searched data in UITable View.I want to highlight the matched text in my table view data.For example if i search for a word "Test".I want to highlight this word in my result.Is there any way to do this??
developer.921 is offline   Reply With Quote
Old 05-25-2011, 12:43 AM   #2 (permalink)
Registered Member
 
Join Date: May 2011
Posts: 5
developer.921 is on a distinguished road
Default can't find solution

Urgent Response is needed
developer.921 is offline   Reply With Quote
Old 05-25-2011, 12:47 AM   #3 (permalink)
Registered Member
 
ngaikwad's Avatar
 
Join Date: Feb 2011
Location: Mobile World
Posts: 450
ngaikwad is on a distinguished road
Default

Quote:
Originally Posted by developer.921 View Post
I searched for a text in my data that user writes in search bar and displayed searched data in UITable View.I want to highlight the matched text in my table view data.For example if i search for a word "Test".I want to highlight this word in my result.Is there any way to do this??
Code:
[tableView deselectRowAtIndexPath:indexPath animated:YES];
__________________
Thank & Regard
NI3(Not Impossible 3)
ngaikwad is offline   Reply With Quote
Old 05-25-2011, 01:15 AM   #4 (permalink)
Registered Member
 
Join Date: May 2011
Posts: 5
developer.921 is on a distinguished road
Default

Quote:
Originally Posted by ngaikwad View Post
Code:
[tableView deselectRowAtIndexPath:indexPath animated:YES];
I want to highlight only the word that matches the search text
developer.921 is offline   Reply With Quote
Old 05-25-2011, 01:22 AM   #5 (permalink)
Registered Member
 
ngaikwad's Avatar
 
Join Date: Feb 2011
Location: Mobile World
Posts: 450
ngaikwad is on a distinguished road
Default

Quote:
Originally Posted by developer.921 View Post
I want to highlight only the word that matches the search text
so change that cell text color....
__________________
Thank & Regard
NI3(Not Impossible 3)
ngaikwad is offline   Reply With Quote
Old 05-25-2011, 01:29 AM   #6 (permalink)
Registered Member
 
Join Date: May 2011
Posts: 5
developer.921 is on a distinguished road
Default

you are not getting my point .i do not want to highlight whole text ,i just want to highlight the single word that matches the text that i writes in the search bar.
For Example:
search bar text = "Test"
cell text ="I am doing Test ";

i Just want to highlight the word "Test"
I hope now u will get my point .thanks for quick reply .Any idea about this
developer.921 is offline   Reply With Quote
Old 05-25-2011, 01:36 AM   #7 (permalink)
Registered Member
 
ngaikwad's Avatar
 
Join Date: Feb 2011
Location: Mobile World
Posts: 450
ngaikwad is on a distinguished road
Default

Quote:
Originally Posted by developer.921 View Post
you are not getting my point .i do not want to highlight whole text ,i just want to highlight the single word that matches the text that i writes in the search bar.
For Example:
search bar text = "Test"
cell text ="I am doing Test ";

i Just want to highlight the word "Test"
I hope now u will get my point .thanks for quick reply .Any idea about this
use setfont for only that text
__________________
Thank & Regard
NI3(Not Impossible 3)
ngaikwad is offline   Reply With Quote
Old 05-25-2011, 02:48 AM   #8 (permalink)
Nuisance Developer
 
Join Date: Jul 2009
Location: Italy
Posts: 4,691
dany_dev is on a distinguished road
Default

Quote:
Originally Posted by ngaikwad View Post
use setfont for only that text
lol, is really more hard than that, since that there is no easy way to change the color of just a part of text....

Start from that
https://github.com/Cocoanetics/NSAtt...tions-for-HTML
you will be able to change part of your text with Core Text.
__________________
dany_dev is offline   Reply With Quote
Old 05-25-2011, 03:31 AM   #9 (permalink)
Registered Member
 
Join Date: May 2011
Posts: 5
developer.921 is on a distinguished road
Default

[quote=dany_dev;338358]lol, is really more hard than that, since that there is no easy way to change the color of just a part of text....

thanks dany_dev for response ..but i want to highlight text in the cell for a particuler range
developer.921 is offline   Reply With Quote
Old 05-25-2011, 05:46 AM   #10 (permalink)
Nuisance Developer
 
Join Date: Jul 2009
Location: Italy
Posts: 4,691
dany_dev is on a distinguished road
Default

Quote:
Originally Posted by developer.921 View Post
thanks dany_dev for response ..but i want to highlight text in the cell for a particuler range
yes, and that code allow you to do it....
__________________
dany_dev is offline   Reply With Quote
Reply

Bookmarks

Tags
highlighting, search, text

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: 356
6 members and 350 guests
doffing81, dre, iOS.Lover, jenniead38, Kirkout, Wikiboo
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,663
Threads: 94,120
Posts: 402,898
Top Poster: BrianSlick (7,990)
Welcome to our newest member, LezB44
Powered by vBadvanced CMPS v3.1.0

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