Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
90 views
I am new to telerik and i want to ask how to update in radgrid with EditMode="InPlace" and without user double-click on the row
i saw this demo (http://demos.telerik.com/aspnet-ajax/grid/examples/dataediting/editondblclick/defaultcs.aspx) which require user to double-click the row to edit
In my case i want to update the data in RadNumericTextBox without the user double-click on the row.

This is my RadNumericTextBox
<telerik:GridTemplateColumn DataField="quantity"
                FilterControlAltText="Filter TemplateColumn column" UniqueName="quantity"
                HeaderText="Quantity" SortExpression="quantity">
                <ItemTemplate>
                    <telerik:RadNumericTextBox ID="quantityTextBox" runat="server"
                        ShowSpinButtons="True" width="50px"
                        DbValue='<%# Convert.ToDouble(Eval("quantity")) %>'
                        DataType="System.Int32" Culture="en-SG" NumberFormat-DecimalDigits="0" MinValue="0" MaxValue="999" ClientEvents-OnValueChanging="editQuantity">
                </telerik:RadNumericTextBox>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
The RadNumericTextBox ClientEvents-OnValueChanging="editQuantity" and i am stuck at the javascript.
I am not sure of how to update without getting the selected rows.

Sorry about my bad english and thank everyone for reading my problem or giving me advice/help.
Weilun
Top achievements
Rank 1
 answered on 17 Jan 2012
6 answers
115 views
Hello Everyone!

I have a problem regarding the DropdownColumn of the grid.

I have a grid with an inline edit and add mode. I also have a Dropdowncolumn in my grid.

What i want is that when I a new item using inline adding of the grid, the Dropdownlist of the Dropdowncolumn should display Items that are not added in the grid.

In short, The Items that are in the grid (specifically in my dropdown column) should not be displayed in the DropDownList during Adding.

I have tried this link

http://www.telerik.com/help/aspnet-ajax/grdcustomizeconfiguregriddropdowncolumn.html

but If I change the datasource of the DropDownColumn, the grid data of my DropDownColumn will be replaced with the firts item in my dropdownlist during adding mode.
Shinu
Top achievements
Rank 2
 answered on 17 Jan 2012
1 answer
75 views
Hi,

I have taken on Label Control to display Margin. I can do grand total but I am not able to do total when it group by. 

 <telerik:GridTemplateColumn AllowFiltering="false" HeaderText="HGU Margin %" SortExpression="HGUMargin"
                                UniqueName="HGUMargin"  ColumnEditorID="HGUMarginEditor">
                                <ItemTemplate>
                                    <asp:Label ID="lblHGUMargin" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "HGUMargin", "{0:P2}")%>'></asp:Label>
                                </ItemTemplate>
                                <FooterTemplate>
                                    <asp:Label runat="server" Text="test" ID="lblforHGUMargin"></asp:Label>
                                </FooterTemplate>
                                <FooterStyle Width="50px" />
                            </telerik:GridTemplateColumn>

On Code behind I am trying to display margin like this:

 if (e.Item.ItemType == GridItemType.GroupFooter)
            {              
 GridGroupFooterItem itemGroupFooter = e.Item as GridGroupFooterItem;
(itemGroupFooter["HGUMargin"].FindControl("lblforHGUMargin") as Label).Text = hgusp.ToString("00.00") + "%";
}
It gives me null label.


My question is How to find label control in code behind or client id of label when I do group by.



Thanks,
Mona

Shinu
Top achievements
Rank 2
 answered on 17 Jan 2012
2 answers
114 views
I am trying to get scheduler resources working the same as the First Look Demo, however the Telerik\RadControls for ASP.NET AJAX Q3 2011\Live Demos  code dowloaded with the 2011 Q3 update to my program files directory doesn't work.  When you uncheck the marketing button, nothing happens. Then if you uncheck the Development button then both marketing and development dissappear.  Checking and unchecking boxes gives strange results.

However the live demo on the web site works perfectly. The Javascript functions to rebindScheduler etc are all identical and work on the onchange event of the html check box.  Can you tell me what you have updated to make the live demo work?
Russell Shannon
Top achievements
Rank 1
 answered on 17 Jan 2012
3 answers
382 views
I have Treeview (attached) and I want to decrease the vertical spacing.

