Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
348 views
I have a radtextbox that I have set to change the background color on change text:
<ClientEvents OnValueChanged="ChangeBackColor" />
function ChangeBackColor(sender) {
sender.get_styles().EnabledStyle[0] += "background-color: lemonchiffon;";
sender.updateCssClass(); }

I have a combobox that does the same thing:

OnClientSelectedIndexChanged="ChangeBackColorCombo"

function ChangeBackColorCombo(sender, args) {
var inputElement = sender.get_inputDomElement();
inputElement.style.backgroundColor = "lemonchiffon";
}

Is there an equvalent to this for a datetime picker? I cant find the function that reference the input or textbox of the control to change it on a selected date change.
Thanks
Shinu
Top achievements
Rank 2
 answered on 14 Nov 2013
4 answers
420 views
Hi i'am using RadHTMLChart with LineSeries.

When i don't pu anything for the minValue in the YAxis the minValue is set automatic.
But it not working all the time, is it me or it a bug?
I have 2 diffrent graphs the first one the lowest number is 77 and the and the minValue autoscale to 72
I have a second graphs with almost with the samething but the smalest number is 58 and the minValue is set to 0??

What i am doing wrong?
I want the minValue and maxValue to autoscale
Sorry for my bad English!
Tks
Luc



<telerik:RadHtmlChart runat="server" ChartTitle-Text="Courbe FR" DataSourceID="SqlDataSource1" ID="RadHtmlChart1" Width="800" Height="500">
                          <PlotArea>
                               <Series>
                                      
                                    <telerik:LineSeries Name="École" DataFieldY="rlEcole"> 
                                      <Appearance>
                                              <FillStyle BackgroundColor="Blue" />
                                         </Appearance> 
                                      <TooltipsAppearance Color="White" /> 
                                  </telerik:LineSeries> 
                                      
                                    <telerik:LineSeries Name="District"  DataFieldY="rlDistrict"> 
                                      <Appearance>
                                              <FillStyle BackgroundColor="Green" />
                                         </Appearance> 
                                      <TooltipsAppearance Color="White" /> 
                                  </telerik:LineSeries> 
  
                                                                       
                                    <telerik:LineSeries Name="Province"  DataFieldY="rlProvince"> 
                                      <Appearance>
                                              <FillStyle BackgroundColor="Red" />
                                         </Appearance> 
                                      <TooltipsAppearance Color="White" /> 
                                  </telerik:LineSeries> 
                               </Series>
                                 
  
                               <YAxis> 
                                    <TitleAppearance Text="%" >
                                        <TextStyle FontSize="16px"></TextStyle>
                                    </TitleAppearance>
                               </YAxis>
  
                                
                               <XAxis DataLabelsField="strAnnee">
                                    <LabelsAppearance />
                               </XAxis>
                                             
                          </PlotArea>
Stamo Gochev
Telerik team
 answered on 14 Nov 2013
1 answer
244 views
Hey Guys,

We have a project where we are using a static table (<table>) as the header, below that is the RadGrid with its ShowHeader="false". Depending on the amount of data, the grid automatically sizes its columns (ignoring the ItemStyle and HeaderStyle Width property).

What I need to do is to get the first row, and get each cell's width property in Javascript then assign that width to my static table's "header" cells. I have been searching for weeks on end trying to get an article that describes what I'm trying to do but to no avail.

What I have tried is the following:

$(document).ready(function () {
    var MasterTable = $find("<%= RadGridSec31.ClientID %>").get_masterTableView();
    var Rows = MasterTable.get_dataItems();
    var row = Rows[0];
    var testWidth = row.get_element().cells[4].width;
 
    alert(testWidth); //--> This returns an empty string
});

Obviously this is not correct because the alert shows empty, and there is no javascript errors in the debugging console either. How do I get the width of each cell in the first row of the grid?
Juan
Top achievements
Rank 1
 answered on 14 Nov 2013
