Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
94 views
I know you can hide the refresh button on the grid using the CommandItemDisplay="None", but what I'm looking to do is move the refresh button outside of the grid.  Can this be done?  (see image for example)
Shinu
Top achievements
Rank 2
 answered on 19 Oct 2011
4 answers
153 views
Seems like something changed between 2011 Q1 519 and the latest 2011 Q2 712 version in regards to how nulls are handled with GridDropDownColumns.  All of my GridDropDownColumns where there is a null value in the field assigned to the DataField property I now see the non-breaking space character   instead of nothing or an empty string.  Was this change intentional or a mistake?
Iana Tsolova
Telerik team
 answered on 19 Oct 2011
2 answers
190 views
Hi everybody:
  below is my code
<telerik:RadNumericTextBox ID="rmtxtPayment" runat="server" Type="Currency"
  MaxLength="10" ReadOnly="True">
  <ReadOnlyStyle HorizontalAlign="Right" />
  <EnabledStyle HorizontalAlign="Right" />
</telerik:RadNumericTextBox>
In IE8 firefox7 chrome14 display properly, but the content can not be right-aligned IE9.
I use telerik.Web.UI, v.2011.1.519.40
Thank you for your help!
z
Top achievements
Rank 1
 answered on 19 Oct 2011
0 answers
103 views
I have a Radgrid that does not get populated/attached to a datasource until the user selectes an input or click a button.

On initial page load, the RadGrid appears as a thick/bold horizontal line across the designated location. Please refer to attachment.

Thanks.


[EDIT]: Never mind. I found a way.
Daniel
Top achievements
Rank 1
 asked on 19 Oct 2011
1 answer
132 views
I am using a RadMaskedTextbox on a Registration page as well as a user properties page in which you have to be logged in to the site to access the user properties page.

The issue I am having is the first time the browser (does not matter which browser) loads the Registration page with the RadMaskedTextbox on it, it does not create the control properly. It just creates a normal html input control with the RadMaskedTextbox's mask, but does not provide any of the actual control's functionality. (i.e. entering only the allowed characters)

The interesting thing is if you log in and navigate to a page with the RadMaskedTextbox on it and then log back out and navigate to the Registration page, the control works perfectly. Sort of like the browser is caching the control's code or something.

Any suggestions or ideas?
Robert
Top achievements
Rank 1
 answered on 18 Oct 2011
0 answers
96 views
I have a requirement to build a treeview dynamically.  Each node on the treeview has a label and two checkboxes.  I have tried two different methods to build the treeview.  In Case 1, I created a node template that includes the label and two checkboxes.   In  Case 2, I do not use a template, but rather I simply add the label and two checkboxes to the node control collection.   I loop through the node collection to set the checkboxes Checked property after I have added all of the nodes to the treeview.   In Case 1, I build the nodes and add the nodes to the treeview in the Page_Init event.  In Case 2, I have tried building the nodes and adding the controls in both Page_Init and Page_Load events.

When I run the page, I change the state of some of the checkboxes in some nodes.  Then I do a postback.  On the return from the postback, everything displays correctly (maintaining the correct state of the checkboxes).  If I build the dynamic treeview in the Page_Load event, I am not able to correctly maintain the checkboxes state.  In Case 2, everything works fine on the first postback.  Then if I make additional changes to the checkboxes and resubmit, the return from the postback does NOT maintain the correct state of the checkboxes.  Even if I do not make any changes to the checkboxes, but just submit unchanged values, the return screen has changed the values of the checkboxes.  (This is true regardless of whether I build the treeview in Page_Init or Page_Load)

Does anyone have any advice on how to maintain the correct state of controls added dynamically to nodes in a treeview?
Kim Wilson
Top achievements
Rank 1
 asked on 18 Oct 2011
3 answers
157 views
Iam having a problem while exporting grid data to pdf. The page Title is not formatting Html escape chacters so that iI would have part of the title in a newline.

