Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
121 views
Hi,

Using the editor both within our product and also on your online demos, if you view the page using IE10 in compatibility view some of the icons on the toolbars fail to load. If this is fine first time, try changing the skin to something else like Default. If you switch out of compatibility view, this resolves itself. By default IE is in compatibility view when viewing a website on a local intranet and this is causing us some issues.

Can you explain why this is happening and why this is only affecting some icons? We have tried using a meta tag to force IE10 out of compatibility view but this have no effect any more. Do you have a solution?

Thanks

Rob
Bozhidar
Telerik team
 answered on 26 Sep 2013
3 answers
250 views
Hi,
i bind my RadGrid to an EntityDataSource.
First i want fill it with a where statement.
In T-SQL like so:  Select Status,Cti,CreatedDate from Table1 where CreatedUser = @LoggedInUser
This works fine. But when i want to filter some columns i get this error
AutoGenerateWhereClause can not be 'true', if Where is defined
My EntityDatasource look like so
<asp:EntityDataSource ID="EntityDataSource1" runat="server" ConnectionString="name=TestEntities"
    DefaultContainerName="TestEntities" EntitySetName="Table1" OrderBy="it.CreatedDate DESC"
    Select="it.[Status], it.[CreatedDate], it.[CTI]"  AutoGenerateWhereClause="True"
    Where="it.CreatedUser = @LoggedInUser">
    <WhereParameters>
        <asp:Parameter DefaultValue="Test\User1" Name="CreatedUser" DbType="String" />
    </WhereParameters>
</asp:EntityDataSource>
How can i achive this. Fill Grid with where statement and also filtering should work
Thanks
Yunuen Sanchez
Top achievements
Rank 1
 answered on 26 Sep 2013
1 answer
141 views

as refer to another post for adding a checkbox in groupheader,

http://www.telerik.com/community/forums/aspnet-ajax/general-discussions/radgrid-checkbox-for-specific-group.aspx

i had implemented the code from

https://github.com/telerik/aspnet-sdk/tree/master/Grid/GroupingAndSelection

it works fine that it can select all child checkbox when click groupheader checkbox.
but i found that the groupheader checkbox cannot deselect after click. i had gone through the code many time but cannot solve it.

Thanks.

<script type="text/javascript" language="javascript" >
    function Clicked(strKey) {
        alert(strKey);
    }
 
 
    var tree = {
        isRoot: true
    },
           treePositionsCache = {};
 
    // The idea is to build a tree in which every node has a relation to it's parent group item
    function GridCreated(sender, args) {
        var rows = sender.get_masterTableView().get_element().rows,
               currentRow,
               currentNode = tree,
               shouldGoUpOneLevel = false,
               groupLevel = 1;
        //Builds the tree
        for (var i = 0; i < rows.length; i++) {
            currentRow = rows[i];
            if (currentRow.parentNode.tagName.toLowerCase() === "tbody") {
                //The row is a group header row
                if (currentRow.className.indexOf("rgGroupHeader") !== -1) {
                    //Finds the parent node of the current node
                    if (shouldGoUpOneLevel) {
                        for (var j = 0; j < groupLevel - $telerik.getElementsByClassName(currentRow, "rgGroupCol").length + 1; j++) {
                            currentNode = currentNode.parent;
                        }
                    }
                    //Determines the group level
                    groupLevel = $telerik.getElementsByClassName(currentRow, "rgGroupCol").length;
                    currentNode.numberOfItems++;
                    currentNode = currentNode[i] = {
                        //Sets the parent reference
                        parent: currentNode,
                        //Sets the checkbox reference
                        checkbox: $telerik.findElement(currentRow, "ClientSelectColumnSelectCheckBox") ||
                               $telerik.findElement(currentRow, "GroupHeaderCheckBox"),
                        numberOfItems: 0,
                        numberOfCheckedItems: 0
                    };
                } else {
                    // The row is a GridDataItem
                    shouldGoUpOneLevel = true;
                    // Increase the number of item that the parent has.
                    currentNode.numberOfItems++;
                    //If the item is selected mark it as one.
                    if (currentRow.className.indexOf("rgSelectedRow") !== -1) {
                        currentNode.numberOfCheckedItems++;
                    }
                }
                //Add the node to the tree
                treePositionsCache[i] = currentNode;
            }
        }
    }
 
 
    function RowSelected(sender, args) {
        PerformSelect(treePositionsCache[$get(args.get_id()).rowIndex]);
    }
 
    function RowDeselected(sender, args) {
        PerformDeselect(treePositionsCache[$get(args.get_id()).rowIndex], true);
    }
 
    //Recursively traverse the tree and deselect the check boxes
    function PerformDeselect(node, firstCall) {
        if (--node.numberOfCheckedItems !== node.numberOfItems && !node.isRoot && node.checkbox.checked) {
            node.checkbox.checked = false;
            PerformDeselect(node.parent, false);
        }
    }
 
    //Recursively traverse the tree and select the check boxes
    function PerformSelect(node) {
        if (++node.numberOfCheckedItems === node.numberOfItems) {
            node.checkbox.checked = true;
            PerformSelect(node.parent);
        }
    }
 
    //Called when a group header check box is checked or unchecked
    function GroupToggleSelection(sender) {
        //Finds the row
        var row = Telerik.Web.UI.Grid.GetFirstParentByTagName(sender, "tr"),
        //Obtains the row index
               rowIndex = row.rowIndex,
        //Determines the group level
               level = $telerik.getElementsByClassName(row, "rgGroupCol").length,
               masterTable = $find('<%=RadGrid1.ClientID%>').get_masterTableView(),
               rows = masterTable.get_element().rows,
               isChecked = sender.checked;
        sender.checked = !sender.checkbox;
 
        //Traverses the rows from the current header down and selects or deselects the GridDataItems
        for (var i = rowIndex + 1; i < rows.length; i++) {
            //If we encounter a grop header with the same group level we stop the selection/deselection
            if (rows[i].className.indexOf("rgGroupHeader") !== -1) {
                if ($telerik.getElementsByClassName(rows[i], "rgGroupCol").length === level) {
                    break;
                }
            } else if (isChecked) {
                masterTable.selectItem(rows[i]);
            } else {
                masterTable.deselectItem(rows[i]);
            }
        }
    }
 
   </script>