2 answers
115 views
I have a Master RadGrid containing databound items. When selecting an item i change content in two child grids (contained in a TabStrip), this works fine. 
Like with the Grids, I would like to change the content on a Rotator (which is also in a tab), when one of the items in the grid is selected. I have tried to Rebind the datasource on my rotator in a item selected event on the grid. This however didn't work. Binding Rotator on Page_Load() works, but this is not what i want. 
Is it possible to do this async? (I want to get images for rotator when an item is selected)
Lars
Top achievements
Rank 1
 answered on 14 Nov 2013
1 answer
385 views
Hi Guys,

Having a heck of a time here. 

We have one client who has a grid (radGrid) in which all rows are always in edit mode, and it uses a edit form user control for its edit mode.

I am trying to add a "Update All" button on the main page (just above the grid). In the button click event I need to loop thru all rows of the grid, find the user control and call a method on the user control that will update its data. I expected I would just call the Update button click event directly.

Problem is, no matter how I try, I cannot "find" the user control. Here is what I have tried:

foreach (GridDataItem dataitem in rgReview.Items)
        {
            if (dataitem.ItemType == GridItemType.AlternatingItem || dataitem.ItemType == GridItemType.Item)
            {   
                GridEditableItem item = (GridEditableItem) dataitem;
                 
                radGridReviewsUserControl userControl = (radGridReviewsUserControl)item.FindControl(GridEditFormItem.EditFormUserControlID);
                 
                string test = "";
 
                radGridReviewsUserControl uc = FindControl<radGridReviewsUserControl>(dataitem.Controls);
 
             }
        }

Notice I tried FindControl as well as a custom recursive FindControl method, and I have iterated thru the objects in debug mode and can find the user control nowhere. Am sure im close.. but just can't find the darn things :(

Can anyone give me a kick in the right direction?

Thanks,

Dave
Princy
Top achievements
Rank 2
 answered on 14 Nov 2013
1 answer
199 views
Princy
Top achievements
Rank 2
 answered on 14 Nov 2013
1 answer
116 views
Hello,

I am developing a table that displays a RadComboBox with a few options. The user is allowed to select multiple items within the RadComboBox, so check boxes are enabled. However, I am having difficulties pulling which items have been checked for each row. I cannot find the dynamically built controls to get the checked items. Also, these RadComboBoxes are not in edit mode. They are simply displaying as normal comboboxes within a grid. How would I access the checked items for each dynamically built combo box? And how could I organize this data by row?

Thanks in advance,

Derek O.
Princy
Top achievements
Rank 2
 answered on 14 Nov 2013
3 answers
293 views
Hi all again,

So it the already a way easy to put the export command buttons on the left??
Or is ther a way to do the same with the template ??


Best regards.
Shinu
Top achievements
Rank 2
 answered on 14 Nov 2013
1 answer
192 views
There is a radbutton in my page and I am writing some C# code in the button click event. In the C# code and I am parsing a date in a try block and if an exception is generated I want to display it and for that I used a radalert. But I found that the alert is displayed after all the c# lines of codes are executed. On debugging that line is executed without any error. Why the delay in displaying the alert, Is this a bug?
Shinu
Top achievements
Rank 2
 answered on 14 Nov 2013
3 answers
215 views
How can I access the value of GridCheckBox column during ItemDataBound Event?

I need access the value and if condition is true hide delete link button.  I have tried many different ways with no luck so far.

Here is my code
Protected Sub PeoplegridCheckrow(ByVal sender As Object, ByVal e As Telerik.Web.UI.GridItemEventArgs)
        If TypeOf e.Item Is GridDataItem Then
            Dim dataItem As GridDataItem = CType(e.Item, GridDataItem)
            Dim relationship As String = dataItem("Relationship").Text
            Dim bJournalName As Boolean = (Boolean.Parse(dataItem("UseAsJournalName").Text))
            If relationship = "Family Member" And bJournalName = True Then
                CType(dataItem("DeleteButton").Controls(0), LinkButton).Visible = False
            End If
        End If
    End Sub

Thank you for the help.
Bryan Hughes
Top achievements
Rank 1
 answered on 13 Nov 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?