Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
410 views
How to get the selected values leaf nodes of raddropdown tree  with chceck boxes .
when  i am click to save button pass only leaf node values using comma separated  string ..


 
Thanks!
SR
Top achievements
Rank 1
 answered on 17 Jan 2014
17 answers
1.2K+ views
Hi Telerik Team,

I have a RadGrid requirement that needs "InPlace" Editmode in which there need to be two dropdown columns one depends on other dropdown selection...

so i have seen a example in your site 

http://demos.telerik.com/aspnet-ajax/grid/examples/dataediting/validation/defaultcs.aspx

in this example when "Adding new Record" can i load data in second "Dropdownlist" depending on the first "Dropdownlist" selected value.
If so what is the best template column i can use to have an access on Dropdownlists.

Can u please guide me with correct approach how to obtain this requirement.

Its urgent...Please do respond

Thanks in Advance.
Princy
Top achievements
Rank 2
 answered on 17 Jan 2014
3 answers
354 views
Hi,
             I want to validation on asp control Checkboxlist and Telrik control Radlistbox inside the radlist view using Required validator or custom validator. please provide sample code.

Thanks,
Rahul
Shinu
Top achievements
Rank 2
 answered on 17 Jan 2014
1 answer
169 views
Is there a way to set the ! icon inside the RadDatePicker control using JavaScript?
Princy
Top achievements
Rank 2
 answered on 17 Jan 2014
5 answers
105 views
Hello,

I am using the Filterexpressions to filter a Grid depending of an DropDownList.

Here is the Code from the GridView:
<telerik:RadGrid ID="ContactsGrid" runat="server" AllowAutomaticDeletes="True"
                            AllowAutomaticInserts="True" AllowAutomaticUpdates="True" AllowPaging="True"
                            AllowSorting="True" Culture="de-DE" DataSourceID="contacts"
                            GridLines="None" Height="100%" OnItemCreated="ContactsGrid_ItemCreated"
                            OnItemInserted="ContactsGrid_ItemInserted"
                                OnPreRender="ContactsGrid_PreRender"
                                onneeddatasource="ContactsGrid_NeedDataSource"                                
                                onitemdatabound="ContactsGrid_ItemDataBound">                               
                            <MasterTableView AutoGenerateColumns="False" CommandItemDisplay="Top"
                                DataKeyNames="ContactsID" DataSourceID="contacts" InsertItemPageIndexAction="ShowItemOnCurrentPage">
                                <Columns>
                                    <telerik:GridEditCommandColumn ButtonType="ImageButton"
                                        UniqueName="EditCommandColumn">
                                    </telerik:GridEditCommandColumn>
                                    <telerik:GridBoundColumn DataField="ContactsID" DataType="System.Int32"
                                        FilterControlAltText="Filter ContactsID column" HeaderText="ContactsID"
                                        SortExpression="ContactsID" UniqueName="ContactsID">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="CustomerID" DataType="System.Int32"
                                        FilterControlAltText="Filter CustomerID column" HeaderText="CustomerID"
                                        SortExpression="CustomerID" UniqueName="CustomerID">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="Name" DataFormatString="<nobr>{0}</nobr>"
                                        FilterControlAltText="Filter Name column" HeaderText="Name"
                                        SortExpression="Name" UniqueName="Name">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="Lastname" DataFormatString="<nobr>{0}</nobr>"
                                        FilterControlAltText="Filter Lastname column" HeaderText="Lastname"
                                        SortExpression="Lastname" UniqueName="Lastname">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="Telephone" DataFormatString="<nobr>{0}</nobr>"
                                        FilterControlAltText="Filter Telephone column" HeaderText="Telephone"
                                        SortExpression="Telephone" UniqueName="Telephone">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="Mobile" DataFormatString="<nobr>{0}</nobr>"
                                        FilterControlAltText="Filter Mobile column" HeaderText="Mobile"
                                        SortExpression="Mobile" UniqueName="Mobile" AutoPostBackOnFilter="False">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="E_Mail" DataFormatString="<nobr>{0}</nobr>"
                                        FilterControlAltText="Filter E_Mail column" HeaderText="E_Mail"
                                        SortExpression="E_Mail" UniqueName="E_Mail">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="Fax" DataFormatString="<nobr>{0}</nobr>"
                                        FilterControlAltText="Filter Fax column" HeaderText="Fax" SortExpression="Fax"
                                        UniqueName="Fax">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="Department" DataFormatString="<nobr>{0}</nobr>"
                                        FilterControlAltText="Filter Department column" HeaderText="Department"
                                        SortExpression="Department" UniqueName="Department">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridBoundColumn DataField="Notification" DataFormatString="<nobr>{0}</nobr>"
                                        FilterControlAltText="Filter Notification column" HeaderText="Notification"
                                        SortExpression="Notification" UniqueName="Notification">
                                    </telerik:GridBoundColumn>
                                    <telerik:GridButtonColumn ButtonType="ImageButton" CommandName="Delete"
                                        Text="Delete" />
                                </Columns>
                                <EditFormSettings>
                                    <EditColumn ButtonType="ImageButton" />
                                </EditFormSettings>
                            </MasterTableView>
                            <ClientSettings>
                                <Selecting AllowRowSelect="True"></Selecting>
                            </ClientSettings>
                        </telerik:RadGrid>

