Solved

Mouseover a Grid

Posted on 2008-10-21
6
782 Views
Last Modified: 2012-05-05
I have been trying to add a javascript function to display information when there is a moveover a grid, and i want the message to disapear on its own after a (reasonably)short time, say a message that just say "use ctr + shift to select multi rows", but i cant seem to find this info, does anyone know how to do it
0
Comment
Question by:dawie
6 Comments
 
LVL 8

Expert Comment

by:MatthiasVance
ID: 22766470
Can you provide us with some example code of your 'grid'?

Kind regards,

Matthias Vance
0
 
LVL 6

Expert Comment

by:James Looney
ID: 22766476
I would recommend this person's script. We use it on a couple of sites and it works great. The instructions here describe exactly how to install it and the code examples show you how to use it. Let me know if you need help, but the instructions are really good.

http://simplythebest.net/scripts/DHTML_scripts/dhtml_script_120.html
0
 
LVL 5

Expert Comment

by:RobPal
ID: 22766480
Are you using an html table as your grid?  If so then you could probably use

alt="use ctrl + shift to select multi rows"

within your <table> tag.

Let me know if that helps or if i've got the wrong end of the stick.

Rob
0
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 

Author Comment

by:dawie
ID: 22766505
Here is the grid design in HTML; Its a third party control but im sure javascript works on it cause i m using javascript with other functions on the grid like double click.

<td>
                                    <telerik:RadGrid ID="rdgAccounts"  OnItemCommand="rdgAccounts_ItemCommand" runat="server" Skin="Office2007" GridLines="None" Width="100%" AutoGenerateColumns="False" UniqueName="BranchID" OnItemCreated="rdgAccounts_ItemCreated" oncolumndb ShowStatusBar="True" OnItemDataBound="rdgAccounts_ItemDataBound" OnNeedDataSource="rdgAccounts_NeedDataSource1" OnPreRender="rdgAccounts_PreRender1">
                                        <MasterTableView HierarchyLoadMode="Client">
                                            <Columns>
                                                <telerik:GridBoundColumn DataField="ID" HeaderText="ID" visible = "False" UniqueName="ID">
                                                    <HeaderStyle Font-Names="Tahoma" Font-Size="X-Small" Width="50%" />
                                                </telerik:GridBoundColumn>
                                                <telerik:GridBoundColumn DataField="Name" HeaderText="Name" UniqueName="Name">
                                                    <HeaderStyle Font-Names="Tahoma" Font-Size="X-Small" Width="50%" />
                                                </telerik:GridBoundColumn>
                                                 <telerik:GridBoundColumn DataField="Date" UniqueName="Description">
                                                    <HeaderStyle Font-Names="Tahoma" Font-Size="X-Small" />
                                                </telerik:GridBoundColumn>
                                            </Columns>
                                            <EditItemStyle Font-Bold="True" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                            Font-Underline="False" Wrap="True" />
                                            <RowIndicatorColumn>
                                                <HeaderStyle Width="20px" />
                                            </RowIndicatorColumn>
                                            <ExpandCollapseColumn>
                                                <HeaderStyle Width="20px" />
                                            </ExpandCollapseColumn>
                                            <NoRecordsTemplate>
                                        </NoRecordsTemplate>
                                        </MasterTableView>
                                        <ClientSettings AllowExpandCollapse="False" EnableRowHoverStyle="True">
                                         <Scrolling AllowScroll="True" UseStaticHeaders="True" />                                                                                      
                                            <Selecting AllowRowSelect="True" />
                                        </ClientSettings>  
                                        <PagerStyle Mode = "NextPrevAndNumeric"/>  
                                        <SelectedItemStyle BackColor="InactiveBorder" />                                      
                                        <ValidationSettings CommandsToValidate="PerformInsert,Update,ItemCommand" />
                                    </telerik:RadGrid></td>
0
 
LVL 8

Expert Comment

by:MatthiasVance
ID: 22766517
RobPal, I assume you mean using the 'title' attribute of the table-tag, since it doesn't support the alt-attribute. I tested it, and it worked nicely. It would be a good solution if he is using a html table.

Kind regards,

Matthias Vance
0
 
LVL 5

Accepted Solution

by:
RobPal earned 500 total points
ID: 22766700
Yes, Matthias is correct.  If you use the title attribute within your <td> tag that holds your grid code then this should work.

<td title="use ctrl + shift to select multi rows">
                                    <telerik:RadGrid ID="rdgAccounts"  OnItemCommand="rdgAccounts_ItemCommand" runat="server" Skin="Office2007" GridLines="None" Width="100%" AutoGenerateColumns="False" UniqueName="BranchID" OnItemCreated="rdgAccounts_ItemCreated" oncolumndb ShowStatusBar="True" OnItemDataBound="rdgAccounts_ItemDataBound" OnNeedDataSource="rdgAccounts_NeedDataSource1" OnPreRender="rdgAccounts_PreRender1">
                                        <MasterTableView HierarchyLoadMode="Client">
                                            <Columns>
                                                <telerik:GridBoundColumn DataField="ID" HeaderText="ID" visible = "False" UniqueName="ID">
                                                    <HeaderStyle Font-Names="Tahoma" Font-Size="X-Small" Width="50%" />
                                                </telerik:GridBoundColumn>
                                                <telerik:GridBoundColumn DataField="Name" HeaderText="Name" UniqueName="Name">
                                                    <HeaderStyle Font-Names="Tahoma" Font-Size="X-Small" Width="50%" />
                                                </telerik:GridBoundColumn>
                                                 <telerik:GridBoundColumn DataField="Date" UniqueName="Description">
                                                    <HeaderStyle Font-Names="Tahoma" Font-Size="X-Small" />
                                                </telerik:GridBoundColumn>
                                            </Columns>
                                            <EditItemStyle Font-Bold="True" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                            Font-Underline="False" Wrap="True" />
                                            <RowIndicatorColumn>
                                                <HeaderStyle Width="20px" />
                                            </RowIndicatorColumn>
                                            <ExpandCollapseColumn>
                                                <HeaderStyle Width="20px" />
                                            </ExpandCollapseColumn>
                                            <NoRecordsTemplate>
                                        </NoRecordsTemplate>
                                        </MasterTableView>
                                        <ClientSettings AllowExpandCollapse="False" EnableRowHoverStyle="True">
                                         <Scrolling AllowScroll="True" UseStaticHeaders="True" />                                                                                      
                                            <Selecting AllowRowSelect="True" />
                                        </ClientSettings>  
                                        <PagerStyle Mode = "NextPrevAndNumeric"/>  
                                        <SelectedItemStyle BackColor="InactiveBorder" />                                      
                                        <ValidationSettings CommandsToValidate="PerformInsert,Update,ItemCommand" />
                                    </telerik:RadGrid></td>
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today I would like to talk about localizing (Internationalization) JavaScript applications. Introduction When creating an application that is going to be used by many people around the globe, it is important to remember that not everyone speak…
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

828 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