Here is the CSS file.
.RadTreeView_tree_2,
.RadTreeView_tree_2 a.rtIn,
.RadTreeView_tree_2 .rtEdit .rtIn input
{
    color: #000000;
    font: 12px/18px "Segoe UI", Arial, sans-serif;
    /*line-height: inherit;*/
}
 
.RadTreeView_tree_2 .rtPlus,
.RadTreeView_tree_2 .rtMinus
{
    background-image: url('TreeView/PlusMinus.png');
}
 
.RadTreeView_tree_2 .rtChecked,
.RadTreeView_tree_2 .rtUnchecked,
.RadTreeView_tree_2 .rtIndeterminate
{
    background-image: url('TreeView/TriState.png');
}
 
.RadTreeView_tree_2 .rtHover .rtIn,
.RadTreeView_tree_2 .rtSelected .rtIn
{
    color: #363636;
    border: 1px solid #fcd132;
}
 
.RadTreeView_tree_2 .rtHover .rtIn
{
    background-color: #fcf9de;
    background-image: url('TreeView/ItemHoveredBg.png');
}
 
.RadTreeView_tree_2 .rtSelected .rtIn
{
    background-color: #fcecb1;
    background-image: url('TreeView/ItemSelectedBg.png');
}
 
.RadTreeView_tree_2 .rtSelected .rtLoadingBefore,
.RadTreeView_tree_2 .rtSelected .rtLoadingAfter,
.RadTreeView_tree_2 .rtSelected .rtLoadingBelow
{
    color: #333333;
}
 
.RadTreeView_tree_2 .rtLI .rtEdit .rtIn
{
    border-color: #fcd132;
    background: #ffffff;
}
 
.RadTreeView_tree_2_disabled .rtIn,
.RadTreeView_tree_2 .rtDisabled .rtIn
{
    color: #cccccc;
}
 
div.RadTreeView_tree_2 .rtIn
{
    /*font-size: 11px;
    line-height: normal;*/
    font-weight: normal;
}
 
div.RadTreeView_tree_2 .rtHover .rtIn
{
    line-height: normal;
    font-weight: bold;
}
 
div.RadTreeView_tree_2 .rtSelected .rtIn
{
    font-weight: bold;
}
 
div.RadTreeView_tree_2 .rtIn
{
    /*font-size: 10px;
    line-height: 12px;*/
}
 
div.RadTreeView_tree_2 .rtHover .rtIn
{
    border-right-color: rgb(252,209,50);
    /*line-height: 12px;
    font-size: 10px;*/
}
 
div.RadTreeView_tree_2 .rtSelected .rtIn
{
    /*font-size: 10px;*/
    font-weight: bold;
}
Richard
Top achievements
Rank 1
 answered on 16 Jan 2012
1 answer
182 views
hi

Im trying to insert a row at the bottom of Grid view with out postback
My Grid has one coloum with rad Combo

placed my Grid view and button in Update panel  and in code behined on button click add a new row to datatable and Binding It to grid view

in Upadate panel gave trigger attributes

 

<Triggers>

 

 

<asp:AsyncPostBackTrigger controlid="btnAddrw" eventname="Click" />

 

 

</Triggers>

im getting the below error as attached

if i remove the above trigger  code  row is getting added but page is getting Postback

How to fix this?

thanks, Harin

 



Richard
Top achievements
Rank 1
 answered on 16 Jan 2012
7 answers
314 views
Hi There,

I've been trying achieve the following, but could not get it done. Looking for any of your help.
  • Have two dropdown column in grid (State & County)
  • State column is bound with Object DataSource
  • County column is also bound with another Object DataSource.

But, County column is related to State. When the grid is bound with DataSource, I need to display State Name and County Name in place of their IDs (Database record would have StateID & CountyID). That's the reason I chose Dropdown columns. so that I can have simple text rendered in view mode. 

Here is what I'm doing..
  1. Assign DataSource to the grid at runtime.
  2. In the grid ItemCreated event, passing the current row's StateID to the County ODS SelectParameter.
       (by expecting that ODS would get me the list of Counties for the give StateID)

Observation:
  1. For the first row, I'm getting the County Name displayed
  2. But for the second row, its empty.

I found that, ODS Selecting event first only once (when the grid was bound), but not for all the rows.
Note: I need grid only in view mode. Not editing rows in grid.
I tried having template columns, but could not find - how to display the county name for the corresponding id. (I do not want Combo box to be displayed, only county name has to be displayed)