<telerik:RadGrid ID="RadGrid1" runat="server" DataSourceID="ldsPayrollFlow" AllowMultiRowSelection="True"
                GridLines="None" Width="960px" AllowSorting="True"
        AutoGenerateColumns="False" AllowFilteringByColumn="True"
                AllowPaging="True" PageSize="15" EnableAJAX="true"
        EnableAJAXLoadingTemplate="true" LoadingTemplateTransparency="25"
        CellSpacing="0">
 
                <PagerStyle Mode="NumericPages"></PagerStyle>
              
                <MasterTableView DataSourceID="ldsPayrollFlow" DataKeyNames="SID" GroupLoadMode="Client">
                    <CommandItemSettings ExportToPdfText="Export to Pdf"></CommandItemSettings>
                    <RowIndicatorColumn>
                        <HeaderStyle Width="10px"></HeaderStyle>
                    </RowIndicatorColumn>
                    <ExpandCollapseColumn>
                        <HeaderStyle Width="10px"></HeaderStyle>
                    </ExpandCollapseColumn>
 
                    <GroupByExpressions>                                              
                    <telerik:GridGroupByExpression>
                        <SelectFields>
                            <telerik:GridGroupByField FieldAlias="DisplayName" FieldName="DisplayName" HeaderText="Staff Name"></telerik:GridGroupByField>
                        </SelectFields>
                        <GroupByFields>
                            <telerik:GridGroupByField FieldName="DisplayName" ></telerik:GridGroupByField>
                        </GroupByFields>                        
                        </telerik:GridGroupByExpression>
 
                    </GroupByExpressions>
                    <GroupHeaderTemplate>
                            <asp:CheckBox ToggleType="CheckBox" ID="GroupHeaderCheckBox" OnClick="GroupToggleSelection(this);" runat="server"></asp:CheckBox>
                    </GroupHeaderTemplate>
 
                    <Columns>
                            <telerik:GridClientSelectColumn UniqueName="ClientSelectColumn" Visible="TRUE" HeaderStyle-Width="10" Display="false">
                            </telerik:GridClientSelectColumn>
                        <telerik:GridBoundColumn DataField="SID" HeaderText="SID" ReadOnly="True"
                            SortExpression="SID" UniqueName="SID" Visible=false>
                        </telerik:GridBoundColumn>

Joe
Top achievements
Rank 1
 answered on 26 Sep 2013