This is my code.
grid.ExportSettings.Pdf.PageTitle = "All Transactions Report" + "\n" + Report printed by User;


I would expect my output to be

All Transactions Report

Report printed by User

But my pdf is outputting

All Transactions Report Report printed by User

Any help will be appreciated
Daniel
Telerik team
 answered on 18 Oct 2011
1 answer
102 views
Hello, im trying to move my custom columns after the auto generated ones, is there a way i can do it? i try orderindex but its not working:
orderindex = RadGrid1.MasterTableView.RenderColumns.Length;
 this.RadGrid1.Columns.FindByUniqueName("Impresion").OrderIndex = orderindex;

please, help. thank you
liliana rojas
Top achievements
Rank 1
 answered on 18 Oct 2011
5 answers
229 views
There seems to be an issue with applying styles in the client side OnDayRender event.
We've noticed that the style is applied correctly, however when the day is hovered over the style reverts to its original style that was applied before the OnDayRender event.
We have a workaround applied by overriding the cell style in the hover event, however the behaviour seems to be incorrect in that it should be remembering the style applied on the client side?
Felipe Casanova
Top achievements
Rank 1
 answered on 18 Oct 2011
2 answers
106 views
I am very new to Telerik so excuse me if I am leaving something out, but I'll try to be as accurate as possible. I have a RadChart (line chart) with a linqdatasource. The chart renders accurately when all YValues are above 1. However, for any YValue between 0 and 1 (e.g. 0.2, 0.6, etc.), the chart runs directly into the XAxis with no label displayed. In fact, it does not even display a label at 0. For those charts where all YValues are below 1, the chart renders blank, with no datapoints, or labels shown. I have went through the code, and the data is being picked up accurately. I have also tried setting the PlotArea range for the YAxis in steps of .5, rather than 1. The results are still the same.