Pls give your helping hand to pass out from this hurdle.
If you have any other solution, pls pass it to. 

Counting upon the positive response..

<telerik:GridDropDownColumn DataField="StateID" DataSourceID="odsState"
    FilterControlAltText="Filter StateID column" HeaderText="State"
    ListTextField="DisplayText" ListValueField="ValueText" UniqueName="StateID">
</telerik:GridDropDownColumn>
 
<telerik:GridDropDownColumn DataField="CountyID" DataSourceID="odsCounty"
    FilterControlAltText="Filter CountyID column" HeaderText="County"
    ListTextField="DisplayText" ListValueField="ValueText" UniqueName="CountyID">
</telerik:GridDropDownColumn>
 
 
<asp:ObjectDataSource ID="odsState" runat="server" SelectMethod="GetStates" TypeName="MyBLL">       
</asp:ObjectDataSource>
 
<asp:ObjectDataSource ID="odsCounty" runat="server" SelectMethod="GetCounties" TypeName="MyBLL">
    <SelectParameters>
        <asp:Parameter Name="stateID" Type="String" />
    </SelectParameters>
</asp:ObjectDataSource>

protected void grid_ItemCreated(object sender, GridItemEventArgs e)
{
 
    if (e.Item is GridDataItem)
        odsCounty.SelectParameters["stateSaid"].DefaultValue = "I'm assigning the currect row's state ID here";

 //Assuming that for every row, ods selecting event would fire. But its not happening
}

Pavlina
Telerik team
 answered on 16 Jan 2012
3 answers
227 views
Hi

I have a linkbutton in the template column. I am already triggering an event on the link button press and able to get the row. I was able to highlight it but when the next row linkbutton is clicked, i need to put the previous selected to original position. I was trying to do using row id but there is no ID for row. How can I do it differently? I was also thought may be I can put arrow in the gridgroupsplittercolumn for row selected but I don't know how to get splittercolumn id for the selected row.

Any suggestion would be appreciated.

Vijai
Jayesh Goyani
Top achievements
Rank 2
 answered on 16 Jan 2012
1 answer
63 views
I have an application that manages currencies on hand for various countries.  Each group is essentially a country that consists of records for each banknote denomination.

What I want to do is have a button in the group footer for each country that:

A - Is labeled "Delete United Kingdom Pound
B - When clicked, it will run an SQL query to delete all records for that country.

I have been unable to label the button.
I have been unable to get the country code needed to run the delete query.

I am developing on a Windows 7 computer using MS Visual Studio 2010.

Please let me know if I can provide more information.

<telerik:RadStyleSheetManager id="RadStyleSheetManager1" runat="server" />
    <style type="text/css">
     .body
     {
         background:#eeeeee;
     }
     .MyBoldedRow
     {
       font-weight: bold;
       color: Red;
     }
     .MyNormalRow
     {
       font-weight: Normal;
       color: Black;
     }
     .RadTextboxClass
     {
        text-align:right;
     }
      
    </style>
