Last post Sep 12, 2007 04:17 PM by James25
Sep 12, 2007 01:28 PM|James25|LINK
Hello! I have a gridview and one of the columns has a text that is very long, and I 'd like to show like only the first sentence and some dots. Is there a way to do this in a gridview? Thanks!!
Sep 12, 2007 01:52 PM|Wookie|LINK
you will have to use the ondatabinding event
in it use findcontrol and do wathever you want on that control
Sep 12, 2007 02:20 PM|limno|LINK
What about this? (replace "+ "with an "&" in VB.NET)
Sep 12, 2007 02:21 PM|Wookie|LINK
Sep 12, 2007 03:29 PM|James25|LINK
I have it like this but it's not working...maybe I am doing it wrong?
Sep 12, 2007 03:32 PM|James25|LINK
I like this method here..But I am using a gridview..Can that be done in a gridview?
Here is my code:
Sep 12, 2007 03:53 PM|limno|LINK
Convert the boundfield to a templatefield as I posted earlier.
Sep 12, 2007 03:56 PM|Wookie|LINK
first you will need to add the parameter to your function
second i think the trim function return the new value so You are required to put that new value in your control
Sep 12, 2007 04:04 PM|James25|LINK
Works great!!!! Thanks a lot!
Sep 12, 2007 04:17 PM|James25|LINK
Thanks for the reply! I gave up on the function..I couldn't get it to work. It works good with the item template.