This is a migrated thread and some comments may be shown as answers.

AllowRowSelect doesn't work..

3 Answers 103 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Jon
Top achievements
Rank 1
Jon asked on 13 Sep 2010, 09:55 PM
Any Ideas.... Why doesn't the AllowRowSelect allow me to click on a row to select it?
thanks again


 

 

<telerik:RadGrid ID="GridManage" runat="server"

 

 

 

AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False"

 

 

 

AllowMultiRowSelection="True"

 

 

 

ShowStatusBar="True" Skin="WebBlue" GridLines="None"

 

 

 

Width="960px" onselectedindexchanged="GridManage_SelectedIndexChanged"

 

 

 

onitemcreated="GridManage_ItemCreated"

 

 

 

onneeddatasource="GridManage_NeedDataSource" PageSize="25" Height="620px"

 

 

 

GroupingEnabled="False" onpagesizechanged="GridManage_PageSizeChanged" ><AlternatingItemStyle BackColor="Silver" /><MasterTableView TableLayout="Fixed" DataKeyNames="ConstituentID" >

 

 

 

 

<RowIndicatorColumn><HeaderStyle Width="20px"></HeaderStyle></RowIndicatorColumn><ExpandCollapseColumn>

 

 

 

 

<HeaderStyle Width="20px"></HeaderStyle></ExpandCollapseColumn><Columns>

 

 

 

 

 

<telerik:GridClientSelectColumn HeaderStyle-Width="25px" DataTextField="CONSTITUENTID" Visible="False" >

 

 

 

 

<HeaderStyle Width="20px" HorizontalAlign="Center"/>

 

 

 

 

 

</telerik:GridClientSelectColumn>

 

 

 

 

 

 

<telerik:GridTemplateColumn UniqueName="CheckBoxTemplateColumn" ><HeaderTemplate>

 

 

 

<asp:CheckBox id="headerChkbox" OnCheckedChanged="ToggleSelectedState" AutoPostBack="True" runat="server">

 

 

 

</asp:CheckBox></HeaderTemplate><ItemTemplate><asp:CheckBox id="CheckBox1"

 

 

 

OnCheckedChanged="ToggleRowSelection" AutoPostBack="True" runat="server"></asp:CheckBox></ItemTemplate><HeaderStyle HorizontalAlign="Center" Width="25px" />

 

 

 

<ItemStyle Width="25px" Wrap="False" /></telerik:GridTemplateColumn><telerik:GridBoundColumn DataField="CONSTITUENTID" Display="False"

 

 

 

HeaderText="Corr ID" UniqueName="column" Visible="False"><HeaderStyle HorizontalAlign="Center" />

 

 

 

<ItemStyle Wrap="False" />

 

 

 

</telerik:GridBoundColumn>

 

 

 

 

<telerik:GridBoundColumn DataField="LastName" HeaderText="Last"

 

 

 

UniqueName="Last" SortExpression="LastName"><HeaderStyle Width="100px" HorizontalAlign="Center"/>

 

 

 

 

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="FirstName" HeaderText="First"

 

 

 

UniqueName="Last" SortExpression="FirstName"><HeaderStyle Width="100px" HorizontalAlign="Center" />

 

 

 

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" />

 

 

 

 

</telerik:GridBoundColumn><telerik:GridBoundColumn DataField="Organization" HeaderText="Org"

 

 

 

UniqueName="Organization" SortExpression="Organization"><HeaderStyle Width="50px" HorizontalAlign="Center" />

 

 

 

 

<ItemStyle Width="200px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="Address1" HeaderText="Address"

 

 

 

UniqueName="Address1" SortExpression="Address1"><HeaderStyle Width="150px" HorizontalAlign="Center" />

 

 

 

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="City" HeaderText="City"

 

 

 

UniqueName="City" SortExpression="City"><HeaderStyle Width="100px" HorizontalAlign="Center" />

 

 

 

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="State" HeaderText="ST"

 

 

 

