Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
101 views
In editor field, change any font-name other than default font name, then change the font-size. Then we can see the font-name will automatically set to default font name of the browser.
Rumen
Telerik team
 answered on 15 Jun 2011
1 answer
133 views
I am using a radgrid where in the ClientSettings, I have AllowScroll="true" and UseStaticHeaders="true".  This grid is in a user control sitting on a webform that is loaded into a MasterPage content area. There are other user controls loaded on demand within a series of tabs.

 What's happening is that the grid is sizing correctly on the page but the masterpage the first time the user control is accessed.  When another user control is subsequently accessed and then the I switch back to the user control with my RadGrid on it the grid's data section has shrunk down to 10px.  The result is you can not see all of the rows in the grid.  Here is the same markup of the grid element before and after:


<div id="ctl00_TabControl_element_FXProduct_element_view_FXProduct_FXProduct_RadGrid1_GridData" class="rgDataDiv" style="overflow: auto; width: 100%; height: 450px;">
<div id="ctl00_TabControl_element_FXProduct_element_view_FXProduct_FXProduct_RadGrid1_GridData" class="rgDataDiv" style="overflow: auto; width: 100%; height: 10px;">

This issue is only happening when the grid has the AllowScroll="true" client setting set to true.  If it is set to false this issue does not occur.

I am attaching some screen shots to demonstrate the issue.

I am using version 2010.1.415.35 of the rad controls.  This is occurring on both IE 8 and Firefox 3.6 and 4.0.

Here is the markup of my control

