Telerik Forums
UI for ASP.NET AJAX Forum
5 answers
441 views
Hello,

we have a limitation that requires us to use the ContentAreaMode="DIV" on our project.

The issue we have is that, at the moment, we would like to strip word formatting.
What we did until now is to strip manually tags on server side, as we could not make the StripFormattingOnPaste work in this mode.

As our users saw recently the demo on the site, they would like to have it done client side. Our issue is show here:

<telerik:RadEditor runat="server" 
    StripFormattingOnPaste="All" ContentAreaMode="DIV" ID="RadEditor1">
    <Content>
    </Content>
</telerik:RadEditor>

With this code, removing ContentAreaMode does make the Stripping work

Is there any workaround ?

Best regards

Philippe
skhalidi
Top achievements
Rank 1
 answered on 14 Feb 2013
2 answers
354 views

I am using radgrid very similar to the one on telerik sample here:
http://demos.telerik.com/aspnet-ajax/grid/examples/overview/defaultcs.aspx

Problem is, earlier selected sub items are not cleared when new sub item are selected. Which gives the user the impression that multiple items arte selected which is not the case.

How can I clear the first main and sub-items selected when new sub items are directly selected?
Dele
Top achievements
Rank 1
 answered on 13 Feb 2013
7 answers
255 views
Is the anything planned to allow for a header and footer in the drop down template? Or is there a way to implement such a feature with the current build?
Mark Kucera
Top achievements
Rank 1
 answered on 13 Feb 2013
4 answers
885 views
Hello, I have an issue with the sort expression feature in the RadGrid.
As said in several post, i'm using the advanced databinding with NeedDataSource to make the sorting works correctly.

This is my grid definitions:
<telerik:RadGrid ID="MyRadGrid" runat="server"
 AllowSorting="true"
 EnableHeaderContextMenu="true"
 Width="900px"
 CssClass="RadGridCustomClass">
                 
  <ClientSettings AllowColumnsReorder="true"
    ReorderColumnsOnClient="true"
    ColumnsReorderMethod="Reorder"
    AllowColumnHide="true" >
      <Resizing AllowColumnResize="true"
        EnableRealTimeResize="true"
        ResizeGridOnColumnResize="true"
        ClipCellContentOnResize="true"
        AllowRowResize="false" />
 </ClientSettings>
             
  <HeaderContextMenu EnableRoundedCorners="true"
    EnableShadows="true"
    OnItemClick="MyRadGrid_HeaderContextMenuClick" />
             
  <MasterTableView AllowMultiColumnSorting="false" 
    AllowCustomSorting="true"
    AllowCustomPaging="true"
    TableLayout="Fixed"
    AutoGenerateColumns="false"
    EnableHeaderContextMenu="true"
    EnableViewState="false" >
    
  <Columns>
    <telerik:GridBoundColumn DataField="ID"
      SortExpression="ID" HeaderText="ID"
      DataType="System.Int32" />
    <telerik:GridBoundColumn DataField="Name"
      SortExpression="Name" HeaderText="Name"
      DataType="System.String" />
    <telerik:GridNumericColumn DataField="UnitPrice" 
      SortExpression="UnitPrice" HeaderText="Unit price"
      DataType="System.Decimal" />
    <telerik:GridBoundColumn DataField="Date"
      SortExpression="Date" DataFormatString="{0:d}" HeaderText="Date"
      DataType="System.DateTime" />
    <telerik:GridCheckBoxColumn DataField="Discontinued"
      SortExpression="Discontinued" HeaderText="Discontinued"
      DataType="System.Boolean" />
  </Columns>
</MasterTableView>
</telerik:RadGrid>

 Pretty simple grid with simple data i load from a list for this test purpose.
On load, i check if the dataSource is nothing, then call Rebind() to call NeedDataSource()
Once its called, i bind my grid with data.

I got this on load....
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
  If MyRadGrid.DataSource Is Nothing Then
    MyRadGrid.Rebind()
  End If
End Sub
 
