text field in gridview 2.0

Posted on 2006-06-07
Last Modified: 2010-05-18
I have a column whcih is a text field in gridview. I would like to disply only the part of text ( i.e  Priter is not working because...) ,and if the user put a cursor on that text column, the whole message will be displayed.. How can I do this using C# and java script?

Question by:jung1975
    1 Comment
    LVL 20

    Accepted Solution

    here you go, when making the textboxes assign the full value into the tooltip and the truncated value into the text part, the javascript then switches them

    <asp:TextBox ToolTip="Testing Testing" ID="TextBox1" runat="server" Text="Testing" onfocus="this.value = this.title;"> </asp:TextBox>

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    IT, Stop Being Called Into Every Meeting

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Sometimes in DotNetNuke module development you want to swap controls within the same module definition.  In doing this DNN (somewhat annoyingly) swaps the Skin and Container definitions to the default admin selections.  To get around this you need t…
    ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
    Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…
    Internet Business Fax to Email Made Easy - With eFax Corporate (, you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

    760 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    10 Experts available now in Live!

    Get 1:1 Help Now