I'm attaching 4 files:
The following is my codebehind:
    protected void trcBehaviorData_ItemDataBound(object sender, Telerik.Charting.ChartItemDataBoundEventArgs e)
    {
        RethinkAutismDataContext ctx = new RethinkAutismDataContext();
 
        NameValueCollection nvcNotes = (NameValueCollection)Session["nvcNotes"];
 
        int index = e.SeriesItem.Index;
        var key = nvcNotes[(index + 1).ToString()];
 
        var r = ctx.viewBehaviorPlanDataInfos.Where(rr => rr.dataSetId == Convert.ToInt32(key)).FirstOrDefault();
        if (r != null)
        {
            String bNotes = "";
            if (!String.IsNullOrEmpty(r.notes))
                bNotes = ":<br /> " + r.notes;
            e.SeriesItem.ActiveRegion.Tooltip = "<b>" + r.dateCreated.ToString("MM/dd/yyyy") + " " + r.uName + "</b>" + bNotes;
            e.SeriesItem.YValue = (double)r.result;
 
        }
    }
 
    protected void buildChartXAxis()
    {
 
        int idx = 0;
        int planCount = 1;
 
        RethinkAutismDataContext ctx = new RethinkAutismDataContext();
        var behavior = (from b in ctx.BehaviorTrackings
                        where b.Id == behaviorId
                        select b).SingleOrDefault();
        trackingMethod = behavior.MethodTypeLU.Name;
        int resultCount = 0;
 
        List<dataReportForBehaviorPlanResult> result = ctx.dataReportForBehaviorPlan(ChildProfileId, behaviorId, Plan).ToList();
        intervalMinutes = (int)behavior.IntervalsofMinutes;
        resultCount = result.Count();
        if (resultCount > 0)
        {
            if (resultCount < 21)
            {
                IEnumerator ieResult = result.GetEnumerator();
                ieResult.MoveNext();
                dataReportForBehaviorPlanResult resultSummary = (dataReportForBehaviorPlanResult)ieResult.Current;
 
                trcBehaviorData.PlotArea.XAxis.AutoScale = false;
                trcBehaviorData.PlotArea.XAxis.AddRange(1, 21, 1);
                for (int i = 0; i < 21; i++)
                {
                    trcBehaviorData.PlotArea.XAxis[i].TextBlock.Text = (i + 1).ToString();
                }
            }
 
            if (resultCount > 20)
            {
                trcBehaviorData.PlotArea.XAxis.AutoScale = false;
                trcBehaviorData.PlotArea.XAxis.AddRange(1, resultCount + 1, 1);
 
                IEnumerator ieResult = result.GetEnumerator();
                while (ieResult.MoveNext())
                {
                    dataReportForBehaviorPlanResult resultSummary = (dataReportForBehaviorPlanResult)ieResult.Current;
 
                    trcBehaviorData.PlotArea.XAxis[idx].TextBlock.Text = planCount.ToString();
                    idx++;
                    planCount++;
                }
            }
        }
}
 
    protected void buildChartYAxis()
    {
        RethinkAutismDataContext ctx = new RethinkAutismDataContext();
        var behavior = (from b in ctx.BehaviorTrackings
                        where b.Id == behaviorId
                        select b).SingleOrDefault();
        trackingMethod = behavior.MethodTypeLU.Name;
        double yAxisLabel = 0;
 
        switch (trackingMethod)
        {
            case "Intervals":
                trcBehaviorData.PlotArea.YAxis.AutoScale = false;
                trcBehaviorData.PlotArea.YAxis.AddRange(1, 120, 10);
 
                for (int i = 0; i < 11; i++)
                {
                    trcBehaviorData.PlotArea.YAxis[i].TextBlock.Text = yAxisLabel.ToString() + "%";
                    yAxisLabel += 10;
                }
                trcBehaviorData.PlotArea.YAxis[11].TextBlock.Text = "Intervals";
                trcBehaviorData.PlotArea.YAxis[12].TextBlock.Text = "% of";
                break;
            case "Frequency":
                trcBehaviorData.PlotArea.YAxis.AutoScale = false;
                trcBehaviorData.PlotArea.YAxis.AddRange(1, 23, 1);
                for (int i = 0; i < 21; i++)
                {
                    trcBehaviorData.PlotArea.YAxis[i].TextBlock.Text = yAxisLabel.ToString();
                    yAxisLabel +=1; // yAxisLabel + Convert.ToDouble(0.5);
                }
                trcBehaviorData.PlotArea.YAxis[21].TextBlock.Text = "/ day";
                trcBehaviorData.PlotArea.YAxis[22].TextBlock.Text = "times";
                break;
                //trcBehaviorData.PlotArea.YAxis.AutoScale = false;
                //double maxValue = Convert.ToDouble(trcBehaviorData.PlotArea.YAxis.MaxValue);
                //trcBehaviorData.PlotArea.YAxis.AddRange(1, maxValue, .1);
                //maxValue -= 1;
                //for (int i = 0; i < maxValue; i++)
                //{
                //    trcBehaviorData.PlotArea.YAxis[i].TextBlock.Text = yAxisLabel.ToString();
                //    yAxisLabel = yAxisLabel + Convert.ToDouble(0.1);
                //}
                ////maxValue = Convert.ToInt32(trcBehaviorData.PlotArea.YAxis.MaxValue);
                //trcBehaviorData.PlotArea.YAxis[Convert.ToInt32(maxValue)].TextBlock.Text = "/ hour";
                //maxValue += Convert.ToDouble(0.5);
                //trcBehaviorData.PlotArea.YAxis[Convert.ToInt32(maxValue)].TextBlock.Text = "times";
                //break;
            case "Duration":
                trcBehaviorData.PlotArea.YAxis.AutoScale = false;
                trcBehaviorData.PlotArea.YAxis.AddRange(1, 60, 5);
                for (int i = 0; i < 12; i++)
                {
                    trcBehaviorData.PlotArea.YAxis[i].TextBlock.Text = yAxisLabel.ToString();
                    yAxisLabel += 5;
                }
                trcBehaviorData.PlotArea.YAxis[12].TextBlock.Text = "Min";
                break;
        }
 
    }