Private Sub MyRadGrid_NeedDataSource(ByVal sender As Object, ByVal e As Telerik.Web.UI.GridNeedDataSourceEventArgs) Handles MyRadGrid.NeedDataSource
  Dim list2 As New List(Of MyBusinessObject)()
  For j As Integer = 0 To 5
    Dim Product1 As New MyBusinessObject()'Some local data
    Product1.ID = j
    Product1.Name = names(j)
    Product1.UnitPrice = prizes(j)
    Product1.[Date] = dates(j)
    Product1.Discontinued = bools(j)
    list2.Add(Product1)
  Next
  MyRadGrid.DataSource = list2
End Sub
 
Public Sub MyRadGrid_HeaderContextMenuClick(ByVal sender As Object, ByVal e As RadMenuEventArgs)
  If e.Item.Value <> "SortAsc" And e.Item.Value <> "SortDesc" Then
    MyRadGrid.MasterTableView.SortExpressions.Clear()
  End If
  MyRadGrid.Rebind() 'i tried MyRadGrid.MasterTableView.Rebind()
End Sub


The sorting doesnt work well, so i use the HeaderContextMenuClick event to output what's going on...
So my grid has the expression it needs, but the sorting doesnt occur.

So i placed a couple of debug.print... Here what i get after click on "sort asc" on "Unit price" column:
******************************Page load
Page load() data source is nothing... Calling MyRadGrid.Rebind()
MyRadGrid_NeedDataSource()
******************************Page load
Page load() data source is nothing... Calling MyRadGrid.Rebind()
MyRadGrid_NeedDataSource()
'WebDev.WebServer.EXE' (Managed): Loaded 'D:\WINDOWS\assembly\GAC_MSIL\Microsoft.VisualBasic\8.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualBasic.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
MyRadGrid_HeaderContextMenuClick() SORT EXPRESSION: Name:UnitPrice Order:Ascending
MyRadGrid_HeaderContextMenuClick() Calling MyRadGrid.Rebind()


Rebind is supposed to call NeedDataSource right? I tried to call MyRadGrid.datasource manualy... but still no result, the grid wont sort.
Plus, i get a empty button (5-8pixel width, 2-3 pixels height) beside the header text after i call Clear sorting.. this happens only in my test, not my project.

I have no idea why this isnt working. Can anyone help me?
Thanks!
Sophie
Top achievements
Rank 2
 answered on 13 Feb 2013
1 answer
88 views
i define a user controls inside other user control and define a 
RadScriptBlock,place script code in it,but script block dont fire.please
 help me.
my code is:

<telerik:RadScriptBlock
ID="RadScriptBlock1" runat="server"> <script type="text/javascript" language="javascript"> function refreshGrid(arg) { alert("1234"); $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("Rebind"); } function RowDblClick(sender, eventArgs) { window.radopen("Details.aspx?codemessage=" + eventArgs.getDataKeyValue("codeadvertisment"), "UserListDialog"); } function OpenFileExplorerDialog() { var wnd = $find("<%= ExplorerWindow.ClientID %>"); wnd.show(); } //This function is called from the Explorer.aspx page function OnFileSelected(wnd, fileSelected) { var textbox = $get("<%= UploadPicture.ClientID %>"); textbox.value = fileSelected; } function ShowMessage(sender, args) { var id = args.getDataKeyValue("codeadvertisment"); var wnd = window.radopen("Details.aspx?codemessage=" + id, null); //Get the clicked row var index = args.get_itemIndexHierarchical(); var item = args.get_tableView().get_dataItems()[index]; var rowElement = item.get_element(); //Get coordinates of the row and reposition the window relative to it var bounds = $telerik.getBounds(rowElement); wnd.moveTo(bounds.x + 120 + index * 10, bounds.y - 180); } </script> </telerik:RadScriptBlock>
MasterChiefMasterChef
Top achievements
Rank 2
 answered on 13 Feb 2013
1 answer
125 views
I have a textbox and a button inside an RadAjaxPanel. When I click the button RadAjaxLoadingPanel is displayed and button click event is fired. But now I want to display a confirmation message that button was clicked or just display any message after RadAjaxLoadingPanel stops.