7 answers
122 views
Iam Facing issue(creating dynamic column with filtertemplate in radcomboboxes in rad grid )
  
We are using radgrid.We are generating dynamic columns with combobox in filter template .We are generating Column dynamically.
  
Issue is Combobox selected changed event is not woring. 
  
i am doing this programmatically using ITEMPLATE interface by inheriting in a class and calling InstantiateIn method using Creating combox control.
Naga
Top achievements
Rank 1
 answered on 26 Sep 2013
3 answers
212 views
Hi, 
I want to call a javascript function when user clicks hierarchy expand button. my hierarchyloadmode = serverondemand and i don't want to change to  hierarchyloadmode = client because i takes very long time to load radgrid. in addition my telerik version doesn't support HierarchyLoadMode.Conditional

is there any solution? 
Kostadin
Telerik team
 answered on 26 Sep 2013
3 answers
175 views
Click on the same date two times gives NULL value second time.
How do I get away with it, so I get the same value even if I click the same date more than once?

Try: http://demos.telerik.com/aspnet-ajax/calendar/examples/programming/serversideevents/defaultcs.aspx
Changed Date to: "9/30/2013 12:00:00 AM"
Changed Date to: "none"
Shinu
Top achievements
Rank 2
 answered on 26 Sep 2013
4 answers
139 views
how can i have a grid with a image collumn binded image from database
Jayesh Goyani
Top achievements
Rank 2
 answered on 26 Sep 2013
6 answers
225 views
I am using RadSchduler, In which before using UpdatePanel, onappointmentcommand works well. But when I use UpdatePanel it never calls the event (when I insert / cancel) an Appointment. 
 
Any kind of help is fine. 
 
Following is the code I am using 
 
 <asp:UpdatePanel ID="UpdatePanel1" runat="server">
          <ContentTemplate><telerik:RadScheduler ID="RadScheduler1" runat="server"
      SelectedView="MonthView" Skin="WebBlue"
      onappointmentcommand="RadScheduler1_AppointmentCommand1"
       onload="RadScheduler1_Load" DataKeyField="ID" DataSubjectField="Subject"
      DataStartField="Start" DataEndField="End"
      onappointmentdelete="RadScheduler1_AppointmentDelete" AllowEdit="false" Height="600px">
 
        <InlineInsertTemplate>
            <asp:DropDownList runat="server" ID="ddlAgenTeamLst" DataSourceID="objTeam" DataTextField="name" DataValueField="id"></asp:DropDownList>
            <asp:Button ID="btnInsert" runat="server" CommandName="Insert" Text="Insert"/>
            <asp:Button ID="btnCancel" runat="server" CommandName="Cancel" Text="Cancel"/>
        </InlineInsertTemplate>
</telerik:RadScheduler></ContentTemplate>  </asp:UpdatePanel>
 
In the above onAppointmentDelete is working fine in both the cases. But I need to get the value from the drop down list when I Insert a data, So i am unable to use "OnAppointmentInsert".
Mohan Prasath
Top achievements
Rank 1
 answered on 26 Sep 2013
2 answers
162 views
Hi,
In my functionality I am adding some appointments(data) in the back end based if one specific appointment is added. (through UI). I am here using RadScheduler1_AppointmentCommand method to Insert the appointments. But even if I use Rebind or DataBind , the newly added appointment are not reflected in the UI. Only one appointment(that is included through UI) is displayed. So what should I have to do to update the new changes?

Note: I am using Scheduler inside UpdatePanel
Mohan Prasath
Top achievements
Rank 1
 answered on 26 Sep 2013
3 answers
138 views
Hi support Telerik,
I have the problem as following :
- I use Telerik.Web.UI dll version 2011.2.915.35 and use RadAjaxManager and RadAjaxLoadingPanel to run Ajax.
- I have a button when click this button then it will run Ajax
The first time I click button it seem run everything ok, but the second time I click button then I see an issue javascrippt error as following:
  Object doesn't support this property or method at code line : if($telerik.$(b).css("filter").indexOf("opacity")!=-1||$telerik.$(b.firstChild.nextSibling).css("filter").indexOf("opacity")!=-1)
My environment use IE8 with https and windows server 2008. Please hepl me resolve this issue ?
Thank you so much.
John Avata.
Pavlina
Telerik team
 answered on 25 Sep 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?