Bill Delisi
Top achievements
Rank 1
Bill Delisi
asked on 02 Jun 2015, 04:40 AM
Hi,
I am using a gridview with full keyboard navigation control, which I am binding through code behind page load. at the same time I am selecting the first row of that gridview through code behine by the below mentioned code :
if (RadGrid1.MasterTableView.Items.Count > 0)
RadGrid1.MasterTableView.Items[0].Selected = true;
Here I am using the client settings by below mentioned code to allow keyboard navigation for the radgrid.
<ClientSettings AllowKeyboardNavigation="true">
<KeyboardNavigationSettings AllowActiveRowCycle="true">
<Selecting AllowRowSelect="true">
</ClientSettings>
Now if I'm clicking on the radgrid rows then keyboard UP and DOWN arrow key is working fine but in case of Loading the page it is selecting the first row but then the keyboard UP and DOWN arrow key is not working.
How do I use UP and DOWN arrow key in case of page load or refreshed?
I am using a gridview with full keyboard navigation control, which I am binding through code behind page load. at the same time I am selecting the first row of that gridview through code behine by the below mentioned code :
if (RadGrid1.MasterTableView.Items.Count > 0)
RadGrid1.MasterTableView.Items[0].Selected = true;
Here I am using the client settings by below mentioned code to allow keyboard navigation for the radgrid.
<ClientSettings AllowKeyboardNavigation="true">
<KeyboardNavigationSettings AllowActiveRowCycle="true">
<Selecting AllowRowSelect="true">
</ClientSettings>
Now if I'm clicking on the radgrid rows then keyboard UP and DOWN arrow key is working fine but in case of Loading the page it is selecting the first row but then the keyboard UP and DOWN arrow key is not working.
How do I use UP and DOWN arrow key in case of page load or refreshed?
5 Answers, 1 is accepted
0
Hi Bill,
You can achieve this requirement using the following approach:
JavaScript:
Hope this helps. Please give it a try and let me know if it works for you.
Also, could you verify that you are not using DataBind() to bind the grid? Performing complex grid operations such as Inserting, Deleting, Updating, Hierarchy relations, Grouping, Exporting, Paging, Sorting, Filtering, etc. require accommodating appropriate database operations. Therefore, we suggest you to avoid Simple Databinding and strongly recommend the use of more advanced databinding methods, which automatically handle the aforementioned functions:
Declarative DataSource
Programmatic Data Binding
Regards,
Eyup
Telerik
You can achieve this requirement using the following approach:
<
ClientEvents
...
OnGridCreated
=
"gridCreated"
/>
function
gridCreated(sender, args) {
sender.get_element().focus();
}
Hope this helps. Please give it a try and let me know if it works for you.
Also, could you verify that you are not using DataBind() to bind the grid? Performing complex grid operations such as Inserting, Deleting, Updating, Hierarchy relations, Grouping, Exporting, Paging, Sorting, Filtering, etc. require accommodating appropriate database operations. Therefore, we suggest you to avoid Simple Databinding and strongly recommend the use of more advanced databinding methods, which automatically handle the aforementioned functions:
Declarative DataSource
Programmatic Data Binding
Regards,
Eyup
Telerik
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 Feedback Portal
and vote to affect the priority of the items
0
surya
Top achievements
Rank 1
answered on 28 Jan 2016, 06:20 PM
Hi telerik,
I am having the same problem with keyboard navigation.I am using radgrid batch editing when i click tab it is going to the next control instead of next cell.could please review my code.
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="View.ascx.cs" Inherits="Christoc.Modules.MenuMix.View" %>
<%@ Register Assembly="Telerik.Web.UI, Version=2013.2.717.40, Culture=neutral, PublicKeyToken=121fae78165ba3d4" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
<%--<%@ Register TagPrefix="telerik" Namespace="Telerik.QuickStart" %>--%>
<
link
rel
=
"stylesheet"
href
=
"//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css"
>
<
script
src
=
"//code.jquery.com/ui/1.11.4/jquery-ui.js"
></
script
>
<
style
type
=
"text/css"
>
.backcolor {
background: #cccccc;
}
</
style
>
<
asp:Repeater
ID
=
"rptItemList"
runat
=
"server"
OnItemDataBound
=
"rptItemListOnItemDataBound"
OnItemCommand
=
"rptItemListOnItemCommand"
>
<
HeaderTemplate
>
<
ul
class
=
"tm_tl"
>
</
HeaderTemplate
>
<
ItemTemplate
>
<
telerik:RadScriptManager
runat
=
"server"
ID
=
"RadScriptManager1"
/>
<
telerik:RadSkinManager
ID
=
"RadSkinManager1"
runat
=
"server"
ShowChooser
=
"true"
/>
<
li
class
=
"tm_t"
>
<
h3
>
<
asp:Label
ID
=
"lblitemName"
runat
=
"server"
Text='<%#DataBinder.Eval(Container.DataItem,"ItemName").ToString() %>' />
</
h3
>
<
asp:Label
ID
=
"lblItemDescription"
runat
=
"server"
Text='<%#DataBinder.Eval(Container.DataItem,"ItemDescription").ToString() %>' CssClass="tm_td" />
<
asp:Panel
ID
=
"pnlAdmin"
runat
=
"server"
Visible
=
"false"
>
<
asp:HyperLink
ID
=
"lnkEdit"
runat
=
"server"
ResourceKey
=
"EditItem.Text"
Visible
=
"false"
Enabled
=
"false"
/>
<
asp:LinkButton
ID
=
"lnkDelete"
runat
=
"server"
ResourceKey
=
"DeleteItem.Text"
Visible
=
"false"
Enabled
=
"false"
CommandName
=
"Delete"
/>
</
asp:Panel
>
</
li
>
</
ItemTemplate
>
<
FooterTemplate
>
</
ul
>
</
FooterTemplate
>
</
asp:Repeater
>
<%--<
a
href
=
"#"
class
=
"myButton"
>turquoise</
a
>--%>
<
style
type
=
"text/css"
>
.myButton {
-moz-box-shadow: 0px 10px 14px -7px #fff6af;
-webkit-box-shadow: 0px 10px 14px -7px #fff6af;
box-shadow: 0px 10px 14px -7px #fff6af;
background: -webkit-gradient(linear, left top, left bottom, color-stop(0.05, #ffec64), color-stop(1, #ffab23));
background: -moz-linear-gradient(top, #ffec64 5%, #ffab23 100%);
background: -webkit-linear-gradient(top, #ffec64 5%, #ffab23 100%);
background: -o-linear-gradient(top, #ffec64 5%, #ffab23 100%);
background: -ms-linear-gradient(top, #ffec64 5%, #ffab23 100%);
background: linear-gradient(to bottom, #ffec64 5%, #ffab23 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffec64', endColorstr='#ffab23',GradientType=0);
background-color: #ffec64;
-moz-border-radius: 8px;
-webkit-border-radius: 8px;
border-radius: 8px;
display: inline-block;
cursor: pointer;
color: #333333;
font-family: Arial;
font-size: 20px;
font-weight: bold;
padding: 8px 32px;
text-decoration: none;
text-shadow: 0px 1px 0px #ffee66;
}
.myButton:hover {
background: -webkit-gradient(linear, left top, left bottom, color-stop(0.05, #ffab23), color-stop(1, #ffec64));
background: -moz-linear-gradient(top, #ffab23 5%, #ffec64 100%);
background: -webkit-linear-gradient(top, #ffab23 5%, #ffec64 100%);
background: -o-linear-gradient(top, #ffab23 5%, #ffec64 100%);
background: -ms-linear-gradient(top, #ffab23 5%, #ffec64 100%);
background: linear-gradient(to bottom, #ffab23 5%, #ffec64 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffab23', endColorstr='#ffec64',GradientType=0);
background-color: #ffab23;
}
.myButton:active {
position: relative;
top: 1px;
}
}
</
style
>
<
asp:Button
ID
=
"btnHome"
runat
=
"server"
Text
=
"Home"
class
=
"myButton"
CausesValidation
=
"False"
OnClick
=
"btnHome_Click"
/>
<
asp:Button
ID
=
"btnMenuMixConfiguration"
runat
=
"server"
class
=
"myButton"
CausesValidation
=
"False"
Text
=
"MenuMix Configuration"
OnClick
=
"btnMenuMixConfiguration_Click"
/>
<
asp:Button
ID
=
"btnMenuMixEntry"
runat
=
"server"
Text
=
"MenuMix Entry"
class
=
"myButton"
OnClientClick
=
"Gethiddenvalues()"
OnClick
=
"btnMenuMixEntry_Click"
/>
<
asp:HiddenField
ID
=
"hxvalue"
ClientIDMode
=
"Static"
runat
=
"server"
/>
<
br
/>
<
br
/>
<
br
/>
<
asp:Panel
ID
=
"Radscriptpanel"
runat
=
"server"
>
<
telerik:RadAjaxManager
runat
=
"server"
>
<
ajaxsettings
>
<
telerik:AjaxSetting
AjaxControlID
=
"gridMenuMixConfig"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"gridMenuMixConfig"
LoadingPanelID
=
"RadAjaxLoadingPanel1"
/>
<
telerik:AjaxUpdatedControl
ControlID
=
"SavedChangesList"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
<
telerik:AjaxSetting
AjaxControlID
=
"gridMenuMixEntry"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"gridMenuMixEntry"
LoadingPanelID
=
"RadAjaxLoadingPanel1"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
<
telerik:AjaxSetting
AjaxControlID
=
"gridConfirmation"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"gridConfirmation"
LoadingPanelID
=
"RadAjaxLoadingPanel1"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
<
telerik:AjaxSetting
AjaxControlID
=
"txtRegisterCustCount"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"txtRegisterCustCount"
LoadingPanelID
=
"RadAjaxLoadingPanel1"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
<
telerik:AjaxSetting
AjaxControlID
=
"txtRegisterSalesTax"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"txtRegisterSalesTax"
LoadingPanelID
=
"RadAjaxLoadingPanel1"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
</
ajaxsettings
>
</
telerik:RadAjaxManager
>
<
telerik:RadAjaxLoadingPanel
runat
=
"server"
ID
=
"RadAjaxLoadingPanel1"
skin
=
"Office2010Silver"
></
telerik:RadAjaxLoadingPanel
>
<
telerik:RadFormDecorator
ID
=
"RadFormDecorator1"
runat
=
"server"
DecorationZoneID
=
"demo1"
DecoratedControls
=
"All"
EnableRoundedCorners
=
"false"
/>
<
telerik:RadFormDecorator
ID
=
"RadFormDecorator2"
runat
=
"server"
DecorationZoneID
=
"demo2"
DecoratedControls
=
"All"
EnableRoundedCorners
=
"false"
/>
</
asp:Panel
>
<
asp:Panel
ID
=
"PHMenuMixConfiguration"
runat
=
"server"
>
<
h2
>Menu Mix Configuration:</
h2
>
<
br
/>
<
div
>
<
table
>
<
tr
>
<
td
>
<
h4
>Select Store : </
h4
>
</
td
>
<
td
>
<
asp:DropDownList
ID
=
"ddlStores"
runat
=
"server"
OnSelectedIndexChanged
=
"ddlStores_SelectedIndexChanged"
AutoPostBack
=
"true"
>
</
asp:DropDownList
></
td
>
</
tr
>
<
tr
>
<
td
>
<
h5
>Registers at Store : </
h5
>
</
td
>
<
td
>
<
div
class
=
"demo-container size-thin"
>
<
telerik:RadListBox
runat
=
"server"
ID
=
"lstStoreRegisters"
Skin
=
"Sunset"
SelectionMode
=
"Multiple"
Height
=
"200"
Width
=
"200"
OnClientSelectedIndexChanged
=
"lstselectindexchanged"
OnItemDataBound
=
"lstStoreRegisters_ItemDataBound"
>
</
telerik:RadListBox
>
<
asp:RequiredFieldValidator
ID
=
"RequiredFieldValidator2"
runat
=
"server"
ErrorMessage
=
"Select a register first."
Display
=
"Dynamic"
ControlToValidate
=
"lstStoreRegisters"
ValidationGroup
=
"DisableRequiresSelection"
CssClass
=
"validator"
/>
<
asp:RequiredFieldValidator
ID
=
"RequiredFieldValidator3"
runat
=
"server"
ErrorMessage
=
"Select a register first."
Display
=
"Dynamic"
ControlToValidate
=
"lstStoreRegisters"
ValidationGroup
=
"DeleteRequiresSelection"
CssClass
=
"validator"
/>
<
asp:RequiredFieldValidator
ID
=
"RequiredFieldValidator5"
runat
=
"server"
ErrorMessage
=
"Select a register first."
Display
=
"Dynamic"
ControlToValidate
=
"lstStoreRegisters"
ValidationGroup
=
"EnableRequiresSelection"
CssClass
=
"validator"
/>
<
asp:RequiredFieldValidator
ID
=
"RequiredFieldValidator6"
runat
=
"server"
ErrorMessage
=
"Select a register first."
Display
=
"Dynamic"
ControlToValidate
=
"lstStoreRegisters"
ValidationGroup
=
"RenameRequiresSelection"
CssClass
=
"validator"
/>
</
div
>
</
td
>
<
td
>
<
table
>
<
tr
>
<
td
>
<
telerik:RadTextBox
runat
=
"server"
ID
=
"txtaddregister"
Width
=
"150px"
MaxLength
=
"50"
></
telerik:RadTextBox
>
<%-- <
asp:TextBox
runat
=
"Server"
ID
=
"itemTextBox"
EmptyMessage
=
"Enter item text"
Size
=
"Wide"
/>--%>
</
td
>
<
td
>
<
telerik:RadButton
ID
=
"AddButton"
skin
=
"Sunset"
runat
=
"server"
OnClick
=
"AddButton_Click"
ValidationGroup
=
"TextRequired"
Text
=
"Add Register"
Size
=
"Narrow"
/>
</
telerik:RadButton
>
<
asp:RequiredFieldValidator
ID
=
"RequiredFieldValidator1"
runat
=
"server"
ErrorMessage
=
"Text is required"
Display
=
"Dynamic"
ControlToValidate
=
"txtaddregister"
ValidationGroup
=
"TextRequired"
CssClass
=
"validator"
/>
</
td
>
</
tr
>
<
tr
>
<
td
>
<
telerik:RadTextBox
runat
=
"server"
ID
=
"txtRename"
Width
=
"150px"
MaxLength
=
"50"
></
telerik:RadTextBox
>
<%-- <
asp:TextBox
runat
=
"Server"
ID
=
"txtRename"
EmptyMessage
=
"Enter item text"
Size
=
"Wide"
/>--%>
</
td
>
<
td
>
<
telerik:RadButton
ID
=
"RenameButton"
skin
=
"Sunset"
runat
=
"server"
CausesValidation
=
"False"
ValidationGroup
=
"NewnameRequired"
onclientclicked
=
"isregisterselected"
OnClick
=
"Rename_Button"
Text
=
"Rename Register"
/>
</
telerik:RadButton
>
<
asp:RequiredFieldValidator
ID
=
"RequiredFieldValidator4"
runat
=
"server"
ErrorMessage
=
"Text is required"
Display
=
"Dynamic"
ControlToValidate
=
"txtRename"
ValidationGroup
=
"NewnameRequired"
CssClass
=
"validator"
/>
</
td
>
</
tr
>
<
tr
>
<
td
>
<
telerik:RadButton
ID
=
"DisableButton"
skin
=
"Sunset"
runat
=
"server"
OnClick
=
"DisableButton_Click"
ValidationGroup
=
"DisableRequiresSelection"
Text
=
"Disable selected Register(s)"
/>
</
telerik:RadButton
></
td
>
</
tr
>
<
tr
>
<
td
>
<
telerik:RadButton
ID
=
"DeleteButton"
skin
=
"Sunset"
runat
=
"server"
OnClick
=
"DeleteButton_Click"
ValidationGroup
=
"DeleteRequiresSelection"
OnClientClicking
=
"confirmregisterdelete"
Text
=
"Delete selected Register(s)"
/>
</
telerik:RadButton
></
td
>
</
tr
>
<
tr
>
<
td
>
<
telerik:RadButton
ID
=
"EnableAllButton"
skin
=
"Sunset"
runat
=
"server"
ValidationGroup
=
"EnableRequiresSelection"
OnClick
=
"EnableAll_Button"
Text
=
"Enable selected Register(s)"
/>
</
telerik:RadButton
></
td
>
</
tr
>
</
table
>
</
td
>
</
tr
>
</
table
>
<
table
>
<
tr
>
<
td
>
<
div
id
=
"demo1"
class
=
"demo-container no-bg"
>
<
telerik:RadListBox
runat
=
"server"
ID
=
"SavedChangesList"
Width
=
"600px"
Height
=
"200px"
Visible
=
"false"
></
telerik:RadListBox
>
<
telerik:RadGrid
ID
=
"gridMenuMixConfig"
GridLines
=
"None"
runat
=
"server"
AllowAutomaticDeletes
=
"True"
OnItemCreated
=
"gridMenuMixConfig_ItemCreated"
skin
=
"Office2010Silver"
Allowsorting
=
"True"
AllowAutomaticInserts
=
"True"
Width
=
"1000px"
OnItemUpdated
=
"gridMenuMixConfig_ItemUpdated"
OnPreRender
=
"gridMenuMixConfig_PreRender"
AllowAutomaticUpdates
=
"True"
AutoGenerateColumns
=
"False"
OnBatchEditCommand
=
"gridMenuMixConfig_BatchEditCommand"
DataSourceID
=
"SqlDataSource1"
>
<
mastertableview
commanditemdisplay
=
"Bottom"
datakeynames
=
"PKey"
horizontalalign
=
"NotSet"
editmode
=
"Batch"
autogeneratecolumns
=
"False"
>
<
BatchEditingSettings
EditType
=
"Cell"
/>
<
CommandItemSettings
ShowAddNewRecordButton
=
"false"
ShowCancelChangesButton
=
"False"
ShowRefreshButton
=
"False"
ShowSavechangesButton
=
"false"
/>
<
Columns
>
<
telerik:GridBoundColumn
DataField
=
"CrunchTimePLU"
ReadOnly
=
"True"
HeaderStyle-Width
=
"210px"
HeaderText
=
"CrunchTimePLU"
SortExpression
=
"CrunchTimePLU"
UniqueName
=
"CrunchTimePLU"
>
</
telerik:GridBoundColumn
>
<
telerik:GridBoundColumn
DataField
=
"Descr"
ReadOnly
=
"True"
HeaderStyle-Width
=
"210px"
HeaderText
=
"Description"
SortExpression
=
"Descr"
UniqueName
=
"Descr"
>
</
telerik:GridBoundColumn
>
<
telerik:GridBoundColumn
DataField
=
"GLAccount"
ReadOnly
=
"True"
HeaderStyle-Width
=
"100px"
HeaderText
=
"GL Account"
SortExpression
=
"GLAccount"
UniqueName
=
"GLAccount"
>
</
telerik:GridBoundColumn
>
<
telerik:GridTemplateColumn
DataField
=
"StorePLU"
SortExpression
=
"StorePLU"
HeaderText
=
"Store PLU"
UniqueName
=
"StorePLU"
>
<
EditItemTemplate
>
<
asp:TextBox
ID
=
"txtStorePLU"
runat
=
"server"
MaxLength
=
"10"
Text='<%# Bind("StorePLU") %>' ></
asp:TextBox
>
<%-- <
asp:RegularExpressionValidator
ID
=
"RegularExpressionValidator1"
runat
=
"server"
ErrorMessage
=
"Must be a number"
ToolTip
=
"Numbers Only"
ValidationExpression
=
"\d+"
ControlToValidate
=
"RunsTextBox"
CssClass
=
"validator"
></
asp:RegularExpressionValidator
>--%>
</
EditItemTemplate
>
<
ItemTemplate
>
<
asp:Label
ID
=
"StorePLULabel2"
runat
=
"server"
Text='<%# Eval("StorePLU") %>'></
asp:Label
>
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
<
telerik:GridTemplateColumn
UniqueName
=
"Display"
HeaderText
=
"Display?"
Datafield
=
"Display"
SortExpression
=
"Display"
>
<
ItemTemplate
>
<%# Eval("Display")%>
</
ItemTemplate
>
<
EditItemTemplate
>
<
asp:RadioButtonList
runat
=
"server"
ID
=
"RadioButtonList1"
RepeatDirection
=
"Horizontal"
>
<
asp:ListItem
Text
=
"Yes"
Value
=
"Y"
></
asp:ListItem
>
<
asp:ListItem
Text
=
"No"
Value
=
"N"
></
asp:ListItem
>
</
asp:RadioButtonList
>
</
EditItemTemplate
>
<%-- <
ItemStyle
CssClass
=
"backcolor"
/>--%>
</
telerik:GridTemplateColumn
>
</
Columns
>
</
mastertableview
>
<
clientsettings
allowkeyboardnavigation
=
"true"
>
<
ClientEvents
OnBatchEditSetEditorValue
=
"setEditorValue"
OnBatchEditGetEditorValue
=
"getEditorvalue"
/>
<%--<
Resizing
AllowColumnResize
=
"true"
ResizeGridOnColumnResize
=
"False"
AllowResizeToFit
=
"true"
/>--%>
<
Scrolling
AllowScroll
=
"true"
UseStaticHeaders
=
"true"
></
Scrolling
>
<
Resizing
AllowColumnResize
=
"true"
EnableRealTimeResize
=
"true"
/>
<
KeyboardNavigationSettings
EnableKeyboardShortcuts
=
"true"
></
KeyboardNavigationSettings
>
<%-- <
Scrolling
AllowScroll
=
"True"
UseStaticHeaders
=
"True"
SaveScrollPosition
=
"true"
FrozenColumnsCount
=
"2"
></
Scrolling
>--%>
</
clientsettings
>
</
telerik:RadGrid
>
<
br
/>
<
div
style
=
"float: right;"
>
<
telerik:RadButton
AutoPostBack
=
"false"
Text
=
"SaveChanges"
skin
=
"Sunset"
ID
=
"SaveChangesButton"
runat
=
"server"
OnClientClicked
=
"SaveChangesInGrid"
></
telerik:RadButton
>
</
div
>
<
asp:SqlDataSource
ID
=
"SqlDataSource1"
runat
=
"server"
ConnectionString="<%$ ConnectionStrings:SiteSqlServerdev %>"
SelectCommand="DINERO_GetCTStorePLUMapping" SelectCommandType="StoredProcedure"
UpdateCommand="DINERO_UpdateCTStorePLUMapping" UpdateCommandType="StoredProcedure"
OnUpdating="OnSqlUpdatedMenuMixConfig"
OnSelecting="SqlDataSourceGridView_Selecting">
<
SelectParameters
>
<
asp:SessionParameter
Name
=
"FranStoreNumber"
Type
=
"Int64"
SessionField
=
"FranStoreNumber"
/>
</
SelectParameters
>
<
UpdateParameters
>
<
asp:SessionParameter
Name
=
"StorePLU"
Type
=
"string"
SessionField
=
"StorePLU"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"Display"
Type
=
"string"
SessionField
=
"Display"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"PKey"
Type
=
"int32"
SessionField
=
"PKey"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"FranStoreNumber"
Type
=
"Int32"
SessionField
=
"FranStoreNumber"
/>
</
UpdateParameters
>
</
asp:SqlDataSource
>
</
div
>
</
td
>
</
tr
>
</
table
>
<
table
>
<
tr
>
<
td
>
<
telerik:RadWindowManager
ID
=
"RadWindowManager1"
runat
=
"server"
EnableShadow
=
"true"
EnableViewState
=
"false"
>
</
telerik:RadWindowManager
>
</
td
>
</
tr
>
</
table
>
</
div
>
</
asp:Panel
>
<
asp:Panel
ID
=
"PHMenuMiXEntry"
runat
=
"server"
>
<
h2
>Menu Mix Entry:</
h2
>
<
br
/>
<
table
>
<
tr
>
<
td
>
<
h3
>Select Store</
h3
>
</
td
>
<
td
>:</
td
>
<
td
>
<
asp:DropDownList
ID
=
"ddlStoreEntry"
runat
=
"server"
AutoPostBack
=
"true"
OnSelectedIndexChanged
=
"ddlStoreEntry_SelectedIndexChanged"
>
<
asp:ListItem
Text
=
"Select Store"
Value
=
""
></
asp:ListItem
>
</
asp:DropDownList
></
td
>
<
td
></
td
>
<
td
>
<
h3
>Sales Date</
h3
>
</
td
>
<
td
>:</
td
>
<
td
>
<
asp:TextBox
ID
=
"txtSalesDate"
runat
=
"server"
OnTextChanged
=
"txtPickupDate_TextChanged"
AutoPostBack
=
"true"
></
asp:TextBox
>
</
td
>
</
tr
>
<
tr
>
<
td
>
<
h3
>Register</
h3
>
</
td
>
<
td
>:</
td
>
<
td
>
<
asp:DropDownList
ID
=
"ddlRegisters"
runat
=
"server"
AutoPostBack
=
"True"
Enabled
=
"false"
OnSelectedIndexChanged
=
"ddlRegisters_SelectedIndexChanged"
>
<
asp:ListItem
Text
=
"Select Register"
Value
=
""
></
asp:ListItem
>
</
asp:DropDownList
></
td
>
</
tr
>
<
tr
>
<
td
>
<
h4
>Register Customer Count</
h4
>
</
td
>
<
td
>:</
td
>
<
td
>
<
telerik:RadNumericTextBox
runat
=
"server"
AutoPostBack
=
"true"
ID
=
"txtRegisterCustCount"
Width
=
"200px"
Height
=
"30px"
Value
=
"1"
EmptyMessage
=
"Enter Customer count"
MinValue
=
"0"
MaxValue
=
"1000"
NumberFormat-DecimalDigits
=
"0"
OnTextChanged
=
"txtRegisterCustCount_TextChanged"
>
<
numberformat
groupseparator
=
""
decimaldigits
=
"0"
allowrounding
=
"true"
keepnotroundedvalue
=
"false"
/>
<
clientevents
onkeypress
=
"NewKeyPress"
/>
</
telerik:RadNumericTextBox
>
</
td
>
<
td
>
<
asp:RequiredFieldValidator
ID
=
"txtRegisterCustCountRequiredFieldValidator"
ControlToValidate
=
"txtRegisterCustCount"
runat
=
"server"
ErrorMessage
=
"RequiredFieldValidator"
ForeColor
=
"Red"
Text
=
"*"
Display
=
"Dynamic"
></
asp:RequiredFieldValidator
>
</
td
>
</
tr
>
<
tr
>
<
td
>
<
br
/>
</
td
>
</
tr
>
<
tr
>
<
td
>
<
h4
>Register Total Sales Tax</
h4
>
</
td
>
<
td
>:</
td
>
<
td
>
<%--<
asp:TextBox
ID
=
"txtRegisterSalesTax"
runat
=
"server"
AutoPostBack
=
"true"
OnTextChanged
=
"txtRegisterCustCount_TextChanged"
></
asp:TextBox
>--%>
<%-- <
telerik:RadMaskedTextBox
runat
=
"server"
Mask
=
"###.###"
Width
=
"222px"
ID
=
"txtRegisterSalesTax"
>
</
telerik:RadMaskedTextBox
>--%>
<
telerik:RadNumericTextBox
MinValue
=
"0"
ID
=
"txtRegisterSalesTax"
Width
=
"200px"
AutoPostBack
=
"true"
Height
=
"30px"
EmptyMessage
=
"Enter Sales Tax"
OnTextChanged
=
"txtRegisterCustCount_TextChanged"
runat
=
"server"
>
<
numberformat
groupseparator
=
"."
decimaldigits
=
"2"
/>
<
clientevents
onkeypress
=
"SalesTaxNewKeyPress"
/>
</
telerik:RadNumericTextBox
>
</
td
>
<
td
>
<
asp:RequiredFieldValidator
ID
=
"txtRegisterSalesTaxRequiredFieldValidator"
CssClass
=
"Validators"
ControlToValidate
=
"txtRegisterSalesTax"
runat
=
"server"
ErrorMessage
=
"RequiredFieldValidator"
ForeColor
=
"Red"
Text
=
"*"
Display
=
"Dynamic"
></
asp:RequiredFieldValidator
>
</
td
>
</
tr
>
</
table
>
<
br
/>
<
table
>
<
tr
>
<
td
>
<
div
id
=
"demo2"
class
=
"demo-container no-bg"
>
<
telerik:RadGrid
ID
=
"gridMenuMixEntry"
GridLines
=
"None"
runat
=
"server"
AllowAutomaticDeletes
=
"True"
skin
=
"Office2010Silver"
AllowSorting
=
"true"
AllowAutomaticInserts
=
"True"
PageSize
=
"10"
OnItemUpdated
=
"gridMenuMixEntry_ItemUpdated"
OnPreRender
=
"gridMenuMixEntry_PreRender"
AllowAutomaticUpdates
=
"True"
AutoGenerateColumns
=
"False"
OnItemDataBound
=
"gridMenuMixEntry_ItemDataBound"
OnBatchEditCommand
=
"gridMenuMixEntry_BatchEditCommand"
DataSourceID
=
"SqlDataSource2"
>
<
mastertableview
commanditemdisplay
=
"Bottom"
datakeynames
=
"FullKey,OKey,AKey2,FullName"
datasourceid
=
"SqlDataSource2"
horizontalalign
=
"NotSet"
editmode
=
"Batch"
autogeneratecolumns
=
"False"
showfooter
=
"true"
>
<
HeaderStyle
HorizontalAlign
=
"Right"
></
HeaderStyle
>
<
FooterStyle
BackColor
=
"white"
HorizontalAlign
=
"Right"
></
FooterStyle
>
<
BatchEditingSettings
EditType
=
"Cell"
/>
<
CommandItemSettings
ShowAddNewRecordButton
=
"false"
ShowRefreshButton
=
"False"
ShowSaveChangesButton
=
"false"
ShowCancelChangesButton
=
"False"
/>
<
Columns
>
<
telerik:GridBoundColumn
DataField
=
"StorePLU"
readonly
=
"True"
HeaderStyle-Width
=
"100px"
HeaderText
=
"Store PLU"
SortExpression
=
"StorePLU"
UniqueName
=
"StorePLU"
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
</
telerik:GridBoundColumn
>
<
telerik:GridBoundColumn
DataField
=
"Descr"
readonly
=
"True"
HeaderStyle-Width
=
"150px"
HeaderText
=
"Description"
SortExpression
=
"Descr"
UniqueName
=
"Descr"
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
</
telerik:GridBoundColumn
>
<
telerik:GridTemplateColumn
DataField
=
"TotalQty"
SortExpression
=
"TotalQty"
HeaderText
=
"Total Qty"
UniqueName
=
"TotalQty"
>
<
EditItemTemplate
>
<
telerik:RadNumericTextBox
ID
=
"TextBox1"
runat
=
"server"
MaxLength
=
"10"
Text='<%# Bind("TotalQty") %>' >
<
clientevents
onkeypress
=
"NewKeyPress"
/>
</
telerik:RadNumericTextBox
>
<%-- <
asp:RegularExpressionValidator
ID
=
"RegularExpressionValidator1"
runat
=
"server"
ErrorMessage
=
"Must be a number"
ToolTip
=
"Numbers Only"
ValidationExpression
=
"\d+"
ControlToValidate
=
"RunsTextBox"
CssClass
=
"validator"
></
asp:RegularExpressionValidator
>--%>
</
EditItemTemplate
>
<
ItemTemplate
>
<
asp:Label
ID
=
"Label5"
runat
=
"server"
Text='<%# Eval("TotalQty") %>'></
asp:Label
>
</
ItemTemplate
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
</
telerik:GridTemplateColumn
>
<
telerik:GridTemplateColumn
DataField
=
"TotalSales"
SortExpression
=
"TotalSales"
HeaderText
=
"Total Sales"
UniqueName
=
"TotalSales"
>
<
EditItemTemplate
>
<
telerik:RadNumericTextBox
ID
=
"RadNumericTextBox1"
MaxLength
=
"10"
Width
=
"150px"
Type
=
"Currency"
runat
=
"server"
Text='<%# Bind("TotalSales") %>'>
<
numberformat
groupseparator
=
""
decimaldigits
=
"2"
/>
<%-- <
clientevents
onkeypress
=
"SalesTaxNewKeyPress"
/>--%>
</
telerik:RadNumericTextBox
>
<%-- <
asp:RegularExpressionValidator
ID
=
"RegularExpressionValidator1"
runat
=
"server"
ErrorMessage
=
"Must be a number"
ToolTip
=
"Numbers Only"
ValidationExpression
=
"\d+"
ControlToValidate
=
"RunsTextBox"
CssClass
=
"validator"
></
asp:RegularExpressionValidator
>--%>
</
EditItemTemplate
>
<
ItemTemplate
>
<
asp:Label
ID
=
"Label6"
runat
=
"server"
Text=<%# DataBinder.Eval(Container.DataItem, "TotalSales", "{0:$##,##0.00#}")%>></
asp:Label
>
</
ItemTemplate
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
</
telerik:GridTemplateColumn
>
<
telerik:GridTemplateColumn
DataField
=
"OverringQty"
SortExpression
=
"OverringQty"
HeaderText
=
"Overring Qty"
UniqueName
=
"OverringQty"
>
<
EditItemTemplate
>
<
telerik:RadNumericTextBox
ID
=
"RadNumericTextBox2"
runat
=
"server"
MaxLength
=
"10"
Text='<%# Bind("TotalQty") %>' >
<
clientevents
onkeypress
=
"NewKeyPress"
/>
</
telerik:RadNumericTextBox
>
<%-- <
asp:RegularExpressionValidator
ID
=
"RegularExpressionValidator1"
runat
=
"server"
ErrorMessage
=
"Must be a number"
ToolTip
=
"Numbers Only"
ValidationExpression
=
"\d+"
ControlToValidate
=
"RunsTextBox"
CssClass
=
"validator"
></
asp:RegularExpressionValidator
>--%>
</
EditItemTemplate
>
<
ItemTemplate
>
<
asp:Label
ID
=
"Label7"
runat
=
"server"
Text='<%# Eval("OverringQty") %>'></
asp:Label
>
</
ItemTemplate
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
</
telerik:GridTemplateColumn
>
<
telerik:GridTemplateColumn
DataField
=
"OverringSales"
SortExpression
=
"OverringSales"
HeaderText
=
"Over ring Sales"
UniqueName
=
"OverringSales"
>
<
EditItemTemplate
>
<
telerik:RadNumericTextBox
ID
=
"RadNumericTextBox3"
Width
=
"150px"
MaxLength
=
"10"
Type
=
"Currency"
runat
=
"server"
Text='<%# Bind("TotalSales") %>'>
<
numberformat
groupseparator
=
""
decimaldigits
=
"2"
/>
<%-- <
clientevents
onkeypress
=
"SalesTaxNewKeyPress"
/>--%>
</
telerik:RadNumericTextBox
>
<%-- <
asp:RegularExpressionValidator
ID
=
"RegularExpressionValidator1"
runat
=
"server"
ErrorMessage
=
"Must be a number"
ToolTip
=
"Numbers Only"
ValidationExpression
=
"\d+"
ControlToValidate
=
"RunsTextBox"
CssClass
=
"validator"
></
asp:RegularExpressionValidator
>--%>
</
EditItemTemplate
>
<
ItemTemplate
>
<
asp:Label
ID
=
"Label8"
runat
=
"server"
Text=<%# DataBinder.Eval(Container.DataItem, "OverringSales", "{0:$##,##0.00#}")%>></
asp:Label
>
</
ItemTemplate
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
</
telerik:GridTemplateColumn
>
<
telerik:GridCalculatedColumn
HeaderText
=
"Net Qty"
UniqueName
=
"NetQty"
HeaderStyle-Width
=
"80px"
DataType
=
"System.int"
DataFields
=
"TotalQty, OverringQty"
Expression
=
"{0}-{1}"
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
<%-- <
HeaderStyle
HorizontalAlign
=
"Center"
/>--%>
</
telerik:GridCalculatedColumn
>
<
telerik:GridCalculatedColumn
HeaderText
=
"Net Sales"
UniqueName
=
"NetSales"
HeaderStyle-Width
=
"80px"
DataType
=
"System.Decimal"
DataFields
=
"TotalSales, OverringSales"
Expression
=
"{0}-{1}"
DataFormatString
=
"{0:C}"
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
<%-- <
HeaderStyle
HorizontalAlign
=
"Center"
/>--%>
</
telerik:GridCalculatedColumn
>
</
Columns
>
</
mastertableview
>
<
clientsettings
allowkeyboardnavigation
=
"true"
>
<
ClientEvents
OnBatchEditCellValueChanged
=
"BatchEditCellValueChanged"
/>
<
KeyboardNavigationSettings
EnableKeyboardShortcuts
=
"true"
/>
<
Resizing
AllowColumnResize
=
"True"
AllowRowResize
=
"false"
ResizeGridOnColumnResize
=
"False"
ClipCellContentOnResize
=
"true"
EnableRealTimeResize
=
"false"
AllowResizeToFit
=
"true"
/>
<
Scrolling
AllowScroll
=
"True"
UseStaticHeaders
=
"True"
SaveScrollPosition
=
"true"
></
Scrolling
>
</
clientsettings
>
</
telerik:RadGrid
>
</
div
>
</
tr
>
</
table
>
<
br
/>
<
asp:SqlDataSource
ID
=
"SqlDataSource2"
runat
=
"server"
ConnectionString="<%$ ConnectionStrings:SiteSqlServerdev %>"
SelectCommand="DINERO_GetStoreRegistersForSales" SelectCommandType="StoredProcedure"
UpdateCommand="DINERO_UpdateStoreRegisterSales" UpdateCommandType="StoredProcedure"
OnSelecting="SqlDataSourceGridViewMenuMixEntry_Selecting"
OnUpdating="OnSqlUpdated">
<
SelectParameters
>
<
asp:SessionParameter
Name
=
"FranStoreNumber"
Type
=
"Int64"
SessionField
=
"FranStoreNumber"
/>
<
asp:SessionParameter
Name
=
"RegisterNumber"
Type
=
"string"
SessionField
=
"RegisterNumber"
/>
<
asp:SessionParameter
Name
=
"SalesDate"
Type
=
"String"
SessionField
=
"SalesDate"
/>
</
SelectParameters
>
<
UpdateParameters
>
<
asp:SessionParameter
Name
=
"FullKey"
Type
=
"string"
SessionField
=
"FullKey"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"AKey2"
Type
=
"int64"
SessionField
=
"AKey2"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"OKey"
Type
=
"int64"
SessionField
=
"OKey"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"FullName"
Type
=
"string"
SessionField
=
"FullName"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"TotalQty"
Type
=
"int64"
SessionField
=
"TotalQty"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"TotalSales"
Type
=
"Decimal"
SessionField
=
"TotalSales"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"OverringQty"
Type
=
"int64"
SessionField
=
"OverringQty"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"OverringSales"
Type
=
"Decimal"
SessionField
=
"OverringSales"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"SalesDate"
Type
=
"string"
SessionField
=
"SalesDate"
></
asp:SessionParameter
>
</
UpdateParameters
>
</
asp:SqlDataSource
>
<
div
style
=
"float: right;"
>
<
telerik:RadButton
AutoPostBack
=
"true"
Visible
=
"false"
Text
=
"View Confirmation"
skin
=
"Sunset"
ID
=
"btnViewConfirmation"
runat
=
"server"
Onclick
=
"btnViewConfirmation_Click"
></
telerik:RadButton
>
<
telerik:RadButton
AutoPostBack
=
"true"
Text
=
"I'm Done"
skin
=
"Sunset"
ID
=
"btnImDoneMenuMixEntry"
runat
=
"server"
Onclick
=
"btnSaveMenumixEntry_Click"
></
telerik:RadButton
>
</
div
>
</
asp:Panel
>
<
asp:Panel
ID
=
"PanelMenuMixConfirmation"
runat
=
"server"
>
<
h2
>Menu Mix Confirmation: </
h2
>
<
br
/>
<
div
>
<
table
>
<
tr
>
<
td
>
<
asp:Label
ID
=
"Label2"
Text
=
"Store:"
Font-Bold
=
"true"
runat
=
"server"
Font-Size
=
"Medium"
></
asp:Label
>
</
td
>
<
td
>
<
asp:Label
ID
=
"lblStore"
runat
=
"server"
></
asp:Label
>
</
td
>
<
td
>
<
asp:Label
ID
=
"Label1"
Text
=
"Sales Date:"
Font-Bold
=
"true"
runat
=
"server"
Font-Size
=
"Medium"
></
asp:Label
>
</
td
>
<
td
></
td
>
<
td
>
<
asp:Label
ID
=
"lblSalesDate"
runat
=
"server"
></
asp:Label
>
</
td
>
</
tr
>
</
table
>
<
br
/>
<
table
>
<
tr
>
<
td
>
<%-- <
h6
>Register Customer Count:</
h6
>--%>
<
asp:Label
ID
=
"Label3"
Text
=
"Register Customer Count:"
Font-Bold
=
"true"
runat
=
"server"
Font-Size
=
"Medium"
></
asp:Label
>
</
td
>
<
td
colspan
=
"2"
>
<
asp:Label
ID
=
"lblRegisterCustomerCount"
runat
=
"server"
></
asp:Label
>
</
td
>
</
tr
>
<
tr
>
<
td
>
<%--<
h6
>Register Total Sales Tax:</
h6
>--%>
<
asp:Label
ID
=
"Label4"
Text
=
"Register Total Sales Tax:"
Font-Bold
=
"true"
runat
=
"server"
Font-Size
=
"Medium"
></
asp:Label
>
</
td
>
<
td
>
<
asp:Label
ID
=
"lblRegisterTotalSalesTax"
runat
=
"server"
></
asp:Label
>
</
td
>
</
tr
>
</
table
>
</
div
>
<
table
>
<
tr
>
<
td
>
<
asp:Label
ID
=
"lbltotal"
runat
=
"server"
Text
=
"Total:"
></
asp:Label
>
</
td
>
<
td
>
<
asp:Label
ID
=
"lblNetQty"
runat
=
"server"
Text
=
"Total:"
></
asp:Label
></
td
>
<
td
>
<
asp:Label
ID
=
"lblNetSales"
runat
=
"server"
Text
=
"Label"
></
asp:Label
></
td
>
</
tr
>
</
table
>
<
telerik:RadGrid
ID
=
"gridConfirmation"
OnPreRender
=
"gridConfirmation_PreRender"
ShowStatusBar
=
"true"
skin
=
"Office2010Silver"
OnItemCreated
=
"gridConfirmation_ItemCreated"
DataSourceID
=
"SqlDataSource4"
runat
=
"server"
AutoGenerateColumns
=
"False"
OnItemDataBound
=
"gridConfirmation_ItemDataBound"
AllowSorting
=
"True"
AllowMultiRowSelection
=
"False"
GridLines
=
"None"
>
<
pagerstyle
mode
=
"NumericPages"
></
pagerstyle
>
<%--<
ClientSettings
>
<
Scrolling
AllowScroll
=
"true"
ScrollHeight
=
"250px"
UseStaticHeaders
=
"true"
/>
</
ClientSettings
>--%>
<%-- enablehierarchyexpandall="true"--%>
<
mastertableview
datasourceid
=
"SqlDataSource4"
hierarchydefaultexpanded
=
"true"
datakeynames
=
"OValue"
allowmulticolumnsorting
=
"True"
showfooter
=
"true"
>
<%--<
FooterStyle
HorizontalAlign
=
"Right"
></
FooterStyle
>--%>
<
DetailTables
>
<%--hierarchydefaultexpanded="true"--%>
<
telerik:GridTableView
DataSourceID
=
"SqlDataSource5"
Width
=
"100%"
ShowFooter
=
"true"
runat
=
"server"
>
<
HeaderStyle
HorizontalAlign
=
"Right"
></
HeaderStyle
>
<
FooterStyle
HorizontalAlign
=
"Right"
></
FooterStyle
>
<
ParentTableRelation
>
<
telerik:GridRelationFields
DetailKeyField
=
"OValue"
MasterKeyField
=
"OValue"
></
telerik:GridRelationFields
>
</
ParentTableRelation
>
<
Columns
>
<
telerik:GridBoundColumn
SortExpression
=
"StorePLU"
HeaderText
=
"StorePLU"
HeaderButtonType
=
"TextButton"
DataField
=
"StorePLU"
UniqueName
=
"StorePLU"
HeaderStyle-Width
=
"100px"
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
</
telerik:GridBoundColumn
>
<
telerik:GridBoundColumn
SortExpression
=
"Descr"
HeaderText
=
"Description"
HeaderButtonType
=
"TextButton"
DataField
=
"Descr"
UniqueName
=
"Descr"
HeaderStyle-Width
=
"150px"
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
</
telerik:GridBoundColumn
>
<
telerik:GridBoundColumn
SortExpression
=
"NetQty"
HeaderText
=
"NetQty"
HeaderButtonType
=
"TextButton"
DataField
=
"NetQty"
UniqueName
=
"NetQty"
HeaderStyle-Width
=
"100px"
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
</
telerik:GridBoundColumn
>
<
telerik:GridBoundColumn
SortExpression
=
"NetSales"
HeaderText
=
"NetSales"
HeaderButtonType
=
"TextButton"
DataField
=
"NetSales"
UniqueName
=
"NetSales"
HeaderStyle-Width
=
"100px"
>
<
ItemStyle
HorizontalAlign
=
"Right"
/>
</
telerik:GridBoundColumn
>
</
Columns
>
<%-- <
SortExpressions
>
<
telerik:GridSortExpression
FieldName
=
"StorePLU"
SortOrder
=
"Ascending"
></
telerik:GridSortExpression
>
</
SortExpressions
>--%>
</
telerik:GridTableView
>
</
DetailTables
>
<
Columns
>
<
telerik:GridBoundColumn
SortExpression
=
"OValue"
HeaderText
=
"Sales Confirmation"
HeaderButtonType
=
"TextButton"
DataField
=
"OValue"
UniqueName
=
"OValue"
>
</
telerik:GridBoundColumn
>
</
Columns
>
<%-- <
SortExpressions
>
<
telerik:GridSortExpression
FieldName
=
"OValue"
></
telerik:GridSortExpression
>
</
SortExpressions
>--%>
</
mastertableview
>
</
telerik:RadGrid
>
<
asp:SqlDataSource
ID
=
"SqlDataSource4"
ConnectionString="<%$ ConnectionStrings:SiteSqlServerdev %>"
ProviderName="System.Data.SqlClient" SelectCommand="DINERO_GetActiveStoreRegistersforConfirmation" SelectCommandType="StoredProcedure"
runat="server" OnSelecting="SqlDataSourceGridView1_Selecting">
<
SelectParameters
>
<
asp:SessionParameter
Name
=
"FranStoreNumber"
Type
=
"string"
SessionField
=
"FranStoreNumber"
/>
</
SelectParameters
>
</
asp:SqlDataSource
>
<
asp:SqlDataSource
ID
=
"SqlDataSource5"
ConnectionString="<%$ ConnectionStrings:SiteSqlServerdev %>"
ProviderName="System.Data.SqlClient" SelectCommand="DINERO_GetRegisterSalesConfirmation" SelectCommandType="StoredProcedure"
runat="server" OnSelecting="SqlDataSourceGridView2_Selecting">
<
SelectParameters
>
<
asp:SessionParameter
Name
=
"OValue"
SessionField
=
"OValue"
Type
=
"string"
></
asp:SessionParameter
>
<
asp:SessionParameter
Name
=
"FranStoreNumber"
SessionField
=
"FranStoreNumber"
Type
=
"Int64"
/>
<
asp:SessionParameter
Name
=
"SalesDate"
SessionField
=
"SalesDate"
Type
=
"String"
/>
</
SelectParameters
>
</
asp:SqlDataSource
>
<
br
/>
<
br
/>
<
div
style
=
"float: left;"
>
<
telerik:RadButton
AutoPostBack
=
"True"
Text
=
"Make More Changes"
skin
=
"Sunset"
ID
=
"btnMakeChanges"
runat
=
"server"
OnClick
=
"btnMakeChangestoEntry_Click"
></
telerik:RadButton
>
</
div
>
<
div
style
=
"float: right;"
>
<
telerik:RadButton
AutoPostBack
=
"True"
Text
=
"I'm Done"
skin
=
"Sunset"
ID
=
"btnImdoneConfirmation"
runat
=
"server"
OnClick
=
"btnSaveConfirmationGrid"
></
telerik:RadButton
>
</
div
>
</
asp:Panel
>
<
telerik:RadCodeBlock
ID
=
"RadCodeBlock1"
runat
=
"server"
>
<
script
type
=
"text/javascript"
>
function isregisterselected(sender, args) {
var listbox = $find("<%=lstStoreRegisters.ClientID %>");
if (listbox.get_selectedItem() == null) {
alert("Please select a register");
sender.set_autoPostBack(false);
}
else {
sender.set_autoPostBack(true);
}
}
function validateMenuMixEntry(sender, args) {
alert("Hi");
var txtcustct = $find("<%=txtRegisterCustCount.ClientID%>");
custct = txtcustct.get_value();
var SalesTax = $find("<%=txtRegisterSalesTax.ClientID%>").get_value();
//alert(custct.get_value());
if (custct == "") {
alert('Please Enter Customer Count');
$find("<%=txtRegisterCustCount.ClientID%>").focus();
sender.set_autoPostBack(false);
return false;
}
else if (SalesTax == "") {
alert('Please Enter Sales Tax');
$find("<%=txtRegisterSalesTax.ClientID%>").focus();
sender.set_autoPostBack(false);
}
else {
sender.set_autoPostBack(true);
}
}
function confirmregisterdelete(sender, args) {
args.set_cancel(!window.confirm("Are you sure you want to delete Register?"));
}
function NewKeyPress(sender, args) {
var keyCharacter = args.get_keyCharacter();
//var number=args.get_value();
//if (keyCharacter == sender.get_numberFormat().NegativeSign || keyCharacter == sender.get_numberFormat().DecimalSeparator)
if (keyCharacter == sender.get_numberFormat().DecimalSeparator) {
args.set_cancel(true);
}
}
function SalesTaxNewKeyPress(sender, args) {
var keyCharacter = args.get_keyCharacter();
//var number=args.get_value();
if (keyCharacter == sender.get_numberFormat().NegativeSign) {
args.set_cancel(true);
}
}
function alertCallBackFn(arg) {
//radalert("<
strong
>radalert</
strong
> returned the following result: <
h3
style
=
'color: #ff0000;'
>" + arg + "</
h3
>", 350, 250, "Result");
return true;
}
function setEditorValue(sender, args) {
//args.set_cancel(true);
var value = args.get_value();
var buttonList = $telerik.findElement(args.get_cell(), "RadioButtonList1");
var items = $(buttonList).find("input");
if (items.length != 0) {
args.set_cancel(true);
}
for (var i = 0; i <
items.length
; i++) {
if (items[i].value == value) {
items[i]
.checked
=
true
;
}
else {
items[i]
.checked
=
false
;
}
}
return true;
}
function test() {
var grid = $find("<%=gridMenuMixConfig.ClientID %>");
var masterTable = grid.get_masterTableView();
var row = masterTable.get_dataItems()[4]; //accessing second row
var radio = rows.findElement('RadioButtonList1');
var elements = radio.getElementsByTagName("input");
var count = 0;
for (var i = 0; i <
elements.length
; i++) {
elements[i]
.checked
=
true
;
}
}
function getEditorvalue(sender, args) {
//args.set_cancel(true);
var buttonList = $telerik.findElement(args.get_cell(), "RadioButtonList1");
var items = $(buttonList).find("input");
if (items.length != 0) {
args.set_cancel(true);
}
for (var
i
=
0
; i < items.length; i++) {
if (items[i].checked) {
args.set_value(items[i].value);
break;
}
}
return true;
}
function gridCommand(sender, args) {
if (args.get_commandName() == "Batch") {
var
changesString
=
sender
.get_batchEditingManager()._extractChangesString(args.get_tableView());
if (changesString.length == 0) {
args.set_cancel(true);
}
}
}
function BatchEditCellValueChanged(sender, args) {
var grid = $find("<%= gridMenuMixEntry.ClientID %>");
grid.get_batchEditingManager().saveChanges(grid.get_masterTableView());
//alert("Thank you ")
}
function SaveChangesInGrid(sender, args) {
var grid = $find('<%=gridMenuMixConfig.ClientID%>');
grid.get_batchEditingManager().saveChanges(grid.get_masterTableView());
//alert('Thank you!Your changes have been saved.');
}
function lstselectindexchanged(sender, e) {
var listbox = $find("<%=lstStoreRegisters.ClientID %>");
var sel = listbox.get_selectedItem().get_value();
var textbox = $find("<%=txtRename.ClientID %>");
textbox.set_value(sel);
}
</
script
>
</
telerik:RadCodeBlock
>
<
script
type
=
"text/javascript"
>
function Gethiddenvalues() {
var dt = new Date();
//alert(dt.toLocaleTimeString())
document.getElementById('<%=hxvalue.ClientID%>').value = dt.toLocaleTimeString();
<%--alert(document.getElementById('<%=hxvalue.ClientID%>').value)--%>
}
$(document).ready(function () {
$("#<%= txtSalesDate.ClientID %>").datepicker({
minDate: -07, maxDate: 0,
showOn: "button",
buttonImage: "images/calendar.gif",
buttonImageOnly: true,
constrainInput: true,
buttonText: "Select date",
dateFormat: "mm/dd/yy"
});
});
</
script
>
0
Hello Surya,
To check the Keyboard Navigation of Batch editing, you can refer to this live sample:
http://demos.telerik.com/aspnet-ajax/grid/examples/data-editing/batch-editing/defaultcs.aspx
You can also check the following custom script:
http://www.telerik.com/forums/batch-edit-radgrid-with-cascading-raddropdownlist-issue#6ujbz1rKVE-jZ1XcQuN4Gg
Regards,
Eyup
Telerik
To check the Keyboard Navigation of Batch editing, you can refer to this live sample:
http://demos.telerik.com/aspnet-ajax/grid/examples/data-editing/batch-editing/defaultcs.aspx
You can also check the following custom script:
http://www.telerik.com/forums/batch-edit-radgrid-with-cascading-raddropdownlist-issue#6ujbz1rKVE-jZ1XcQuN4Gg
Regards,
Eyup
Telerik
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 Feedback Portal
and vote to affect the priority of the items
0
surya
Top achievements
Rank 1
answered on 02 Feb 2016, 02:28 PM
Hello Eyup...
I tried it but it is not working.I am using version 2013.2.717.40.Nothing is working on my end with keyboard navigation.if this feature is not availble in the version could you please send me the work around.I am sturck with this only thing.
Thank you
0
Hello Surya,
Keyboard navigation for Batch editing most probably is released in a newer version. I am afraid there is no workaround to incorporate it in older version. Generally, we highly suggest our customers to use the most recent versions of Telerik controls with richer functionality and stable performance.
Regards,
Eyup
Telerik
Keyboard navigation for Batch editing most probably is released in a newer version. I am afraid there is no workaround to incorporate it in older version. Generally, we highly suggest our customers to use the most recent versions of Telerik controls with richer functionality and stable performance.
Regards,
Eyup
Telerik
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 Feedback Portal
and vote to affect the priority of the items