So i was trying telerik:RadHtmlChart to try make my chart more Responsive so that when the user resize the screen the chart resize too , but it is not working ..in the code they write ""
but when i try to put it in my code its say that 'ClientEvents not supported ' any one know whey i checked the web.config and its seem fine
help
<div class="demo-container">
<telerik:RadHtmlChart runat="server" ID="BarChart" Height="300px" Width="100%">
<ClientEvents OnLoad="chartLoad" />
<PlotArea>
<XAxis>
<Items>
<telerik:AxisItem LabelText="Item 1"></telerik:AxisItem>
<telerik:AxisItem LabelText="Item 2"></telerik:AxisItem>
<telerik:AxisItem LabelText="Item 3"></telerik:AxisItem>
</Items>
</XAxis>
<Series>
<telerik:BarSeries Name="Series 1">
<SeriesItems>
<telerik:CategorySeriesItem Y="25"></telerik:CategorySeriesItem>
<telerik:CategorySeriesItem Y="-12"></telerik:CategorySeriesItem>
<telerik:CategorySeriesItem Y="39"></telerik:CategorySeriesItem>
</SeriesItems>
</telerik:BarSeries>
<telerik:BarSeries Name="Series 2">
<SeriesItems>
<telerik:CategorySeriesItem Y="-15"></telerik:CategorySeriesItem>
<telerik:CategorySeriesItem Y="38"></telerik:CategorySeriesItem>
<telerik:CategorySeriesItem Y="-11"></telerik:CategorySeriesItem>
</SeriesItems>
</telerik:BarSeries>
</Series>
</PlotArea>
</telerik:RadHtmlChart>
</div>
The following online resources show how to make RadHtmlChart responsive:
Responsive Telerik RadHtmlChart
https://demos.telerik.com/aspnet-ajax/htmlchart/examples/functionality/responsive-chart/defaultcs.aspx
https://www.telerik.com/support/code-library/radhtmlchart-in-a-responsive-web-page
window.onresize = function () {
$find("<%=RadHtmlChart1.ClientID%>").get_kendoWidget().resize();
}
Related
I'm using jsf2.2 primefaces 6.0 and i already implemented a graphical solution to view, download and print pictures through galleria component of primefaces.
The issue is that I need help positioning the print commandButton on the right for best ergonomic result.
Here's the wanted result:
Here the XHTML code:
<p:dialog header="Documents numérisés" widgetVar="diag" modal="true"
dynamic="true" showEffect="fade" hideEffect="fade" resizable="true"
position="center" id="diagImages" onShow="download()">
<p:outputPanel id="gal" style="text-align:center;">
<p:galleria value="#{demandeBean.demandeSelectionnee.images}"
panelWidth="500" panelHeight="313" showCaption="false"
autoPlay="false" var="image">
<p:graphicImage id="image"
value="http://localhost:18080/openCars/images/#{image}"
width="500" height="313" />
</p:galleria>
</p:outputPanel>
<p:commandButton value="Print" type="button" icon="ui-icon-print"
style="display:block;margin-bottom: 20px">
<p:printer target="image" />
</p:commandButton>
</p:dialog>
Well, this may not be a perfect solution but it worked for me.
<p:panelGrid>
<p:commandButton value="Print" type="button" icon="ui-icon-print"
style="float:right;">
<p:printer target="image" />
</p:commandButton>
<p:panelGrid>
How can i customize the text in legend. am using telerik tools. how can i change the legend text from the back end? c# or vb.net code is enough. as per the customer requirement i need to display combined text from x axis and y axis are to be displayed in the legend. following is the code am using for this.
<telerik:radchart id="radchart_teamchart" autolayout="true" charttitle-appearance-fillstyle-fillsettings-imagealign="Center"
chartimageformat="Png" charttitle-visible="true" seriesorientation="Vertical"
width="900px" defaulttype="Bubble" runat="server" skin="Vista" autotextwrap="true"
intelligentlabelsenabled="true">
<ChartTitle TextBlock-Text="My New Customer Status">
</ChartTitle>
<Series>
<telerik:ChartSeries DataYColumn="noofcustomer" Name="Order" Type="Bar" Appearance-BarWidthPercent="10">
<Appearance LabelAppearance-Visible="false">
<TextAppearance TextProperties-Font="Cambria, 8.25pt" Position-AlignedPosition="TopLeft">
</TextAppearance>
<FillStyle MainColor="DarkOrange" SecondColor="WhiteSmoke" FillType="Gradient">
</FillStyle>
<PointMark Visible="True" Border-Width="2" Border-Color="DarkKhaki" Dimensions-AutoSize="false"
Dimensions-Height="10px" Dimensions-Width="6px">
<FillStyle MainColor="Red" FillType="solid">
</FillStyle>
</PointMark>
<LineSeriesAppearance Width="6"></LineSeriesAppearance>
</Appearance>
</telerik:ChartSeries>
</Series>
<PlotArea>
<XAxis DataLabelsColumn="month" AxisLabel-Visible="true" AxisLabel-TextBlock-Text="Month"
AxisLabel-TextBlock-Appearance-TextProperties-Color="Brown">
<Appearance>
<TextAppearance TextProperties-Font="Arial, 8.25pt, style=Bold" Dimensions-Paddings="0.5px">
</TextAppearance>
<LabelAppearance RotationAngle="270">
</LabelAppearance>
</Appearance>
</XAxis>
<YAxis AxisMode="Normal" MaxItemsCount="7" AxisLabel-Visible="true" AxisLabel-TextBlock-Text="No Of Cusotmers"
AxisLabel-TextBlock-Appearance-TextProperties-Color="Brown">
<Appearance>
<TextAppearance TextProperties-Font="Arial, 8.5pt, style=Bold">
</TextAppearance>
</Appearance>
</YAxis>
</PlotArea>
<Legend Visible="true" ></Legend>
</telerik:radchart>
I do not think that's what a legend is for and thus, I do not think you can do this.
I would advise that you first go through the control documentation and explore the available properties to see whether something is useful for you:
http://www.telerik.com/help/aspnet-ajax/chart-styling-custom-appearance-properties.html
http://www.telerik.com/help/aspnet-ajax/chart-styling-elements.html
http://www.telerik.com/help/aspnet-ajax/chart-legenddisplaymode.html - note the ItemLabels option that puts the items in the legend
http://www.telerik.com/help/aspnet-ajax/chart-legend.html - there are also some options on building custom legends, so this can help
Another idea is to build a custom legend from your data source. You can see a sample approach here http://demos.telerik.com/aspnet-ajax/htmlchart/examples/functionality/custombarcolor/defaultcs.aspx even though the chart is the current RadHtmlChart control (RadChart is deprecated in favor of this newer chart control).
i'm using jqgrid asp.net component .how can i change a filed width and height (text box or combo) in add and edit dialog boxes?
Thank you
At the last im found it
1 you need to specify edittype attribute
2 after that specify editfiled attributes tag
for text area
<trirand:JQGridColumn DataField="Remarks" HeaderText="Remarks" Editable="true" EditType="TextArea">
<Formatter>
<trirand:CustomFormatter FormatFunction="formatRating" UnFormatFunction="unformatRating" />
</Formatter>
<EditFieldAttributes>
<trirand:JQGridEditFieldAttribute Name="cols" Value="80" />
<trirand:JQGridEditFieldAttribute Name="rows" Value="6" />
</EditFieldAttributes>
</trirand:JQGridColumn>
for text box
<trirand:JQGridColumn DataField="Design" HeaderText="Design" Editable="true" EditDialogFieldSuffix=" (MAX - 10)">
<Formatter>
<trirand:CustomFormatter FormatFunction="formatRating" UnFormatFunction="unformatRating" />
</Formatter>
<EditFieldAttributes>
<trirand:JQGridEditFieldAttribute Name="size" Value="2" />
</EditFieldAttributes>
</trirand:JQGridColumn>
if i will change SlideDirection to right then it will not work shows blank and no dick pin there but for Left property it works
<center>
<telerik:RadSplitter ID="RadSplitter1" runat="server" Height="300" Width="500">
<telerik:RadPane ID="EndPane" runat="server" Width="220" Scrolling="None">
<telerik:RadSlidingZone ID="RadSlidingZone1" runat="server" Width="22" ClickToOpen="false" SlideDirection="Left">
<telerik:RadSlidingPane ID="RadSlidingPane2" Title="Pane1" runat="server" Width="150"
MinWidth="130">
1
</telerik:RadSlidingPane>
</telerik:RadSlidingZone>
</telerik:RadPane>
</telerik:RadSplitter>
</center>
you can check the size of the pane that may help
I have a have an asp:Menu and i am using css classes to format this menu.
<asp:Menu ID="MenuMain" runat="server" DataSourceID="SiteMapDataSource"
Orientation="Horizontal" RenderingMode="List" SkinID="None"
IncludeStyleBlock="false" StaticDisplayLevels="1">
<StaticMenuStyle CssClass="nav" />
<StaticSelectedStyle CssClass="active" />
<LevelSubMenuStyles>
<asp:SubMenuStyle CssClass="level1" />
<asp:SubMenuStyle CssClass="level2" />
</LevelSubMenuStyles>
However asp.net dynamically adds the inline styles and divs that are generated by javascript associated to the menu.
Is there anyway to prevent this ?
Add your own css class with different names and associate them with this in CssClass
<StaticMenuStyle CssClass="nav" />
<StaticSelectedStyle CssClass="active" />
<LevelSubMenuStyles>
<asp:SubMenuStyle CssClass="level1" />
<asp:SubMenuStyle CssClass="level2" />
</LevelSubMenuStyles>
Hope it helps.
Don't forget to upvote it if it solves you problem.
Thanks.. :)