Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
80 views
Hi,

I have a "strange" style like this:
Snippet created with CBEnhancer
h2 strong {
    color: #06c;
}

This gives me the ability to color some words in headlines - just by setting them bold.
My problem - since the h2 is bold RadEditor shows the bold button as set - and doesn't enable me to apply this style to a part of the heading.

Expected: doubleclick a word to select it - click bold button to set the color.
Got: word is marked - bold button is not clickable

Any way to change this behaviour?

Regards
Manfred
ManniAT
Top achievements
Rank 2
 answered on 14 Sep 2009
2 answers
152 views
Hi All,

I had the error originally, which prompted the use of <colgroup> <col /> etc.

That unfortunately did not work. (The Detail grid uses GrodBoundColumn and GridCheckboxColumn), the Master TableView originally used <Span> and eval which worked , but which provided me a lack of alignments.
I replaced those <Span> elements with a table and no <colgroup> elements resulting in the error, which needed colgroup to get around it.  But no go.

I get this error now
TIA
Neal

System.NullReferenceException: Object reference not set to an instance of an object.
  at Telerik.Web.Apoc.Render.Pdf.Fonts.Type2CIDSubsetFont.get_WArray()
  at Telerik.Web.Apoc.Pdf.PdfFontCreator.CreateCIDFont(String pdfFontID, Font font, CIDFont cidFont)
  at Telerik.Web.Apoc.Pdf.PdfFontCreator.MakeFont(String pdfFontID, Font font)
  at Telerik.Web.Apoc.Pdf.FontSetup.AddToResources(PdfFontCreator fontCreator, PdfResources resources)
  at Telerik.Web.Apoc.Render.Pdf.PdfRenderer.StopRenderer()
  at Telerik.Web.Apoc.StreamRenderer.StopRenderer()
  at Telerik.Web.Apoc.Fo.FOTreeBuilder.Parse(XmlReader reader)


I have checked my C# code to exactly match your examples

 

 

 

protected void grvSchedule_ItemCreated(object sender, GridItemEventArgs e)

 

{

 

if (e.Item.OwnerTableView.Name != "grvAnimalDetl")

 

{

 

foreach (GridDataItem dataItem in e.Item.OwnerTableView.Items)

 

{

 

foreach (TableCell cell in e.Item.Cells)

 

{

cell.Style[

"font-family"] = "Arial Unicode MS";

 

cell.Style[

"text-align"] = "left";

 

cell.Style[

"font-size"] = "12px";

 

cell.Style[

"height"] = "38px";

 

}

}

}

 

if (e.Item.OwnerTableView.Name == "grvAnimalDetl")

 

{

 

if (e.Item is GridDataItem )

 

{

 

foreach (TableCell cell in e.Item.Cells)

 

{

cell.Style[

"font-family"] = "Arial Unicode MS";

 

cell.Style[

"text-align"] = "left";

 

cell.Style[

"font-size"] = "8px";

 

cell.Style[

"height"] = "24px";

 

}

}

 

if (e.Item is GridHeaderItem)

 

{

 

foreach (TableCell cell in e.Item.Cells)

 

{

cell.Style[

"font-family"] = "Arial Unicode MS";

 

cell.Style[

"text-align"] = "left";

 

cell.Style[

"font-size"] = "9px";

 

cell.Style[

"font-weight"] = "bold";

 

cell.Style[

"height"] = "35px";

 

}

}

 

 

if (e.Item is GridCommandItem)

 

{

e.Item.PrepareItemStyle();

//needed to span the image over the CommandItem cells

 

 

 

 

 

}

 

 

}
}

and markup

 

 

 

<

 

telerik:RadGrid ID="grvSchedules"

 

 

runat="server" Width="100%"

 

 

 

 

 

CssClass="GridVClass"

 

 

AutoGenerateColumns="False"

 

 

 

 

 

AllowPaging="True"

 

 

GridLines="None"

 

 

 

 

 