UniqueName="State" SortExpression="State"><HeaderStyle Width="30px" HorizontalAlign="Center" />

 

 

 

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="Zip" HeaderText="Zip"

 

 

 

UniqueName="Zip" SortExpression="Zip"><HeaderStyle Width="50px" HorizontalAlign="Center" />

 

 

 

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="Email" HeaderText="Email"

 

 

 

UniqueName="Email" SortExpression="Email"><HeaderStyle Width="100px" HorizontalAlign="Center" />

 

 

 

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn></Columns><PagerStyle Mode="NextPrevNumericAndAdvanced"></PagerStyle></MasterTableView>

 

 

 

<SelectedItemStyle BackColor="#CCCCCC" ForeColor="Black" BorderStyle="Outset" />

 

 

 

<HeaderStyle Font-Bold="False" Font-Size="Small" />

 

 

 

 

 

 

<ClientSettings EnableRowHoverStyle="true" AllowColumnsReorder="True">

 

 

 

<Selecting AllowRowSelect="True" />

 

 

 

</ClientSettings>

 

 

 

 

 

</telerik:RadGrid>

 

3 Answers, 1 is accepted

Sort by
0
Pavlina
Telerik team
answered on 14 Sep 2010, 09:09 AM
Hello Jon,

Thanks for the sample code. However, we cannot reproduce the behavior you are describing. I took the sample code you provided and put it in a sample page following a similar scenario you have. I am attaching the page for your reference. Please let me know if you manage to reproduce what you are getting in this project, and what steps to follow, so that we can test it too.

Best wishes,
Pavlina
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Jon
Top achievements
Rank 1
answered on 14 Sep 2010, 01:42 PM

I don't understand why yours works and mine does not. I have mine in a master page and radsplitter. 
Any ideas? thanks again!!!!!!!!!

<%@ Page Title="Manage" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="Manage.aspx.cs" Inherits="TRU2.Pages.Manage" %>

<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %>

<%@ Register src="../Controls/Filters_Constituent.ascx" tagname="Filters" tagprefix="uc1" %>

<%@ Register src="../Controls/TakeAction_on_Constit.ascx" tagname="TakeAction_on_Constit" tagprefix="uc2" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">

<style type="text/css">

.style1

{

width: 100%;

}

 

.styleAction

{

width: 28%;

height: 247px;

}

</style>

 

<script type="text/javascript">

function openWin()

{

var oWnd = radopen("RadWindowDialog");

}

</script>

 

 

 

</asp:Content>

<asp:Content ID="Content4" ContentPlaceHolderID="MainContent" runat="server">

<telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server" height="800px" width="970px">

<telerik:RadWindowManager ID="RadWindowMgr" runat="server"

SkinID="WebBlue" Modal="True"></telerik:RadWindowManager>

 

<telerik:RadToolTipManager EnableShadow="true" HideDelay="1"

ID="RadToolTipManager1" Width="330px" Height="200px"

RelativeTo="Element" Position="BottomCenter"

OnAjaxUpdate="OnAjaxUpdate" runat="server" Skin="Windows7" ManualClose="True"

ShowDelay="0" HideEvent="ManualClose" AnimationDuration="300">

</telerik:RadToolTipManager>

<telerik:RadToolTip ID="RadToolTipAction" runat="server" Skin="WebBlue"

TargetControlID="btnTAKEACTION" Animation="Slide" AnimationDuration="200"

HideEvent="ManualClose">

<telerik:radformdecorator id="FormDecorator1" runat="server" decoratedcontrols="all"

skin="WebBlue">

</telerik:radformdecorator>

 

</telerik:RadToolTip>

<telerik:RadAjaxManager ID="RadAjaxManager" runat="server">

</telerik:RadAjaxManager>

 

<!-- HEADING -->

<table style="table-layout: fixed">

<tr>

<td class="TD_Center" colspan="10">

<asp:Label ID="Label1" runat="server" Font-Bold="True" Font-Names="Verdana"