<%@ Control Language="C#" AutoEventWireup="true" CodeFile="FXOrderProducts.ascx.cs" Inherits="FXOrderProducts" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<telerik:RadGrid
    ID="RadGrid1"
    runat="server"
    AllowPaging="True" 
    pagesize="100"
    OnRowDrop="RadGrid1_RowDrop"
    OnItemUpdated="RadGrid1_ItemUpdated"
    OnUpdateCommand="RadGrid1_UpdateCommand"
    OnDeleteCommand="RadGrid1_DeleteCommand"
    AllowMultiRowSelection="True"             
    OnItemDataBound = "RadGrid1_OnItemDataBound"
    OnNeedDataSource="RadGrid1_NeedDataSource"
    OnItemCreated="RadGrid1_ItemCreated" 
    OnExcelExportCellFormatting="RadGrid1_ExcelExportCellFormatting"                   
    EnableAJAX = "true"
    Skin="Windows7" Height="450px">
    <MasterTableView DataKeyNames="Id" Width="100%" TableLayout="Fixed" AutoGenerateColumns="False" >
        <NoRecordsTemplate>
            <div style="height: 30px; cursor: pointer;">No products to view</div>
        </NoRecordsTemplate>
        <PagerStyle Mode="NumericPages" PageButtonCount="10" />                    
        <Columns>
            <telerik:GridClientSelectColumn UniqueName="ClientSelectColumn" HeaderStyle-Width="30px"  ItemStyle-Width="30px"  />                    
 
            <telerik:GridBoundColumn DataField="GroupName" HeaderText="Group"
            SortExpression="GroupName" UniqueName="Group" ReadOnly="True" DataFormatString="<nobr>{0}</nobr>" >                   
            </telerik:GridBoundColumn>      
                          
            <telerik:GridBoundColumn DataField="ProductName" HeaderText="Product"
            SortExpression="ProductName" UniqueName="ProductName" ReadOnly="True" DataFormatString="<nobr>{0}</nobr>" >                   
            </telerik:GridBoundColumn>  
                          
            <telerik:GridBoundColumn DataField="Product.Vendor" HeaderText="Mfg."
            SortExpression="Product.Vendor" UniqueName="Vendor" ReadOnly="True" DataFormatString="<nobr>{0}</nobr>"  >                   
            </telerik:GridBoundColumn>                                      
                      
            <telerik:GridBoundColumn DataField="Description" HeaderText="Description"
            SortExpression="Description" UniqueName="Description" ColumnEditorID="GridDescriptionEditor" EditFormColumnIndex="1" ItemStyle-Width="70px" HeaderStyle-Width="70px" DataFormatString="<nobr>{0}</nobr>"   >                   
            </telerik:GridBoundColumn>
                                        
            <telerik:GridBoundColumn DataField="Family" HeaderText="Family"
            SortExpression="Family" UniqueName="Family" ReadOnly="True" DataFormatString="<nobr>{0}</nobr>">                   
            </telerik:GridBoundColumn>                                         
                      
            <telerik:GridBoundColumn DataField="Price" HeaderText="List Price"
            SortExpression="Price" UniqueName="Price" ReadOnly="true" DataFormatString="{0:C}" >  
            </telerik:GridBoundColumn>  
                      
            <telerik:GridBoundColumn DataField="ProductProgram.Program" HeaderText="Program"
            SortExpression="ProductProgram.Program" UniqueName="Program" ReadOnly="True" DataFormatString="<nobr>{0}</nobr>" Display="false">                   
            </telerik:GridBoundColumn>                                                                                                                                                                                 
 
            <telerik:GridBoundColumn DataField="CalculatedPrice" HeaderText="Sell Price"
            SortExpression="CalculatedPrice" UniqueName="CalculatedPrice" DataFormatString="{0:C}" ColumnEditorID="GridSellPriceEditor" EditFormColumnIndex="0" >  
            </telerik:GridBoundColumn>  
                      
            <telerik:GridBoundColumn DataField="Quantity" HeaderText="Qty"
            SortExpression="Quantity" UniqueName="Quantity" ReadOnly="False" ColumnEditorID="GridQuantityEditor" EditFormColumnIndex="0" ItemStyle-Width="40px" HeaderStyle-Width="40px" >  
            </telerik:GridBoundColumn>  
                      
            <telerik:GridBoundColumn DataField="ExtendedPrice" HeaderText="Ext Price"
            SortExpression="ExtendedPrice" UniqueName="ExtendedPrice" ReadOnly="true" DataFormatString="{0:C}" >  
            </telerik:GridBoundColumn>
                      
            <telerik:GridBoundColumn DataField="ProdCost" HeaderText="Cost"
            SortExpression="ProdCost" UniqueName="Cost" DataFormatString="{0:C}" ColumnEditorID="GridCostEditor" EditFormColumnIndex="0">  
            </telerik:GridBoundColumn
                                                       
            <telerik:GridBoundColumn DataField="Margin" HeaderText="Margin"
                SortExpression="Margin" UniqueName="Margin" ReadOnly="True" DataFormatString="{0:C}" Display="false">  
            </telerik:GridBoundColumn>
 
            <telerik:GridBoundColumn DataField="MarginPercent" HeaderText="Margin %"
                SortExpression="MarginPercent" UniqueName="MarginPct" ReadOnly="True" >                   
            </telerik:GridBoundColumn>
 
            <telerik:GridBoundColumn DataField="Product.Status" HeaderText="Status"
                SortExpression="Product.Status" UniqueName="Status" ReadOnly="True" >                   
            </telerik:GridBoundColumn>
                          
            <telerik:GridCheckBoxColumn UniqueName="Optional" DataField="Optional" HeaderText="Opt." ItemStyle-Width="40px" HeaderStyle-Width="40px"  >
            </telerik:GridCheckBoxColumn
 
            <telerik:GridBoundColumn DataField="Optional" HeaderText="Optional"
            SortExpression="Optional" UniqueName="Optional" ReadOnly="True" Visible="false" >                   
            </telerik:GridBoundColumn>
 
            <telerik:GridButtonColumn  CommandName="Delete" Text="Delete" UniqueName="Delete" ConfirmText="Are you sure you want to delete this item?"
            HeaderStyle-Width="35px" ButtonType="ImageButton" ImageUrl="~/Images/Icons/Power2Order/Delete_16x16.png">
            </telerik:GridButtonColumn>
        </Columns
        <EditFormSettings UserControlName="SmartParts/SalesOrder/FXEditProduct.ascx" EditFormType="WebUserControl"
            <EditColumn UniqueName="EditCommandColumn1">
            </EditColumn>                 
        </EditFormSettings>
    </MasterTableView>
    <ClientSettings
        AllowRowsDragDrop="True" 
        EnableRowHoverStyle="true">
        <Selecting
            AllowRowSelect="true"
            EnableDragToSelectRows="false" />
        <Scrolling
            AllowScroll="true"
            UseStaticHeaders="true" />
        <ClientEvents
            OnRowDropping="onRowDropping"
            OnRowDblClick="GridRowDblClick"
            OnGridCreated="GridCreated" />   
        <Resizing
            EnableRealTimeResize="True"
            ResizeGridOnColumnResize="False"
            AllowColumnResize="True" />                                    
    </ClientSettings>