PagerStyle-AlwaysVisible="false"

 

 

 

 

 

 

OnItemCommand="grvSchedule_ItemCommand"

 

 

OnItemDataBound="grvSchedule_ItemDataBound"

 

 

 

 

 

OnDetailTableDataBind="grvSchedule_DetailTableDataBind"

 

 

OnNeedDataSource="grvSchedule_NeedDataSource"

 

 

OnDataBound="grvSchedule_DataBound"

 

 

 

 

 

OnItemCreated = "grvSchedule_ItemCreated"

 

 

 

 

 

HorizontalAlign="Left">

 

 

 

 

 

 

<ExportSettings IgnorePaging="true" >

 

 

 

 

 

<Pdf PageHeight="270mm" PageWidth="540mm" PageTitle="Client Schedule" />

 

 

 

 

 

</ExportSettings>

 

 

 

 

 

<PagerStyle Mode="NumericPages" AlwaysVisible="False">

 

 

 

 

 

</PagerStyle>

 

 

 

 

 

 

<MasterTableView

 

 

Width="100%"

 

 

DataKeyNames="RecId" CellSpacing="1" pagesize="20">

 

 

 

 

 

<DetailTables >

 

 

 

 

 

<telerik:GridTableView

 

 

Name="grvAnimalDetl"

 

 

 

 

 

BorderColor="Gray"

 

 

 

 

 

BorderStyle="Solid"

 

 

 

 

 

BorderWidth="1px"

 

 

 

 

 

DataKeyNames="AnimalId, AnimalTypeId, insval, Val"

 

 

BackColor="LemonChiffon"

 

 

 

 

 

EditMode="InPlace"

 

 

Width="100%" runat="server" CellSpacing="-1"

 

 

GridLines="Horizontal" HierarchyDefaultExpanded="True"

 

 

PagerStyle-Visible="false" >

 

 

 

 

 

 

<Columns>

 

 

 

 

 

 

<telerik:GridBoundColumn DataField="AnimalName"

 

 

HeaderText="Name" UniqueName="AnimalName">

 

 

 

 

 

<ItemStyle HorizontalAlign="Left" Width="130px" Font-Size="XX-Small" />

 

 

 

 

 

<HeaderStyle HorizontalAlign="Left" Width="130px" Font-Size="XX-Small" />

 

 

 

 

 

</telerik:GridBoundColumn>

 

 

 

 

 

 

 

<telerik:GridCheckBoxColumn DataField="AccidentalVC"

 

 

HeaderText="AccidentalVC" UniqueName="AccidentalVC" >

 

 

 

 

 

<ItemStyle Width ="75px" HorizontalAlign="Center" Font-Size="XX-Small" />

 

 

 

 

 

<HeaderStyle Width="75px" HorizontalAlign="Center" Font-Size="XX-Small"

 

 

 

 

 

wrap="True" />

 

 

 

 

 

</telerik:GridCheckBoxColumn>

 

 

</Columns>

 

 

 

 

 

 

<ItemStyle BackColor="White" Font-Names="Times New Roman" HorizontalAlign="Left" VerticalAlign="Middle" Wrap="False" />

 

 

 

 

 

<AlternatingItemStyle BackColor="GhostWhite" Font-Names="Times New Roman" HorizontalAlign="Left" VerticalAlign="Middle" Wrap="False" />

 

 

 

 

 

<HeaderStyle BackColor="LemonChiffon" />

 

 

 

 

 

 

<CommandItemStyle BackColor="LemonChiffon" BorderColor="Gray"

 

 

BorderStyle="Solid"

 

 

 

 

 

BorderWidth="1px" />

 

 

 

 

 

</telerik:GridTableView>

 

 

 

 

 

</DetailTables>

 

 

 

 

 

 

<Columns>

 

 

 

 

 

<telerik:GridTemplateColumn>

 

 

 

 

 

<ItemTemplate>

 

 

 

 

 

<table>

 

 

 

 

 

<colgroup>

 

 