In the SelectedIndexChanged-Event from the DropDownList i have this code:

ContactsGrid.MasterTableView.FilterExpression = "it.CustomerID = " + e.Index;
ContactsGrid.MasterTableView.Rebind();

When i now Change the DropDownList and the Grid is filtered, the paging disappears and i only see the first page wich show 10 records. But there are more than 10 records that match in the filterexpression.

How can i enable the paging again?

Kind regards
Lukas
Princy
Top achievements
Rank 2
 answered on 17 Jan 2014
5 answers
243 views
I created RadPanelItem dynamicly an add a CheckBoxList with this code
// Create a RadPnaleItem and set the Text to SelectionTitle.
RadPanelItem radPanelItemSelection = new RadPanelItem();
radPanelItemSelection.Text = row["SelectionTitle"].ToString();
 
// Expand only the first selection.
if (selectionNumber == 1)
{
    radPanelItemSelection.Expanded = true;
}
else
{
    radPanelItemSelection.Expanded = false;
}
 
// Create anothet RadPanelItem and add the CheckBoxList.
RadPanelItem radPanelItemCheckBoxList = new RadPanelItem();
radPanelItemCheckBoxList.Controls.Add(checkBoxList);
radPanelItemSelection.Items.Add(radPanelItemCheckBoxList);
 
// Add the RadPanelItem to the RadPanelBar.
rpbFilters.Items.Add(radPanelItemSelection);
This piece of code is run inside a loop so that will be more than one RadPanelItem on the RadPanelBar.

I now try to access the CheckBoxList an read them out, but some how I can't get to the CheckBocList's. I have tried different options. Please help

RadPanelItem radPanelItem = rpbFilters.Items[0];
CheckBoxList checkBoxList = (CheckBoxList)radPanelItem.FindControl("cblSelect1");
var radPanelItems = rpbFilters.GetAllItems();
 
foreach (RadPanelItem item in radPanelItems)
{
    RadPanelItem radPanelItem = item.Items[0];
    CheckBoxList checkBoxList = (CheckBoxList)radPanelItem.FindControl("cblSelect1");
}

Anders Pedersen
Shinu
Top achievements
Rank 2
 answered on 17 Jan 2014
5 answers
118 views
Hi All,

I would like to apply changes to multiple columns on ItemDataBound.  I am familiar with:
GridDataItem dataItem = e.Item as GridDataItem;
dataItem["Column_Name"].text = //Apply Formatting here;

Is there anyway to wildcard that?  For example something like "dataItem[*].text " or do I have to do each individual column?

Thanks,
Mark




Shinu
Top achievements
Rank 2
 answered on 17 Jan 2014
5 answers
814 views
Hi, 
 I'm expecting something like raddropdowntree.selectedvalues or similar, but I couldn't find one. And also,is there any way to add items just like regular dropdown, like raddropdowntree.items.add()?

Thanks!
Shinu
Top achievements
Rank 2
 answered on 17 Jan 2014
3 answers
1.0K+ views

I'm getting an error "Conversion from type 'DBNull' to type 'Boolean' is not valid." upon displaying an insert form inside a RadGrid that has two RadButton controls with the ToggleType="Checkbox" that have the Checked property being bound from a database.

<telerik:RadButton ID="RXRequired" runat="server" ForeColor="White"

   
AutoPostBack="false"
ButtonType="ToggleButton" Checked='<%# Bind("RXRequired")%>'

    ToggleType="CheckBox" EnableViewState="true" >

    <ToggleStates>

         <telerik:RadButtonToggleState PrimaryIconCssClass="rbRemove" />

         <telerik:RadButtonToggleState PrimaryIconCssClass="rbOk" Selected="true" />

    </ToggleStates>

</telerik:RadButton>

I have seen numerous posts all over the web regarding DBNull values and checkboxes upon initiating a form insert with the Bind statement. This apparently has been going on for many, many years. This is truly amazing that this is still an issue today, many years later! When the hell is Telerik going to fix this issue with their controls? Come on guys, fix this already!!! This is a real simple thing to do, why should this still be an issue?


This is insane already. FIX IT!!!!!!!!!!!!!!!!!!!!!!

Steve
Top achievements
Rank 1
 answered on 16 Jan 2014
3 answers
187 views
Hi all,

I have a SQL Data Source with three columns for simplicity (Organization_Name, Organization_ID, Organization_Parent_ID).

I am receiving the following error, "This constraint cannot be enabled as not all values have corresponding parent values."  This makes sense as some of the Organization_Parent_ID values are null.  How can I circumvent this error message, showing all of the parent organizations with their children underneath?

It should look something like this:

Organization_A
Organization_B
Organization_C
Organization_D
          Sub_Organization_A
          Sub_Organization_B
Organization_E

I see in the Object Data Source example in this link that there are multiple root level items as well.

Thanks,
Mark




Mark
Top achievements
Rank 1
 answered on 16 Jan 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?