</telerik:RadGrid>
Maria Ilieva
Telerik team
 answered on 15 Jun 2011
10 answers
131 views
Need a little help here...I have a page within Sitefinity that is made up of 2 user controls. UserControl1 is the left half of the page, UserControl2 is the right side of the page. Each of these user controls have a RadGrid in them that open automatically in edit mode for a single record. I need to create a button inside UserControl2 that fires off the Update command for both RadGrids and then reloads the page so that both grids will return to edit mode with the new values.

Can you tell me what the code behind would look like for that button to reference and fire off the update command on those grids inside the user controls? Thanks for the assistance.
KARAN
Top achievements
Rank 1
 answered on 15 Jun 2011
1 answer
66 views
Hi, 

i am working on grid population at client side by page methods. i am using like this

PageMethods.GetData(currentPageIndex * pageSize, pageSize, sortExpressionsAsSQL, filterExpressions.toList(), updateGrid);

updateGrid is a client side method in which i bind the resultset to grid. in item command some time it goes into updategrid method and sometimes not i donot know why when i click on page button. 

plz help

Regards,


Faisal
Tsvetina
Telerik team
 answered on 15 Jun 2011
1 answer
72 views

I dynamically bind radgrid delete ,
Binding like that ,
confirmation message all the things come
GridButtonColumn btncol = new GridButtonColumn();
 this.RadGrid1.MasterTableView.Columns.Add(btncol);
 btncol.ButtonType = GridButtonColumnType.ImageButton;
 btncol.HeaderStyle.Width = 10;
 btncol.CommandName = "Delete";
 btncol.Text = "delete";
 btncol.UniqueName = "DeleteColumn";
 btncol.CommandArgument = "Child";
 btncol.ConfirmDialogType = GridConfirmDialogType.RadWindow;
 btncol.ConfirmText = "Are You Sure Want To Delete This Record?";
 btncol.ConfirmTitle = "Delete Confirm";

Error Come Like when i click ok button confirm Dialog

 Sys.WebForms.PageRequestManagerServerErrorException: Invalid postback or callback argument.  Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page.  For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them.  If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.

Replay soon Very Urgent
Waiting For Ur replay

Thanks,
Mohamed.
Iana Tsolova
Telerik team
 answered on 15 Jun 2011
1 answer
115 views
Hi,

I get the problem shown in the attached image with Window XP and IE7. It works fine otherwise. Can anyone identify the cause? I have put the html of the user control containing the list box below.

Thanks.

<%@ Assembly Name="SIMS.UI.UserControls, Version=1.0.0.0, Culture=neutral, PublicKeyToken=bc6fb793b8a12a45" %>
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="MaintainUserPermissions.ascx.cs"
    Inherits="SIMS.UI.UserControls.Security.MaintainUserPermissions" EnableViewState="true" %>