And here's my asp:
<telerik:RadChart ID="trcBehaviorPlanData" runat="server" DataSourceID="behaviorPlanSummary"
    DefaultType="Line" Width="810px" Height="350px">
    <Series>
        <cc1:ChartSeries Name="dataMeasurement" DataYColumn="result" Type="Line" DataLabelsColumn="date"
            >
            <Appearance ShowLabels="true" PointDimentions-AutoSize="False" PointDimentions-Height="10px"
                PointDimentions-Width="30px">
                <%--graph line color--%>
                <FillStyle FillType="Solid" MainColor="47, 127, 172">
                </FillStyle>
                <PointMark Dimensions-AutoSize="False" Dimensions-Height="8px" Dimensions-Width="40px"
                    Visible="True">
                </PointMark>
                <TextAppearance TextProperties-Color="78, 168, 188">
                </TextAppearance>
                <Border Color="177, 215, 250" />
            </Appearance>
        </cc1:ChartSeries>
    </Series>
    <PlotArea>
        <XAxis>
            <Appearance Color="226, 218, 202" MajorTick-Color="221, 235, 244">
                <MajorGridLines Color="221, 235, 244" />
                <TextAppearance TextProperties-Color="81, 99, 100">
                </TextAppearance>
            </Appearance>
            <AxisLabel>
                <TextBlock>
                    <Appearance TextProperties-Color="78, 168, 188">
                    </Appearance>
                </TextBlock>
            </AxisLabel>
        </XAxis>
        <YAxis AxisMode="Normal" Appearance-LabelAppearance-Position-AlignedPosition="Center">
            <Appearance Color="226, 218, 202" MajorTick-Color="221, 235, 244" MinorTick-Color="221, 235, 244">
                <MajorGridLines Color="247, 251, 252" />
                <MinorGridLines Color="247, 251, 252" />
                <TextAppearance TextProperties-Color="81, 99, 100">
                </TextAppearance>
            </Appearance>
            <AxisLabel>
                <TextBlock>
                    <Appearance TextProperties-Color="247, 251, 252">
                    </Appearance>
                </TextBlock>
            </AxisLabel>
        </YAxis>
        <Appearance Dimensions-Width="30" Dimensions-Margins="40px, 30px, 15%, 9%">
            <%--graph background color--%>
            <FillStyle MainColor="247, 251, 252" SecondColor="Transparent">
            </FillStyle>
            <Border Color="221, 235, 244" />
        </Appearance>
    </PlotArea>
    <Appearance BarWidthPercent="20" Corners="Round, Round, Round, Round, 5">
        <FillStyle MainColor="247, 251, 252">
        </FillStyle>
        <Border Color="188, 229, 231" Width="1" />
    </Appearance>
    <ChartTitle>
        <Appearance Dimensions-Margins="4%, 10px, 10px, 7%">
            <FillStyle MainColor="">
            </FillStyle>
        </Appearance>
        <TextBlock Text="">
            <Appearance TextProperties-Color="232, 140, 0" TextProperties-Font="Verdana, 20pt, style=Bold">
            </Appearance>
        </TextBlock>
    </ChartTitle>
    <Legend>
        <Appearance Visible="false" Position-AlignedPosition="TopLeft">
            <ItemTextAppearance TextProperties-Color="81, 99, 100">
            </ItemTextAppearance>
            <Border Color="247, 251, 252" />
        </Appearance>
        <TextBlock Visible="true">
        </TextBlock>
    </Legend>
</telerik:RadChart>
I'm also attaching images of how some of these charts render, with the behavior described.

Any help would be greatly appreciated!

Rita

Rita
Top achievements
Rank 1
 answered on 18 Oct 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
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?