Font-Size="Large" Text="Manage Constituent Records"></asp:Label>

</td>

</tr>

<tr>

<td colspan="10" class="style16">

<hr style="width: 960px" />

</td>

</tr>

</table>

<telerik:RadSplitter id="RadSplitter1" runat="server" height="640px" width="960">

<telerik:RadPane id="MainPane" runat="server">

 

<telerik:RadGrid ID="GridManage" runat="server"

AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False"

AllowMultiRowSelection="True"

ShowStatusBar="True" Skin="WebBlue" GridLines="None"

Width="960px" onselectedindexchanged="GridManage_SelectedIndexChanged"

onitemcreated="GridManage_ItemCreated"

onneeddatasource="GridManage_NeedDataSource" PageSize="25" Height="620px"

GroupingEnabled="False" onpagesizechanged="GridManage_PageSizeChanged" ><AlternatingItemStyle BackColor="Silver" /><MasterTableView TableLayout="Fixed" DataKeyNames="ConstituentID" >

<RowIndicatorColumn><HeaderStyle Width="20px"></HeaderStyle></RowIndicatorColumn><ExpandCollapseColumn>

<HeaderStyle Width="20px"></HeaderStyle></ExpandCollapseColumn><Columns>

 

<telerik:GridClientSelectColumn HeaderStyle-Width="25px" DataTextField="CONSTITUENTID" Visible="False" >

<HeaderStyle Width="20px" HorizontalAlign="Center"/>

 

</telerik:GridClientSelectColumn>

 

<telerik:GridTemplateColumn UniqueName="CheckBoxTemplateColumn" ><HeaderTemplate>

<asp:CheckBox id="headerChkbox" OnCheckedChanged="ToggleSelectedState" AutoPostBack="True" runat="server">

</asp:CheckBox></HeaderTemplate><ItemTemplate><asp:CheckBox id="CheckBox1"

OnCheckedChanged="ToggleRowSelection" AutoPostBack="True" runat="server"></asp:CheckBox></ItemTemplate><HeaderStyle HorizontalAlign="Center" Width="25px" />

<ItemStyle Width="25px" Wrap="False" /></telerik:GridTemplateColumn><telerik:GridBoundColumn DataField="CONSTITUENTID" Display="False"

HeaderText="Corr ID" UniqueName="column" Visible="False"><HeaderStyle HorizontalAlign="Center" />

<ItemStyle Wrap="False" />

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="LastName" HeaderText="Last"

UniqueName="Last" SortExpression="LastName"><HeaderStyle Width="100px" HorizontalAlign="Center"/>

 

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="FirstName" HeaderText="First"

UniqueName="Last" SortExpression="FirstName"><HeaderStyle Width="100px" HorizontalAlign="Center" />

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" />

</telerik:GridBoundColumn><telerik:GridBoundColumn DataField="Organization" HeaderText="Org"

UniqueName="Organization" SortExpression="Organization"><HeaderStyle Width="50px" HorizontalAlign="Center" />

 

<ItemStyle Width="200px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="Address1" HeaderText="Address"

UniqueName="Address1" SortExpression="Address1"><HeaderStyle Width="150px" HorizontalAlign="Center" />

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="City" HeaderText="City"

UniqueName="City" SortExpression="City"><HeaderStyle Width="100px" HorizontalAlign="Center" />

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="State" HeaderText="ST"

UniqueName="State" SortExpression="State"><HeaderStyle Width="30px" HorizontalAlign="Center" />

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="Zip" HeaderText="Zip"

UniqueName="Zip" SortExpression="Zip"><HeaderStyle Width="50px" HorizontalAlign="Center" />

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn><telerik:GridBoundColumn DataField="Email" HeaderText="Email"

UniqueName="Email" SortExpression="Email"><HeaderStyle Width="100px" HorizontalAlign="Center" />

<ItemStyle Width="125px" HorizontalAlign="Center" Wrap="False" /></telerik:GridBoundColumn></Columns><PagerStyle Mode="NextPrevNumericAndAdvanced"></PagerStyle></MasterTableView>

