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

I used RadGrid's simple data-binding through the DataBind() method, so there is only two steps to make the datagrid, which is on page load event

RadGridID.DataSource = FRManager.GetAllFRData();
RadGridID.DataBind();

Now i can drag and drop the row and i got the event of protected void RadGridID
_RowDrop(object sender, GridDragDropEventArgs e)
{
}

Whatever example is given on the telerik on below link, i used it to bind but not get success.

http://demos.telerik.com/aspnet-ajax/grid/examples/programming/draganddrop/defaultcs.aspx?

please let me know what to write in this event to work out this, i took one field named OrderNumber in the table, this field is in hidden in my datagrid.

Thanks,
Viktor Tachev
Telerik team
 answered on 14 Nov 2013
2 answers
116 views
I make use of the RadPanelBar and each one has the appropriate Treeview with available columns.  I would like to take the columns on the left and drag them to the RadListBox on the right.  This would allow me to reference the database with only the columns listed in the RadListBox and not have to go through each RadTreeView and determine which columns are checked.  As I have implemented the Telerik example here, curious if there is a way to modify this script that would allow me to go from multiple RadTreeView's to 1 RadListBox?

The list on the Left is "static" as each of the Trees are populated with XML data.  How do I reset the values, if they would like to perform another search within the same session?  Or is it possible to just leave the values on the Left and I could simply just reset the Listbox?
Kate
Telerik team
 answered on 14 Nov 2013
5 answers
475 views
Hi,
I would like to open a aspx page at Radwindow and passing a value by querystring from a button click event.
Without querystring , I was successful , but stuck-up at passing the value.

<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
 <script type="text/javascript">
    function ShowAddSubLevel(id) {
    window.radopen("AddCausePopup.aspx?Cause_Id=" + id, "UserListDialog");
    return false;
</script>
</telerik:RadCodeBlock>
--------------------------------------------
<asp:Panel ID="pnlShowCompany" runat="server">
<telerik:RadWindowManager ID="RadWindowManager1" runat="server" Behaviors="Close, Move, Reload">
  <Windows>
     <telerik:RadWindow ID="UserListDialog" runat="server" Title="Manage actions" Height="610px"
       Width="575px" Left="150px" ReloadOnShow="true" ShowContentDuringLoad="false" Modal="true" VisibleStatusbar="false" Animation="Fade" />
       </Windows>
        </telerik:RadWindowManager>
          </asp:Panel>
protected void BtnAddSublevel_Click(object sender, EventArgs e)
    {
................
............
 Cause_Id = Convert.ToInt32(DtCause1.Rows[0][0].ToString());
...............
...............
ClientScript.RegisterStartupScript(Page.GetType(), "mykey", "ShowAddSubLevel(21);", true);
}
---------------------------------------------
First of all, I am not sure how to pass Cause_Id at ShowAddSubLevel(Cause_Id)??
and even statically RadWindow is not showing.

Please help me out.

Thanks,
Debasish
Shinu
Top achievements
Rank 2
 answered on 14 Nov 2013
1 answer
379 views
Vasil
Telerik team
 answered on 14 Nov 2013
1 answer
330 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
384 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
234 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
105 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
345 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
188 views
Princy
Top achievements
Rank 2
 answered on 14 Nov 2013
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?