<col />

 

 

<col />

 

 

</colgroup>

 

 

 

<tr>

 

 

 

 

 

<td >Animal Details and Covers:

 

 

</td>

 

 

 

 

 

<td >

 

 

 

 

 

</td>

 

 

 

 

 

</tr>

 

 

 

 

 

 

</table>

 

 

 

 

 

<br />

 

 

 

 

 

<br />

 

 

 

 

 

<br />

 

 

 

 

 

</ItemTemplate>

 

 

 

 

 

</telerik:GridTemplateColumn>

 

 

</Columns>

 

 

 

 

 

</MasterTableView>

 

 

 

 

 

 

<ClientSettings>

 

 

 

 

 

<Selecting AllowRowSelect="True" />

 

 

 

 

 

</ClientSettings>

 

 

 

 

 

<AlternatingItemStyle Font-Size="X-Small"></AlternatingItemStyle>

 

 

<ItemStyle Font-Size="X-Small"></ItemStyle>

 

 

</telerik:RadGrid>

 

 

 

 

 

 

Neal
Top achievements
Rank 1
 answered on 14 Sep 2009
4 answers
104 views
Is there a way to hide the area that the details tables get shifted over?  I am trying to make the detail table look like part of the main row.  I have ExpandCollapseColumn-Display set to false in the MasterTableView, so I don't see the expand column, but I am hoping that there is a way to remove the area that it is shifted right.
Mike Dennis
Top achievements
Rank 1
 answered on 14 Sep 2009
1 answer
167 views
Hello, I have a question
How can I create a grid from javascript
I want to create the Grid with new columns when you click a button <input click="createGrid();">, in other words, creating a grid dynamically from client side

Thanks.
Sebastian
Telerik team
 answered on 14 Sep 2009
4 answers
167 views
Hi
I have page with RadGrid WebSrvice but when I added Ajax Loading and Grid didn't bind...
When I don't have Grid with WebService is ok:)

MasterPage
 
<asp:ScriptManager ID="ScriptManager1" runat="server" ScriptMode="Release" EnablePageMethods="true"> 
        <Scripts> 
            <asp:ScriptReference Path="WebUserControl/Raport/AdvancedForm.js" /> 
            <asp:ScriptReference Path="~/JScript.js" /> 
        </Scripts> 
    </asp:ScriptManager> 
 
<telerik:RadScriptBlock ID="RadScriptBlock1" runat="server"> 
 
        <script type="text/javascript"> 
            function pageLoad(sender, eventArgs) { 
                if (!eventArgs.get_isPartialLoad()) { 
                    $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("InitialPageLoad"); 
                } 
            } 
</script> 
 
    </telerik:RadScriptBlock> 
    <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Skin="vista" 
        EnableEmbeddedSkins="false"> 
    </telerik:RadAjaxLoadingPanel> 
    <telerik:RadAjaxManager runat="server" ID="RadAjaxManager1" ClientEvents-OnRequestStart="OnRequestStart" 
        OnAjaxRequest="RadAjaxManager1_AjaxRequest" UpdatePanelsRenderMode="Inline" DefaultLoadingPanelID="RadAjaxLoadingPanel1"> 
        <AjaxSettings> 
            <telerik:AjaxSetting AjaxControlID="RadGrid1"> 
                <UpdatedControls> 
                    <telerik:AjaxUpdatedControl ControlID="RadScheduler1" LoadingPanelID="RadAjaxLoadingPanel1" /> 
                </UpdatedControls> 
            </telerik:AjaxSetting> 
            <telerik:AjaxSetting AjaxControlID="RadAjaxManager1"> 
                <UpdatedControls> 
                    <telerik:AjaxUpdatedControl ControlID="Panel2" LoadingPanelID="RadAjaxLoadingPanel3" /> 
                </UpdatedControls> 
            </telerik:AjaxSetting> 
        </AjaxSettings> 
    </telerik:RadAjaxManager> 
 
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel2" runat="server" Height="175px" 
        Width="175px" Transparency="0"> 
        <img alt="Loading..." style="border: 0;" id="progress" runat="server" /> 
    </telerik:RadAjaxLoadingPanel> 
    <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel3" runat="server" Height="75px" 
        Width="75px" Transparency="0"> 
        <img alt="Loading..." src="LoadingProgressBar.gif" style="border: 0;" /> 
    </telerik:RadAjaxLoadingPanel> 
 <div id="divStrona" style="display: none;" runat="server">