<SelectedItemStyle BackColor="#CCCCCC" ForeColor="Black" BorderStyle="Outset" />

<HeaderStyle Font-Bold="False" Font-Size="Small" />

 

<ClientSettings EnableRowHoverStyle="true" AllowColumnsReorder="True">

<Selecting AllowRowSelect="True" />

</ClientSettings>

 

</telerik:RadGrid></telerik:RadPane>

<telerik:RadSplitBar id="Radsplitbar2" runat="server"></telerik:RadSplitBar>

<telerik:RadPane id="EndPane" runat="server" width="22" scrolling="none" Font-Size="Larger">

<telerik:RadSlidingZone ID="Radslidingzone1" runat="server"

DockedPaneId="Radslidingpane" slidedirection="Left" width="22"

ClickToOpen="True">

<telerik:RadSlidingPane ID="Radslidingpane1" runat="server"

Font-Bold="True" Font-Size="Larger" ForeColor="#000066" title="Show Filters"

width="300" DockOnOpen="True" UndockText="Close"><uc1:Filters ID="Filters1" runat="server" OndataUpdated="Reload_Data" /></telerik:RadSlidingPane></telerik:RadSlidingZone></telerik:RadPane>

</telerik:RadSplitter>

 

<telerik:RadWindowManager ID="RadWindowManager1" runat="server" EnableShadow="true">

<Windows>

<telerik:RadWindow ID="RadWindowDialog" runat="server" Title="" Height="300px"

Width="300px" Left="150px" ReloadOnShow="true" ShowContentDuringLoad="false" Modal="true" >

<ContentTemplate>

 

<table class="styleAction">

<tr>

<td>

&nbsp;</td>

<td align="center">

<asp:HyperLink ID="hypUpdateSelectedConstituentRecords" runat="server"

Font-Names="Arial">Update Selected Constituent Record(s)</asp:HyperLink>

</td>

<td>

&nbsp;</td>

</tr>

<tr>

<td>

&nbsp;</td>

<td align="center">

<asp:HyperLink ID="hypCreateOutgoing" runat="server" Font-Names="Arial">Create Outgoing Communication to Selected Constituent Record(s)</asp:HyperLink>

</td>

<td>

&nbsp;</td>

</tr>

<tr>

<td>

&nbsp;</td>

<td align="center">

<asp:HyperLink ID="hypPrintEnvelopes" runat="server" Font-Names="Arial">Print Envelope(s) for Selected Records</asp:HyperLink>

</td>

<td>

&nbsp;</td>

</tr>

<tr>

<td>

&nbsp;</td>

<td align="center">

<asp:HyperLink ID="hypDeleteSelected" runat="server" Font-Names="Arial">Delete Selected Records</asp:HyperLink>

</td>

<td>

&nbsp;</td>

</tr>

<tr>

<td>

&nbsp;</td>

<td align="center">

</td>

<td>

&nbsp;</td>

</tr>

</table>

</ContentTemplate>

 

</telerik:RadWindow>

</Windows>

</telerik:RadWindowManager>

<!-- TAKE ACTION -->

<table width="960">

<tr>

<td class="TD_Center">

<asp:Button ID="btnTAKEACTION" runat="server" TabIndex="-1"

Text="Take Action on Selected Records" Width="214px"

/>

</td>

</tr>

</table>

 

</telerik:RadAjaxPanel>

</asp:Content>

0
Pavlina
Telerik team
answered on 14 Sep 2010, 04:52 PM
Hello Jon,

The code looks correct. Therefore, in order to properly assist you, I would suggest that you open a formal support ticket and send us a small working project, incorporating your logic. We will review it locally and advise you further. 

Thank you.

All the best,
Pavlina
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Grid
Asked by
Jon
Top achievements
Rank 1
Answers by
Pavlina
Telerik team
Jon
Top achievements
Rank 1
Share this question
or