</head>
    <body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
        <Scripts>
            <%--Needed for JavaScript IntelliSense in VS2010--%>
            <%--For VS2008 replace RadScriptManager with ScriptManager--%>
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" />
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" />
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js" />
        </Scripts>
    </telerik:RadScriptManager>
    <script type="text/javascript">
        //Put your JavaScript code here.
    </script>
        <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
            <AjaxSettings>
                <telerik:AjaxSetting AjaxControlID="RadGrid1">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="RadGrid1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
            </AjaxSettings>
        </telerik:RadAjaxManager>
    <div>
            <asp:SqlDataSource  ID="CountryCodes" runat="server"
            ConnectionString="Data Source=W-SQL04.dlbassociates.com;Initial Catalog=DonPlanner;Integrated Security=SSPI"
            SelectCommand="SELECT 'XXXX' as CurrencyTarget_CountryCode, '<Select a Country>' as DisplayValue UNION SELECT dbo.Currency_LatestConversions_TBL.Currency_CountryCode as CountryCode, dbo.Currency_LatestConversions_TBL.Currency_CountryDesc + ' (' + dbo.Currency_LatestConversions_TBL.Currency_CountryCode + ')' as DisplayValue
                FROM dbo.Currency_LatestConversions_TBL
                LEFT OUTER JOIN dbo.Currency_TargetAmounts_TBL ON dbo.Currency_LatestConversions_TBL.Currency_CountryCode = dbo.Currency_TargetAmounts_TBL.CurrencyTarget_CountryCode
                ORDER BY DisplayValue ASC">
        </asp:SqlDataSource>
 
        <asp:SqlDataSource ID="SqlDataSource1" runat="server"
            ConnectionString="<%$ ConnectionStrings:DonPlannerCS %>"
            DeleteCommand="DELETE FROM Currency_TargetAmounts_TBL WHERE CurrencyTarget_CountryCode = @CurrencyTarget_CountryCode"
            InsertCommand="INSERT INTO [Currency_TargetAmounts_TBL] ([CurrencyTarget_CountryCode], [CurrencyTarget_USDDenomination], [CurrencyTarget_USDNeeded], [CurrencyTarget_Native], [CurrencyTarget_NativeCurrent])
                Select @CurrencyTarget_CountryCode, @USDDenomination1, @USRequired1, @NativeDenom1, @CurrentCount1 UNION ALL
                Select @CurrencyTarget_CountryCode, @USDDenomination2, @USRequired2, @NativeDenom2, @CurrentCount2 UNION ALL
                Select @CurrencyTarget_CountryCode, @USDDenomination3, @USRequired3, @NativeDenom3, @CurrentCount3 UNION ALL
                Select @CurrencyTarget_CountryCode, @USDDenomination4, @USRequired4, @NativeDenom4, @CurrentCount4 UNION ALL
                Select @CurrencyTarget_CountryCode, @USDDenomination5, @USRequired5, @NativeDenom5, @CurrentCount5"
            SelectCommand="SELECT TOP (100) PERCENT
                dbo.Currency_TargetAmounts_TBL.Currency_ID,
                dbo.Currency_TargetAmounts_TBL.CurrencyTarget_CountryCode,
                dbo.Currency_LatestConversions_TBL.Currency_CountryDesc,
                dbo.Currency_TargetAmounts_TBL.CurrencyTarget_USDDenomination,
                dbo.Currency_TargetAmounts_TBL.CurrencyTarget_USDNeeded,
                dbo.Currency_TargetAmounts_TBL.CurrencyTarget_Native,
                dbo.Currency_TargetAmounts_TBL.CurrencyTarget_NativeCurrent,
                CEILING(dbo.Currency_TargetAmounts_TBL.CurrencyTarget_USDNeeded / (dbo.Currency_TargetAmounts_TBL.CurrencyTarget_Native * (1 / dbo.Currency_LatestConversions_TBL.Currency_Conversion))) AS CountNeeded
                FROM dbo.Currency_LatestConversions_TBL LEFT OUTER JOIN
                dbo.Currency_TargetAmounts_TBL ON
                dbo.Currency_LatestConversions_TBL.Currency_CountryCode = dbo.Currency_TargetAmounts_TBL.CurrencyTarget_CountryCode
                WHERE (NOT (dbo.Currency_TargetAmounts_TBL.CurrencyTarget_CountryCode IS NULL))
                ORDER BY dbo.Currency_LatestConversions_TBL.Currency_CountryDesc, dbo.Currency_TargetAmounts_TBL.CurrencyTarget_USDDenomination"
            UpdateCommand="UPDATE [Currency_TargetAmounts_TBL] SET 
                [CurrencyTarget_USDNeeded] = @CurrencyTarget_USDNeeded,
                [CurrencyTarget_Native] = @CurrencyTarget_Native,
                [CurrencyTarget_NativeCurrent] = @CurrencyTarget_NativeCurrent
                WHERE [Currency_ID]=@Currency_ID">
            <DeleteParameters>
                <asp:Parameter Name="CurrencyTarget_ID" />
            </DeleteParameters>
            <InsertParameters>
                <asp:Parameter Type="String" Name="CurrencyTarget_CountryCode" />
 
                <asp:Parameter Type="Int32" Name="USDDenomination1" />
                <asp:Parameter Type="Int32" Name="USRequired1" />
                <asp:Parameter Type="Int32" Name="NativeDenom1" />
                <asp:Parameter Type="Int32" Name="CurrentCount1" />
 
                <asp:Parameter Type="Int32" Name="USDDenomination2" />
                <asp:Parameter Type="Int32" Name="USRequired2" />
                <asp:Parameter Type="Int32" Name="NativeDenom2" />
                <asp:Parameter Type="Int32" Name="CurrentCount2" />
 
                <asp:Parameter Type="Int32" Name="USDDenomination3" />
                <asp:Parameter Type="Int32" Name="USRequired3" />
                <asp:Parameter Type="Int32" Name="NativeDenom3" />
                <asp:Parameter Type="Int32" Name="CurrentCount3" />
 
                <asp:Parameter Type="Int32" Name="USDDenomination4" />
                <asp:Parameter Type="Int32" Name="USRequired4" />
                <asp:Parameter Type="Int32" Name="NativeDenom4" />
                <asp:Parameter Type="Int32" Name="CurrentCount4" />
 
                <asp:Parameter Type="Int32" Name="USDDenomination5" />
                <asp:Parameter Type="Int32" Name="USRequired5" />
                <asp:Parameter Type="Int32" Name="NativeDenom5" />
                <asp:Parameter Type="Int32" Name="CurrentCount5" />
 
            </InsertParameters>
            <UpdateParameters>
                <asp:Parameter Name="CurrencyTarget_USDNeeded" />
                <asp:Parameter Name="CurrencyTarget_Native" />
                <asp:Parameter Name="CurrencyTarget_NativeCurrent" />
            </UpdateParameters>
        </asp:SqlDataSource>
        <asp:Label ID="Label1" runat="server" Text="Don Beaty's Foreign Currency Tracker"
                Font-Bold="False" Font-Names="Calibri" Font-Size="XX-Large"></asp:Label>
        <telerik:RadGrid ID="RadGrid1" runat="server" AllowAutomaticUpdates="True"
                CellSpacing="0" DataSourceID="SqlDataSource1" GridLines="None"
                BorderColor="Gray" BorderStyle="Inset">
            <MasterTableView autogeneratecolumns="False" commanditemdisplay="Top"
                datasourceid="SqlDataSource1" allowpaging="True"
                datakeynames="Currency_ID"
                PageSize="30" EditMode="InPlace" Name="Currency" showgroupfooter="True">
                <CommandItemSettings ExportToPdfText="Export to PDF"></CommandItemSettings>
 
                <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
                    <HeaderStyle Width="20px"></HeaderStyle>
                </RowIndicatorColumn>
 
                <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">
                    <HeaderStyle Width="20px"></HeaderStyle>
                </ExpandCollapseColumn>
 
                <Columns>
                    <telerik:GridTemplateColumn
                        FilterControlAltText="Filter EditCommandColumn column"
                        Groupable="False"
                        UniqueName="EditCommandColumn">
 
                        <ItemTemplate>
                            <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="false" CommandName="Edit" Text="Edit"></asp:LinkButton>
                        </ItemTemplate>
 
                        <EditItemTemplate>
                            <asp:LinkButton ID="LinkButton1" runat="server" CommandName="Update" Text="Update"></asp:LinkButton
                             <asp:LinkButton ID="LinkButton2" runat="server" CausesValidation="false" CommandName="Cancel" Text="Cancel"></asp:LinkButton>
                        </EditItemTemplate>
 
                        <InsertItemTemplate>
                            <asp:LinkButton ID="LinkButton3" runat="server" CommandName="Insert" Text="Insert"></asp:LinkButton>
                            <asp:LinkButton ID="LinkButton4" runat="server" CausesValidation="false" CommandName="Cancel" Text="Cancel"></asp:LinkButton>
                        </InsertItemTemplate>
 
                    </telerik:GridTemplateColumn>
 
                    <telerik:GridTemplateColumn
                        DataField="Currency_ID"
                        FilterControlAltText="Filter Currency_ID column"
                        HeaderText=""
                        SortExpression="Currency_ID"
                        UniqueName="Currency_ID">
 
                        <ItemTemplate>
                             
                        </ItemTemplate>
 
                        <EditItemTemplate>
                            <asp:Label ID="Currency_IDLabel1" runat="server" Text='<%# Bind("Currency_ID") %>'></asp:Label>
                        </EditItemTemplate>
 
                        <InsertItemTemplate></InsertItemTemplate>
 
                    </telerik:GridTemplateColumn>
 
                    <telerik:GridTemplateColumn
                        DataField="CurrencyTarget_CountryCode"
                        FilterControlAltText="Filter column column"
                        HeaderText="Country Code"
                        UniqueName="ddCountryCode">
                          
                        <ItemTemplate>
                            <asp:Label ID="CurrencyTarget_CountryCodeLabel" runat="server" Text='<%# Bind("CurrencyTarget_CountryCode") %>'></asp:Label>
                        </ItemTemplate>
 
                        <EditItemTemplate>
                            <asp:Label ID="CurrencyTarget_CountryCodeLabel1" runat="server" Text='<%# Bind("CurrencyTarget_CountryCode") %>'></asp:Label>
                        </EditItemTemplate>
 
                        <InsertItemTemplate>
                            <telerik:RadComboBox ID="CurrencyTarget_CountryCode" runat="server"
                                DataSourceID="CountryCodes" DataTextField="DisplayValue"
                                DataValueField="CurrencyTarget_CountryCode"
                                SelectedValue='<%# Bind("CurrencyTarget_CountryCode") %>'>
                            </telerik:RadComboBox>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ErrorMessage="Select A Country Code" ControlToValidate="CurrencyTarget_CountryCode" ValidationExpression="[^<]*"/>
                        </InsertItemTemplate>
                    </telerik:GridTemplateColumn>
 
                    <telerik:GridTemplateColumn
                        DataField="Currency_CountryDesc"
                        FilterControlAltText="Filter Currency_CountryDesc column"
                        HeaderText="Country Description"
                        SortExpression="Currency_CountryDesc"
                        UniqueName="Currency_CountryDesc">
 
                        <ItemTemplate>
                            <asp:Label ID="Currency_CountryDescLabel" runat="server" Text='<%# Bind("Currency_CountryDesc") %>'></asp:Label>
                        </ItemTemplate>
 
                        <EditItemTemplate>
                            <asp:Label ID="Currency_CountryDescLabel1" runat="server" Text='<%# Bind("Currency_CountryDesc") %>'></asp:Label>
                        </EditItemTemplate>
 
                        <InsertItemTemplate></InsertItemTemplate>
 
                    </telerik:GridTemplateColumn>
 
                    <telerik:GridTemplateColumn
                        DataField="CurrencyTarget_USDDenomination"
                        DataType="System.Int32"
                        FilterControlAltText="Filter CurrencyTarget_USDDenomination column"
                        HeaderText="USD Denomination"
                        SortExpression="CurrencyTarget_USDDenomination"
                        UniqueName="CurrencyTarget_USDDenomination">
                         
                        <ItemTemplate>
                            <asp:Label ID="CurrencyTarget_USDDenominationLabel" runat="server" Text='<%# Eval("CurrencyTarget_USDDenomination","${0:#}") %>'></asp:Label>
                        </ItemTemplate>
 
                        <EditItemTemplate>
                            <asp:Label ID="CurrencyTarget_USDDenominationLabel1" runat="server" Text='<%#  Eval("CurrencyTarget_USDDenomination", "${0:#}") %>'></asp:Label>
                        </EditItemTemplate>
 
                        <InsertItemTemplate>
                             
                            <telerik:RadNumericTextBox ID="USDDenomination1" runat="server" NumberFormat-DecimalDigits="0" Value="5" MinValue="1" CssClass="RadTextboxClass" /><br />
                            <br /><telerik:RadNumericTextBox ID="USDDenomination2" runat="server" NumberFormat-DecimalDigits="0" Value="10" MinValue="1" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="USDDenomination3" runat="server" NumberFormat-DecimalDigits="0" Value="20" MinValue="1" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="USDDenomination4" runat="server" NumberFormat-DecimalDigits="0" Value="50" MinValue="1" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="USDDenomination5" runat="server" NumberFormat-DecimalDigits="0" Value="100" MinValue="1" CssClass="RadTextboxClass"/><br />
 
                        <br /></InsertItemTemplate>
 
                        <HeaderStyle HorizontalAlign="Right" />
 
                        <ItemStyle HorizontalAlign="Right" />
 
                    </telerik:GridTemplateColumn>
 
                    <telerik:GridTemplateColumn
                        DataField="CurrencyTarget_USDNeeded"
                        DataType="System.Int32"
                        FilterControlAltText="Filter CurrencyTarget_USDNeeded column"
                        HeaderText="USD Needed"
                        SortExpression="CurrencyTarget_USDNeeded"
                        UniqueName="CurrencyTarget_USDNeeded">
 
                        <ItemTemplate>
                            <asp:Label ID="CurrencyTarget_USDNeededLabel" runat="server" Text='<%# Bind("CurrencyTarget_USDNeeded", "${0:#}")  %>'></asp:Label>
                        </ItemTemplate>
 
                        <EditItemTemplate>
                            <telerik:RadNumericTextBox ID="CurrencyTarget_USDNeededTextBox" runat="server" NumberFormat-DecimalDigits="0" text='<%# Bind("CurrencyTarget_USDNeeded") %>' MinValue="0" CssClass="RadTextboxClass"/>
                        </EditItemTemplate>
 
                        <InsertItemTemplate>
                            <telerik:RadNumericTextBox ID="USRequired1" runat="server" NumberFormat-DecimalDigits="0" Value="10" MinValue="0" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="USRequired2" runat="server" NumberFormat-DecimalDigits="0" Value="0" MinValue="0" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="USRequired3" runat="server" NumberFormat-DecimalDigits="0" Value="40" MinValue="0" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="USRequired4" runat="server" NumberFormat-DecimalDigits="0" Value="150" MinValue="0" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="USRequired5" runat="server" NumberFormat-DecimalDigits="0" Value="300" MinValue="0" CssClass="RadTextboxClass"/><br />
                        <br /></InsertItemTemplate>
 
                        <HeaderStyle HorizontalAlign="Right" />
 
                        <ItemStyle HorizontalAlign="Right" />
 
                    </telerik:GridTemplateColumn>
 
                    <telerik:GridTemplateColumn
                        DataField="CurrencyTarget_Native"
                        DataType="System.Int32"
                        FilterControlAltText="Filter CurrencyTarget_Native column"
                        HeaderText="Foreign Denomination"
                        SortExpression="CurrencyTarget_Native"
                        UniqueName="CurrencyTarget_Native">
 
                        <ItemTemplate>
                            <asp:Label ID="CurrencyTarget_NativeLabel" runat="server" Text='<%# Bind("CurrencyTarget_Native") %>'></asp:Label>
                        </ItemTemplate>
 
                        <EditItemTemplate>
                            <telerik:RadNumericTextBox ID="CurrencyTarget_NativeTextBox" runat="server" NumberFormat-DecimalDigits="0" text='<%# Bind("CurrencyTarget_Native") %>' MinValue="1" CssClass="RadTextboxClass"/>
                        </EditItemTemplate>
 
                        <InsertItemTemplate>
                            <telerik:RadNumericTextBox ID="NativeDenom1" runat="server" NumberFormat-DecimalDigits="0" MinValue="1" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="NativeDenom2" runat="server" NumberFormat-DecimalDigits="0" MinValue="1" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="NativeDenom3" runat="server" NumberFormat-DecimalDigits="0" MinValue="1" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="NativeDenom4" runat="server" NumberFormat-DecimalDigits="0" MinValue="1" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="NativeDenom5" runat="server" NumberFormat-DecimalDigits="0" MinValue="1" CssClass="RadTextboxClass"/><br />
                        <br /></InsertItemTemplate>
 
                        <HeaderStyle HorizontalAlign="Right" />
 
                        <ItemStyle HorizontalAlign="Right" />
 
                    </telerik:GridTemplateColumn>
                     
                    <telerik:GridTemplateColumn
                        DataField="CurrencyTarget_NativeCurrent"
                        DataType="System.Decimal"
                        FilterControlAltText="Filter CurrencyTarget_NativeCurrent column"
                        HeaderText="Foreign Count On Hand"
                        SortExpression="CurrencyTarget_NativeCurrent"
                        UniqueName="CurrencyTarget_NativeCurrent">
 
                        <ItemTemplate>
                            <asp:Label ID="CurrencyTarget_NativeCurrentLabel" runat="server" Text='<%# Bind("CurrencyTarget_NativeCurrent") %>'></asp:Label>
                        </ItemTemplate>
 
                        <EditItemTemplate>
                            <telerik:RadNumericTextBox ID="CurrencyTarget_NativeCurrentLabel" runat="server" NumberFormat-DecimalDigits="0" text='<%# Bind("CurrencyTarget_NativeCurrent") %>' MinValue="0" CssClass="RadTextboxClass"/>
                        </EditItemTemplate>
 
                        <InsertItemTemplate>
                            <telerik:RadNumericTextBox ID="CurrentCount1" runat="server" Value="0" NumberFormat-DecimalDigits="0" MinValue="0" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="CurrentCount2" runat="server" Value="0" NumberFormat-DecimalDigits="0" MinValue="0" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="CurrentCount3" runat="server" Value="0" NumberFormat-DecimalDigits="0" MinValue="0" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="CurrentCount4" runat="server" Value="0" NumberFormat-DecimalDigits="0" MinValue="0" CssClass="RadTextboxClass"/><br />
                            <br /><telerik:RadNumericTextBox ID="CurrentCount5" runat="server" Value="0" NumberFormat-DecimalDigits="0" MinValue="0" CssClass="RadTextboxClass"/><br />
                        <br /></InsertItemTemplate>
 
                        <HeaderStyle HorizontalAlign="Right" />
 
                        <ItemStyle HorizontalAlign="Right" />
 
                    </telerik:GridTemplateColumn>
 
                    <telerik:GridTemplateColumn
                        DataField="CountNeeded"
                        DataType="System.Decimal"
                        FilterControlAltText="Filter CountNeeded column"
                        HeaderText="Count Needed"
                        SortExpression="CountNeeded"
                        UniqueName="CountNeeded">
 
                        <ItemTemplate>
                            <asp:Label ID="CountNeeded" runat="server" Text='<%# Bind("CountNeeded") %>'></asp:Label>
                        </ItemTemplate>
 
                        <EditItemTemplate>
                            <asp:label ID="CountNeededTextBox" runat="server" Text='<%# Bind("CountNeeded") %>'></asp:label>
                        </EditItemTemplate>
 
                        <InsertItemTemplate></InsertItemTemplate>
 
                        <HeaderStyle HorizontalAlign="Right" />
 
                        <ItemStyle HorizontalAlign="Right" />
 
                    </telerik:GridTemplateColumn>
         
                </Columns>
 
                <GroupByExpressions>
                    <telerik:GridGroupByExpression>
                        <SelectFields>
                            <telerik:GridGroupByField FieldAlias="CountryCode" FieldName="CurrencyTarget_CountryCode" HeaderText="Country Code" />
                        </SelectFields>
                        <GroupByFields>
                            <telerik:GridGroupByField FieldAlias="CurrencyTarget_CountryCode" FieldName="CurrencyTarget_CountryCode" />
                        </GroupByFields>
                    </telerik:GridGroupByExpression>
                </GroupByExpressions>
 
                <GroupFooterTemplate>
                    <telerik:RadButton ID="RadButton1" runat="server" OnClick="RadButton1_click" Text='<%# Bind("CurrencyTarget_CountryCode") %>'>
                    </telerik:RadButton>
                </GroupFooterTemplate>
 
                <EditFormSettings>
                    <EditColumn FilterControlAltText="Filter EditCommandColumn column"></EditColumn>
                </EditFormSettings>
                <GroupHeaderItemStyle BackColor="PaleGreen" BorderColor="Black" BorderStyle="Solid" Font-Bold="True" Font-Names="Calibri" Font-Size="Medium" ForeColor="Black" />
                <AlternatingItemStyle BackColor="#D7FFD7" />
                <PagerStyle AlwaysVisible="True" BackColor="#FFC080" />
                <HeaderStyle Font-Bold="True" />
            </MasterTableView>
 
            <FilterMenu EnableImageSprites="False"></FilterMenu>
 
            <HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Default"></HeaderContextMenu>
 
        </telerik:RadGrid>
    </div>
    </form>
</body>
</html>


Rick
Top achievements
Rank 1
 answered on 16 Jan 2012
7 answers
135 views
Hello Team,

I'm facing the following issue with the Telerik Rad Tree View.

I've a tree view with multiple parent and child node relations. For instance consider a node A which has 5 child nodes a,b,c,d and e. Now i've set the CheckChildNodes property of the control to true.

Now i select the node A. So it will in turn select a,b,c,d,e. I'm unchecking a,b. Then i'm doing a postback which goes to another page and shows some content pertaining to the nodes selected. Now i click the "back" button in the browser and come to the original page. So the treeview shows the node A as selected and c,d,e as selected (and a,b as unselected). Fine till now.

Now if i unselect the node A, it is selecting all its child nodes a,b,c,d,e. If i check the node A, it is unselecting all its child nodes a,b,c,d,e. Exactly opposite!

Could some one provide some insights in this issue?

Thank you.

Regards
NLV
Bozhidar
Telerik team
 answered on 16 Jan 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?