MasterChiefMasterChef
Top achievements
Rank 2
 answered on 13 Feb 2013
7 answers
162 views
I have a RadGrid that contains 31 columns of various data types and widths. I have the width set to 98% so that it shows the horizontal scroll bar and it's working as expected in IE. But in Firefox the horizontal scroll bar is far too wide, even wider than the screen itself, and the grid extends far beyond the edge of the page. If I try to scroll to the right side of the grid the scroll bar hits the right side before the last column comes into view; so it's impossible to see the last few columns in the grid.

The grid is also inside a panel, not sure if that could be a factor; but the application has many grids inside panels and I'm only seeing it on this one page. Any help would be greatly appreciated.

Thanks
Shane
Shane
Top achievements
Rank 1
 answered on 13 Feb 2013
1 answer
94 views
Hi

We use the scheduler and use resource grouping.
Our resourceType is named "employee". When i use this in the DayView - Groupby="employee" this works ok.
Same in the weekview (Grouby = "employee").

But when i want to group together with date this works in the dayview but not in the weekview. 
So our groupby is then :  Groupby=  "Date,employee" 

It rans on jscript error =  this._weekmodels[h.modelIndex].addToBlock(h).
the modelindex is "undefined".
Any idea's howto solve this issue ?

Some information :
ResourcePopulationMode="ServerSide" , resources are added in Page_Load  (but i tried also the manual, clientside)..
-  Appointments are retrieved from Webservice.

I have added an screenshot where the jscript fails.

Regards,
Peter
Boyan Dimitrov
Telerik team
 answered on 13 Feb 2013
1 answer
203 views

please check the below screen shot , i applied Edititemtemplate css but this is not working it is taking fixed width as 160px   how to set this grid as fixed width