<%@ Register TagPrefix="sims" TagName="DisplayMessageControl" Src="~/_Layouts/SIMSControls/Common/UserControls/DisplayMessageControl.ascx" %>
<%@ Register TagPrefix="sims" TagName="MessagePrompt" Src="~/_Layouts/SIMSControls/Common/UserControls/MessagePromptControl.ascx" %>
<asp:ScriptManagerProxy ID="maintainUserPermissionsScriptManagerProxy" runat="server" />
<div>
    <asp:Panel ID="pnlUserPermissionsContainer" runat="server">
        <asp:UpdatePanel ID="mainUpdatePanel" runat="server" UpdateMode="Conditional">
            <ContentTemplate>
                <asp:HiddenField ID="hfSiteRoleUserData" runat="server" />
                <asp:HiddenField ID="hfSiteModuleData" runat="server" />
                <asp:HiddenField ID="hfModuleRoleData" runat="server" />
                <asp:Panel ID="pnlMessageControl" runat="server" Visible="false">
                    <sims:DisplayMessageControl ID="dmcMessageControl" runat="server" Visible="false" />
                </asp:Panel>
                <table width="100%">
                    <tr>
                        <td style="width: 25%; vertical-align: top">
                            <asp:Label ID="lblUsers" CssClass="label" Text="Users" runat="server" /><br />
                            <div class="rlbDiv">
                                <telerik:RadListBox Width="100%" ID="rlbUsers" runat="server" CheckBoxes="true" Skin=""
                                    OnClientSelectedIndexChanged="SelectedUserChanged" OnClientItemChecked="UserChecked" />
                            </div>
                        </td>
                        <td style="width: 25%; vertical-align: top">
                            <asp:Label ID="lblAgencies" CssClass="label" Text="Agencies" runat="server" /><br />
                            <div class="rlbDiv">
                                <telerik:RadListBox Width="100%" ID="rlbAgencies" runat="server" CheckBoxes="true"
                                    Skin="" OnClientSelectedIndexChanged="SelectedAgencyChanged" OnClientItemChecked="AgencyChecked" />
                            </div>
                        </td>
                        <td style="width: 25%; vertical-align: top">
                            <asp:Label ID="lblModules" CssClass="label" Text="Modules" runat="server" /><br />
                            <div class="rlbDiv">
                                <telerik:RadListBox Width="100%" ID="rlbModules" runat="server" CheckBoxes="true"
                                    Skin="" OnClientSelectedIndexChanged="SelectedModuleChanged" OnClientItemChecked="ModuleChecked" />
                            </div>
                        </td>
                        <td style="width: 25%; vertical-align: top">
                            <asp:Label ID="lblRoles" CssClass="label" Text="Roles" runat="server" /><br />
                            <div class="rlbDiv">
                                <telerik:RadListBox Width="100%" ID="rlbRoles" runat="server" CheckBoxes="true" Skin=""
                                    OnClientItemChecked="RoleChecked" />
                            </div>
                        </td>
                    </tr>
                     <tr>
                        <td style="width:25%; vertical-align: top">
                            <table style="width:100%; vertical-align: top">
                                <tr>
                                    <td>
                                        <asp:TextBox ID="txtUserFilter" runat="server" Text="Search..." ForeColor="Gray" onblur="WaterMark(this, event);" onfocus="WaterMark(this, event);" CssClass="rlbTextbox" />
                                    </td>
                                    <td style="width:5%">
                                        <asp:ImageButton ID="btnUserSearch" runat="server" AlternateText="Search..." CommandName="UserSearch" CssClass="button" />
                                    </td>
                                </tr>
                            </table>
                        </td>
                        <td style="width:25%; vertical-align: top">
                            <table style="width:100%; vertical-align: top">
                                <tr>
                                    <td>
                                        <asp:TextBox ID="txtAgencyFilter" runat="server" Text="Search..." ForeColor="Gray" onblur="WaterMark(this, event);" onfocus="WaterMark(this, event);" CssClass="rlbTextbox" />
                                    </td>
                                    <td style="width:5%">
                                        <asp:ImageButton ID="btnAgencySearch" runat="server" AlternateText="Search..." CommandName="AgencySearch" CssClass="button" />
                                    </td>
                                </tr>
                            </table>
                        </td>
                        <td></td>
                        <td></td>
                    </tr>
                </table>
                <table width="100%">
                    <tr>
                        <%--                        <td style="width:50%; vertical-align: top;">
                            <div align="left">
                                <asp:Button ID="btnUserDetails" runat="server" Text="User Details" CommandName="Details" CssClass="button" />
                            </div>
                        </td>--%>
                        <td style="width: 100%; vertical-align: top">
                            <div align="right">
                                <asp:Button ID="btnSave" runat="server" Text="Save" CommandName="Save" CssClass="button" />
                                <asp:Button ID="btnCancel" runat="server" Text="Cancel" CommandName="Cancel" CssClass="button" />
                                <asp:Button ID="btnDummy" runat="server" CssClass="button" Style="display: none" />
                            </div>
                        </td>
                    </tr>
                </table>
                <div style="position: fixed; top: 0px; left: 0px;">
                    <ajax:ModalPopupExtender ID="mpeDeleteConfirmMessagePrompt" runat="server" TargetControlID="btnDummy"
                        PopupControlID="pnlDeleteConfirmMessagePrompt" BackgroundCssClass="modalBackground"
                        BehaviorID="mpeDeleteConfirmMessagePrompt" />
                    <asp:Panel ID="pnlDeleteConfirmMessagePrompt" CssClass="modalPopup" Style="display: none;
                        width: auto" runat="server">
                        <asp:UpdatePanel ID="pnlDeleteMessagePrompt" runat="server" RenderMode="Inline">
                            <ContentTemplate>
                                <sims:MessagePrompt ID="ucDeleteConfirmMessagePrompt" MessageText="Are you sure you wish to remove all roles for this user, agency and module?"
                                    runat="server" PopupControlID="mpeDeleteConfirmMessagePrompt" ActionText="Yes"
                                    ActionCommandName="Yes" CancelText="No" CancelCommandName="No" />
                            </ContentTemplate>
                        </asp:UpdatePanel>
                    </asp:Panel>
                    <ajax:ModalPopupExtender ID="mpeAgencyDeleteConfirmMessagePrompt" runat="server"
                        TargetControlID="btnDummy" PopupControlID="pnlAgencyDeleteConfirmMessagePrompt"
                        BackgroundCssClass="modalBackground" BehaviorID="mpeAgencyDeleteConfirmMessagePrompt" />
                    <asp:Panel ID="pnlAgencyDeleteConfirmMessagePrompt" CssClass="modalPopup" Style="display: none;
                        width: auto" runat="server">
                        <asp:UpdatePanel ID="pnlAgencyDeleteMessagePrompt" runat="server" RenderMode="Inline">
                            <ContentTemplate>
                                <sims:MessagePrompt ID="ucAgencyDeleteConfirmMessagePrompt" MessageText="Are you sure you wish to remove all permissions for this user and agency?"
                                    runat="server" PopupControlID="mpeAgencyDeleteConfirmMessagePrompt" ActionText="Yes"
                                    ActionCommandName="Yes" CancelText="No" CancelCommandName="No" />
                            </ContentTemplate>
                        </asp:UpdatePanel>
                    </asp:Panel>
                    <ajax:ModalPopupExtender ID="mpeUserDeleteConfirmMessagePrompt" runat="server" TargetControlID="btnDummy"
                        PopupControlID="pnlUserDeleteConfirmMessagePrompt" BackgroundCssClass="modalBackground"
                        BehaviorID="mpeUserDeleteConfirmMessagePrompt" />
                    <asp:Panel ID="pnlUserDeleteConfirmMessagePrompt" CssClass="modalPopup" Style="display: none;
                        width: auto" runat="server">
                        <asp:UpdatePanel ID="pnlUserDeleteMessagePrompt" runat="server" RenderMode="Inline">
                            <ContentTemplate>
                                <sims:MessagePrompt ID="ucUserDeleteConfirmMessagePrompt" MessageText="Are you sure you wish to remove all permissions for this user?"
                                    runat="server" PopupControlID="mpeUserDeleteConfirmMessagePrompt" ActionText="Yes"
                                    ActionCommandName="Yes" CancelText="No" CancelCommandName="No" />
                            </ContentTemplate>
                        </asp:UpdatePanel>
                    </asp:Panel>
                </div>
            </ContentTemplate>
        </asp:UpdatePanel>
    </asp:Panel>