<telerik:RadSplitter ID="rsTresc" runat="server" Skin="Vista" Orientation="Vertical" 
                Width="100%" EnableEmbeddedSkins="false" Height="100%" OnClientLoaded="OnClientLoaded"> 
                <telerik:RadPane ID="rpSzukaj" runat="server" Collapsed="False"> 
                    <asp:ContentPlaceHolder ID="cphTresc" runat="server"> 
                    </asp:ContentPlaceHolder> 
                </telerik:RadPane> 
                <telerik:RadSplitBar ID="rsbTrescKalendarz" runat="server" Visible="true" CollapseMode="Forward" 
                    Height="100%" /> 
                <telerik:RadPane ID="rpKalendarz" runat="server" Height="100%"> 
                    <telerik:RadScheduler ID="RadScheduler1" runat="server" Width="100%" DataKeyField="idraport" 
                        DataStartField="raportdatastart" DataEndField="raportdatakoniec" DataSubjectField="opis" 
                        Skin="Office2007" Height="400px" ShowFooter="false" RowHeaderWidth="52" CustomAttributeNames="Due, Priority" 
                        OverflowBehavior="Scroll"> 
                        <WebServiceSettings Path="SchedulerWebService.asmx" ResourcePopulationMode="ServerSide" /> 
                    </telerik:RadScheduler> 
                </telerik:RadPane> 
            </telerik:RadSplitter>
</div>

MasterPage.cs

protected void RadAjaxManager1_AjaxRequest(object sender, AjaxRequestEventArgs e) 
    { 
        if (e.Argument == "RebindScheduler") 
        { 
            RadScheduler1.Rebind(); 
        } 
        if (e.Argument == "InitialPageLoad") 
        { 
            //simulate longer page load 
            //System.Threading.Thread.Sleep(5000); 
             
            //divPanel.Attributes["style"] = ""; 
            //divTresc.Attributes["style"] = ""; 
            divStrona.Attributes["style"] = ""; 
        } 
    } 

Page.aspx:
telerik:RadCodeBlock ID="RadCodeBlock1" runat="server"> 
 
        <script type="text/javascript"> 
            function pageLoad(sender, args) { 
                PageMethods.GetData(updateGrid); 
            } 
 
            function gridCommand(sender, args) { 
 
            } 
 
            function updateGrid(result) { 
                var tableView = $find("<%= RadGrid1.ClientID %>").get_masterTableView(); 
                tableView.set_dataSource(result); 
                tableView.dataBind(); 
            } 
 
            function categoryFetched(category, item) { 
                item.get_cell("CategoryID").innerHTML = category.Name; 
            } 
            function rowDataBound(sender, args) { 
                //to jest po to aby dzialaly GridTemplateColumn gdy jest webservice 
                var label = args.get_item().findControl("ID"); // find control 
                if (label != null) { 
                    label.set_value(args.get_dataItem()["ID"]); 
                } 
            } 
        </script> 
 
    </telerik:RadCodeBlock> 
 
 <telerik:RadGrid ID="RadGrid1" runat="server" Skin="Vista" Width="800px" PageSize="200" 
        AutoGenerateColumns="false" EnableViewState="false" OnRowDrop="RadGrid1_RowDrop"> 
        <MasterTableView DataKeyNames="ID" ClientDataKeyNames="ID"> 
            <Columns> 
                <telerik:GridTemplateColumn HeaderText="ID" Display="false" > 
                    <ItemTemplate> 
                       <asp:Label ID="ID" runat="server" /> 
                    </ItemTemplate> 
                </telerik:GridTemplateColumn> 
                <telerik:GridBoundColumn DataField="Imie" HeaderText="Imie"> 
                </telerik:GridBoundColumn> 
                <telerik:GridBoundColumn DataField="Nazwisko" HeaderText="Nazwisko"> 
                </telerik:GridBoundColumn> 
                <telerik:GridBoundColumn DataField="Specjalizacja" HeaderText="Specjalizacja"> 
                </telerik:GridBoundColumn> 
                <telerik:GridBoundColumn DataField="Status" HeaderText="Status"> 
                </telerik:GridBoundColumn> 
            </Columns> 
        </MasterTableView> 
        <ClientSettings AllowRowsDragDrop="true"> 
            <%--<DataBinding Location="MyService.asmx" SelectMethod="GetData" SelectCountMethod="GetCount"> 
                </DataBinding>--%> 
            <ClientEvents OnRowDataBound="rowDataBound" OnCommand="gridCommand" /> 
            <Selecting AllowRowSelect="true" /> 
            <ClientEvents OnRowDropping="rowDropping" OnRowDragStarted="PobierzKlienta" /> 
        </ClientSettings> 
    </telerik:RadGrid> 