<telerik:RadGrid ID="grdComprehensiveParts" AutoGenerateColumns="false" AllowSorting="True"
               PageSize="7" AllowPaging="True" runat="server" AllowAutomaticUpdates="false"
               OnItemCommand="grdComprehensiveParts_ItemCommand" AllowAutomaticInserts="false"
               OnInsertCommand="grdComprehensiveParts_InsertCommand" OnUpdateCommand="grdComprehensiveParts_UpdateCommand">
               <PagerStyle Mode="NextPrevAndNumeric"></PagerStyle>
               <MasterTableView CssClass="TableviewStle" HeaderStyle-CssClass="GridHeaderStyle"
                   CommandItemDisplay="Top" AutoGenerateColumns="false" DataKeyNames="ComprehensivePartNo"
                   EditMode="InPlace" ItemStyle-CssClass="GridItemStyle" EditItemStyle-CssClass="GridItemStyle">
                   <CommandItemSettings AddNewRecordText="NewRecord" ShowRefreshButton="false" />
                   <Columns>
                       <telerik:GridEditCommandColumn ButtonType="ImageButton" UniqueName="EditCommandColumn">
                           <ItemStyle CssClass="MyImageButton"></ItemStyle>
                       </telerik:GridEditCommandColumn>
                       <telerik:GridTemplateColumn HeaderText="InvoiceDate">
                           <EditItemTemplate>
                               <telerik:RadDatePicker runat="server" ID="dpInvoiceDate" DbSelectedDate='<%#Eval("InvoiceDate")%>'>
                               </telerik:RadDatePicker>
                           </EditItemTemplate>
                           <ItemTemplate>
                               <asp:Label runat="server" ID="lblInvoiceDate" Text='<%#Eval("InvoiceDate")%>'></asp:Label>
                           </ItemTemplate>
                       </telerik:GridTemplateColumn>
                       <telerik:GridTemplateColumn HeaderText="InvoiceNumber">
                           <EditItemTemplate>
                               <telerik:RadTextBox CssClass="GridEditTextbox" runat="server" ID="txtInvoiceNumber"
                                   Text='<%#Eval("InvoiceNumber") %>'>
                               </telerik:RadTextBox>
                           </EditItemTemplate>
                           <ItemTemplate>
                               <asp:Label runat="server" ID="lblLength" CssClass="GridLabelStyle" Text='<%#Eval("InvoiceNumber")%>'></asp:Label>
                           </ItemTemplate>
                       </telerik:GridTemplateColumn>
                       <telerik:GridTemplateColumn HeaderText="PartNumber">
                           <EditItemTemplate>
                               <telerik:RadTextBox CssClass="GridEditTextbox" runat="server" ID="txtPartNumber"
                                   Text='<%#Eval("PartNumber") %>'>
                               </telerik:RadTextBox>
                           </EditItemTemplate>
                           <ItemTemplate>
                               <asp:Label runat="server" ID="lblPartNumber" CssClass="GridEditTextbox" Text='<%#Eval("PartNumber")%>'></asp:Label>
                           </ItemTemplate>
                       </telerik:GridTemplateColumn>
                       <telerik:GridTemplateColumn HeaderText="PartDescription">
                           <EditItemTemplate>
                               <telerik:RadTextBox runat="server" ID="txtPartDescription" CssClass="GridEditTextbox"
                                   Text='<%#Eval("PartDescription") %>'>
                               </telerik:RadTextBox>
                           </EditItemTemplate>
                           <ItemTemplate>
                               <asp:Label runat="server" ID="lblPartDescription" Text='<%#Eval("PartDescription")%>'></asp:Label>
                           </ItemTemplate>
                       </telerik:GridTemplateColumn>
                       <telerik:GridTemplateColumn HeaderText="ReturnQuantity">
                           <EditItemTemplate>
                               <telerik:RadNumericTextBox runat="server" ID="txtReturnQuantity" CssClass="GridEditTextbox"
                                   Text='<%#Eval("ReturnQuantity") %>'>
                               </telerik:RadNumericTextBox>
                           </EditItemTemplate>
                           <ItemTemplate>
                               <asp:Label runat="server" ID="lblReturnQuantity" CssClass="GridEditTextbox" Text='<%#Eval("ReturnQuantity")%>'></asp:Label>
                           </ItemTemplate>
                       </telerik:GridTemplateColumn>
                       <telerik:GridTemplateColumn HeaderText="ReturnDesc">
                           <EditItemTemplate>
                               <telerik:RadTextBox runat="server" ID="txtReturnDesc" Text='<%#Eval("ReturnDesc") %>'>
                               </telerik:RadTextBox>
                           </EditItemTemplate>
                           <ItemTemplate>
                               <asp:Label runat="server" ID="lblReturnDesc" CssClass="GridEditTextbox" Text='<%#Eval("ReturnDesc")%>'></asp:Label>
                           </ItemTemplate>
                       </telerik:GridTemplateColumn>
                       <telerik:GridButtonColumn ConfirmText="Delete this product?" ConfirmDialogType="RadWindow"
                           ConfirmTitle="Delete" ImageUrl="../Vital Software Pty Ltd_files/Delete.gif" ButtonType="ImageButton"
                           CommandName="Delete" Text="Delete" UniqueName="DeleteColumn">
                           <ItemStyle HorizontalAlign="Center" CssClass="MyImageButton"></ItemStyle>
                       </telerik:GridButtonColumn>
                   </Columns>
               </MasterTableView>
               <ClientSettings>
                   <ClientEvents OnRowDblClick="RowDblClick1"></ClientEvents>
               </ClientSettings>
           </telerik:RadGrid>
MasterChiefMasterChef
Top achievements
Rank 2
 answered on 13 Feb 2013
1 answer
98 views
Hi,

I'm using Web20 skin for my Barcharts and Line charts but it seems it has only 5 colors in color pallet and it repeats those colors for legends # more than 5. So 1st and 6th Legends have same color. Do you have any skin that has more colors? Sometimes I have 30 Legends to display and its really confusing when all legends have same color in the chart. please help asap.

Thanks,
Archana
Petar Kirov
Telerik team
 answered on 13 Feb 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?