</div>
Genady Sergeev
Telerik team
 answered on 15 Jun 2011
2 answers
104 views
I'd like to customize the text displayed by the GridHTMLEditorColumnEditor ; I tried that but the content remains empty (the resourceValue column is bound only in the ItemDataBound event):

protected void RadGrid1_ItemCreated(object sender, GridItemEventArgs e)
        {
            if (e.Item is GridEditableItem && e.Item.IsInEditMode)
            {
                GridEditableItem editedItem = e.Item as GridEditableItem;
                GridHTMLEditorColumnEditor editor = (GridHTMLEditorColumnEditor)editedItem.EditManager.GetColumnEditor("resourceValue");
                 editor.Editor.Content = "my custom text";             
            }
        }

jc mag
Top achievements
Rank 1
 answered on 15 Jun 2011
1 answer
66 views

Hi Team,

 

We are using Telerik ASP.net Ajax with 2010.1.415.0 build.

While testing on Firefox 4 (build 4.0.1) we are facing a problem in editor when image in editor is selected and click on image map Editor Button. Image map Editor get open but it does not show image in ‘Preview’ section.

Could you please let us know any workaround to resolve the same?


Thank you in advance.
Rumen
Telerik team
 answered on 15 Jun 2011
2 answers
113 views

Hello,