Please help :)
Adek
Top achievements
Rank 1
 answered on 14 Sep 2009
1 answer
76 views
Hi

I have a RadCalendar inside an asp:Repeater, and am trying to find out how I can know from what # RepeaterItem a

"OnSelectionChanged" event is coming from.
I.e. What I am trying to do is, when a date is clicked in my RadCalendar I need to know the state of a CheckBox inside the same RepeaterItem.

I have looked at the following candidates to do this:

1. Through Repeater_ItemCommand, but RadCalendar does not support attribute "CommandName", and this event does not seem to fire for the Repeater control when a date in radControl is clicked.

2. By trying to find the active RepeaterItem in event handler "SelectedDateChange(object sender, SelectedDatesEventArgs e)". Tried using the FindControl() through .Parent.Parent... but without luck.

would love help on this
Axel G.

 

Axel
Top achievements
Rank 2
 answered on 14 Sep 2009
5 answers
336 views
Hi.,

Can i know how to Expand the row When i DoubleClick On the RadGrid  "SelectedRow"

Thank you
Suresh K
Top achievements
Rank 1
 answered on 14 Sep 2009
1 answer
104 views
Hello,

This was logged as a support ticket too.  Using Telerik 2008.3.1125.35, the RadSpell spellcheck popup interface looks very bad.  It's not rendering any of the styles that I can see, though it is referencing the parent class correctly.

Now I am using a custom skin, and it works for everything else... it does look like it's referring to the correct class here, but no styles get applied.  For the spell checker popup, is there anything else I need to setup when using a custom skin?

Thanks.
Martin
Telerik team
 answered on 14 Sep 2009
21 answers
854 views
Hi, is there any issue that may let scrollbar position reset to the top after RadAjaxManager update a region?

I try to dynamically load user controls in the Templated Columns, but after load it, the scrollbar's location always go to the top.

Cheer for your help.
Ricky.
Sebastian
Telerik team
 answered on 14 Sep 2009
8 answers
221 views
I have ELMAH running on my server which reports and logs errors that might otherwise not be seen. Running on IIS 7 server fully patched. I have a web application that after I updated to the latest build (2009.1.527.35) starts throwing this error


System.Web.HttpException: Server cannot append header after HTTP headers have been sent.

Generated: Mon, 01 Jun 2009 18:55:13 GMT


System.Web.HttpException: Server cannot append header after HTTP headers have been sent.
   at System.Web.HttpResponse.AppendHeader(String name, String value)
   at Telerik.Web.UI.RadCompression.application_EndRequest(Object sender, EventArgs e)
   at System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

Sebastian
Telerik team
 answered on 14 Sep 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?