when i load my page, all the pageviews are displayed. I need to click on each tab to obtain the normal display (only the selected pageview).
I precise that it works great on FF but not on IE8

Have you an idea ?
Aurore


Here's the schema of my architecture :
<tlk:RadPane ID="m_oTopPane" runat="server" Scrolling="Both" PanesBorderSize="0">
                <asp:Panel ID="ConfPanel" runat="server" Style="visibility: hidden;">                  
                    <tlk:RadTabStrip ID="m_oRadStrip" runat="server" MultiPageID="RadMultiPage1" Orientation="HorizontalTop"
                        SelectedIndex="0" Width="840" Style="margin-left: 10px;" >
                        <Tabs>
                            <tlk:RadTab runat="server">
                            </tlk:RadTab>
                            <tlk:RadTab runat="server">
                            </tlk:RadTab>
                            <tlk:RadTab runat="server">
                            </tlk:RadTab>
                        </Tabs>
                    </tlk:RadTabStrip>
                    <tlk:RadMultiPage ID="RadMultiPage1" runat="server" SelectedIndex="0" >
      <tlk:RadPageView ...>
      </tlk:RadPageView/>
 <tlk:RadPageView ...>
      </tlk:RadPageView/>
 <tlk:RadPageView ...>
      </tlk:RadPageView/>
</tlk:RadMultiPage>
</tlk:RadTabStrip>
<asp:Panel>
</tlk:RadPane>

I set this on web.config
        <add key="Telerik.Skin" value="Sphinx"/>
        <add key="Telerik.EnableEmbeddedSkins" value="false"/>

I use the 2010.3.1317.35 dll version
Dimitar Terziev
Telerik team
 answered on 15 Jun 2011
5 answers
68 views
Hello,

my trees are very dynamic an so it takes a lot of time to generate them node by node,
level by level.

So my Question is, if it is possible to return a complete part of a tree with all its subnotes in one step.
I think I've to return a Treenode-object not a TreenodeData-object. Have'nt I?

Best regards.
Nikolay Tsenkov
Telerik team
 answered on 15 Jun 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?