Telerik Forums
UI for ASP.NET AJAX Forum
7 answers
506 views
I have the following situation: rad grid is updated when event is passed from a user control on the same page, while AJAX loading works fine, and reloads the grid properly, the RadAjaxLoadingPanel does not show.

here is the simplified example of the aspx page.

<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %> 
<%@ Register src="../../PageControls/Filters/TradeFilter.ascx" tagname="TradeFilter" tagprefix="uc1" %> 
 
 
<telerik:RadAjaxManager DefaultLoadingPanelID="RadAjaxLoadingPanel1" ID="RadAjaxManager1" runat="server"
    <AjaxSettings> 
        <telerik:AjaxSetting AjaxControlID="filterTrade"
            <UpdatedControls> 
                <telerik:AjaxUpdatedControl ControlID="grdTrades" LoadingPanelID="RadAjaxLoadingPanel1" /> 
            </UpdatedControls> 
        </telerik:AjaxSetting> 
    </AjaxSettings> 
</telerik:RadAjaxManager> 
<telerik:RadAjaxLoadingPanel BackColor="Gray" ID="RadAjaxLoadingPanel1" runat="server" Height="150px" Width="150px" Transparency="25"
        <img alt="Loading..." src='<%= RadAjaxLoadingPanel.GetWebResourceUrl(Page, "Telerik.Web.UI.Skins.Default.Ajax.loading.gif") %>' style="border:0;" /> 
</telerik:RadAjaxLoadingPanel> 
 
<uc1:TradeFilter ID="filterTrade" runat="server" /> 
 
<telerik:RadGrid ID="grdTrades" runat="server" Skin="Web20" EnableViewState="true"
<MasterTableView  autogeneratecolumns="true" > 
</telerik:RadGrid> 
 

As i said, the grid loads properly using AJAX and not refreshing the page, but RadAjaxLoadingPanel1 is not displayed.
If I have grid that is refreshed by aspx control, it is displayed properly.






Tsvetina
Telerik team
 answered on 26 Nov 2010
3 answers
87 views
Hi, I'm with a problem when render a radwindow, for some users browsers (IE), not render the title bar with the close button. Yet clean the cookies and temporary files from the IE, but in some cases did resolved and in others no. What can to be the problem? The version of telerik is Q1 2008.
Georgi Tunev
Telerik team
 answered on 26 Nov 2010
4 answers
57 views
I have a grid that is using declarative client side binding to a aspx pagemethod to get data which works fine.

<telerik:RadGrid ID="rgDiscoveries"
                 runat="server"
                 AllowFilteringByColumn="True"
                 AllowSorting="true"
                 AllowPaging="True"
                 GridLines="None"
                 AutoGenerateColumns="true" Culture="en-GB">
  <ClientSettings>
    <DataBinding Location="Default.aspx" SelectMethod="GetDataAndCount" />
  </ClientSettings>
...

I have added a FilterTemplate to one column which has a ComboBox in which pulls a listing from a second page method.
<telerik:GridBoundColumn DataField="ScriptName"
                         HeaderText="Script Name"
                         UniqueName="scriptName"
                         DataType="System.String">
  <FilterTemplate>
    <telerik:RadComboBox ID="filterScriptName"
                         runat="server"
                         EmptyMessage="Select a script"
                         EnableLoadOnDemand="true"
                         ShowMoreResultsBox="true"
                         EnableVirtualScrolling="true"
                         OnClientSelectedIndexChanged="filterScriptName_SelectedIndexChanged">
      <WebServiceSettings method="GetScriptNames" Path="Default.aspx" />
    </telerik:RadComboBox>
  </FilterTemplate>
</telerik:GridBoundColumn>

The combobox is populated but I don't know how to trigger the grid to repopulate when the combobox SelectedIndexChanged event fires.
function filterScriptName_SelectedIndexChanged(sender,args) {
  var tableView = $find("<%= rgDiscoveries.MasterTableView.ClientID %>");
  tableView.filter("ScriptName", args.get_item().get_value(), "EqualTo");
  // What goes here??
}

Is there an example of this somewhere please?

Cheers,
Nick
Tsvetoslav
Telerik team
 answered on 26 Nov 2010
1 answer
41 views
Hi,

I am filtering the grid on a numeric field using the column filter. When filtered with '6 7' filter value and filter options other than between, I get '...operand missing..' error. Can you provide a way to trap the error?

Thanks & Regards
Tsvetoslav
Telerik team
 answered on 26 Nov 2010
1 answer
41 views
Hi - on my grid, it displays the total number of results as well the normal pagination controls, but, if I have my grid set to display 50 rows per page and I have less than 50 results, the pagination doesn't show (which is obvious) but the total row count doesn't show either.

How would I get it to display, say 35 when I have it set to 50 rows per page?

Thanks.
Princy
Top achievements
Rank 2
 answered on 26 Nov 2010
1 answer
75 views
Hi all,

I write this just to save some of you some frustrating hours.

If one of your gridcolumns contain a '$' character in the UniqueName property, there is a risk that you are not able to get the new/updated value from that column.
I have spent many (!) hours  trying to figure out what the problem was.
I don't know if it always is so, or if it was a a combination of dropdown columns / dynamic creation etc ... - but it did not work.

As soon as I removed the '$' - everything was ok.

According to Telerik support this is not a bug - so I guess nothing will be changed due to this in future versions.

Now you are warned !

Happy programming ;-)

Thanks.
Tsvetina
Telerik team
 answered on 26 Nov 2010
7 answers
185 views
I'm using a sql datasource to populate my radcombobox.  The combobox is a multiselect with checkboxes.  I would like to add another item, the text would be All and if you select this item, all the checkboxes in the combo would be selected.  I tried in the databound event and it makes the checkbox, but not the text.  Here's the code:
protected void ImpactCombo_DataBound(object sender, EventArgs e)
        {
            RadComboBoxItem all = new RadComboBoxItem("All", "-1");
            ImpactCombo.Items.Add(all);
        }

Any ideas?  Thanks.
Dimitar Terziev
Telerik team
 answered on 26 Nov 2010
1 answer
115 views
Hello Everyone,

I have been searching for an hour trying to find the solution to this issue.

I am trying to access a RadWindow from a RadWindowManager on a MasterPage within a UserControl.
So...

MasterPage >> WindowManager >> UserControl >> RadWindow


MasterPage
-----------------------

 

 

<telerik:RadWindowManager ID="RadWindowManager1" runat="server">

 

 

 

</telerik:RadWindowManager>

 



UserControl
-------------------------

<

 

 

style type="text/css">

 

 

 

.style1

 

{

 

 

width: 32px;

 

 

 

height: 32px;

 

}

</

 

 

style>

 

<

 

 

p>

 

 

 

<img alt="" class="style1"

 

 

 

src="../../images/ui/1290451133_x-office-document.png" /></p>

 

 

<

 

 

telerik:RadWindow ID="RadWindow1" runat="server">

 

<

 

 

ContentTemplate>

 

 

 

<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>

 

</

 

 

ContentTemplate>

 

</

 

 

telerik:RadWindow>

OnClick of the <IMG> tag I would like to load this RadWindow into the RadWindowManager collection (display it).

What is the best way to achieve this functionality?

Also, is there a way to load a UserControl within the RadWindow?

Many thanks,
~Dean

 

Georgi Tunev
Telerik team
 answered on 26 Nov 2010
3 answers
270 views
Is it possible? I have tried

from http://www.telerik.com/help/aspnet-ajax/grid_sort.html

var masterTable = $find("<%= RadGrid1.ClientID %>").get_masterTableView();
masterTable.sort("");

but it does not seem to do anything?

I need to do it from client side as when you click on different nodes in in my treeview it will rebinds the grid to different columns, so it needs to clear the column sort at the same time.

thanks
Toby
Radoslav
Telerik team
 answered on 26 Nov 2010
5 answers
122 views
Dear Team,
I am using datareader to bind data with grid. Works fine for first page but when a page index is changed or page size is changed grid displays no records...
it shows the new page or resized page correctly when I reload the page this is serverside code please tell me if i am missing something

protected void NeedDataSource()
{
    grd_report.Visible = true;
    if (IsPostBack == true && txt_todate.SelectedDate != null && txt_fromdate.SelectedDate != null)
    {
        String _todate = txt_todate.SelectedDate.Value.ToString("dd-MMM-yyyy");
        String _fromdate = txt_fromdate.SelectedDate.Value.ToString("dd-MMM-yyyy");
        obj_sales.initConnection();
        obj_sales.nwideTotalSalesSummary(_todate, _fromdate);
        grd_report.DataSource = obj_sales.getResults();
        grd_report.DataBind();
    }
}
protected void PageSizeChanged(object source, Telerik.Web.UI.GridPageSizeChangedEventArgs e)
{
    NeedDataSource();
    grd_report.Rebind();
}


        protected void NeedDataSource()
        {
            grd_report.Visible = true;
            if (IsPostBack == true && txt_todate.SelectedDate != null && txt_fromdate.SelectedDate != null)
            {
                String _todate = txt_todate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                String _fromdate = txt_fromdate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                obj_sales.initConnection();
                obj_sales.nwideTotalSalesSummary(_todate, _fromdate);
                grd_report.DataSource = obj_sales.getResults();
                grd_report.DataBind();
            }
        }
        protected void PageSizeChanged(object source, Telerik.Web.UI.GridPageSizeChangedEventArgs e)
        {
            NeedDataSource();
            grd_report.Rebind();
        }

        protected void NeedDataSource()
        {
            grd_report.Visible = true;
            if (IsPostBack == true && txt_todate.SelectedDate != null && txt_fromdate.SelectedDate != null)
            {
                String _todate = txt_todate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                String _fromdate = txt_fromdate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                obj_sales.initConnection();
                obj_sales.nwideTotalSalesSummary(_todate, _fromdate);
                grd_report.DataSource = obj_sales.getResults();
                grd_report.DataBind();
            }
        }
        protected void NeedDataSource()
        {
            grd_report.Visible = true;
            if (IsPostBack == true && txt_todate.SelectedDate != null && txt_fromdate.SelectedDate != null)
            {
                String _todate = txt_todate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                String _fromdate = txt_fromdate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                obj_sales.initConnection();
                obj_sales.nwideTotalSalesSummary(_todate, _fromdate);
                grd_report.DataSource = obj_sales.getResults();
                grd_report.DataBind();
            }
        }
        protected void NeedDataSource()
        {
            grd_report.Visible = true;
            if (IsPostBack == true && txt_todate.SelectedDate != null && txt_fromdate.SelectedDate != null)
            {
                String _todate = txt_todate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                String _fromdate = txt_fromdate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                obj_sales.initConnection();
                obj_sales.nwideTotalSalesSummary(_todate, _fromdate);
                grd_report.DataSource = obj_sales.getResults();
                grd_report.DataBind();
            }
        }
        protected void NeedDataSource()
        {
            grd_report.Visible = true;
            if (IsPostBack == true && txt_todate.SelectedDate != null && txt_fromdate.SelectedDate != null)
            {
                String _todate = txt_todate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                String _fromdate = txt_fromdate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                obj_sales.initConnection();
                obj_sales.nwideTotalSalesSummary(_todate, _fromdate);
                grd_report.DataSource = obj_sales.getResults();
                grd_report.DataBind();
            }
        }
        protected void NeedDataSource()
        {
  
protected void NeedDataSource()
{
    grd_report.Visible = true;
    if (IsPostBack == true && txt_todate.SelectedDate != null && txt_fromdate.SelectedDate != null)
    {
        String _todate = txt_todate.SelectedDate.Value.ToString("dd-MMM-yyyy");
        String _fromdate = txt_fromdate.SelectedDate.Value.ToString("dd-MMM-yyyy");
        obj_sales.initConnection();
        obj_sales.nwideTotalSalesSummary(_todate, _fromdate);
        grd_report.DataSource = obj_sales.getResults();
        grd_report.DataBind();
    }
}
protected void PageSizeChanged(object source, Telerik.Web.UI.GridPageSizeChangedEventArgs e)
{
    NeedDataSource();
    grd_report.Rebind();
}
         grd_report.Visible = true;
            if (IsPostBack == true && txt_todate.SelectedDate != null && txt_fromdate.SelectedDate != null)
            {
                String _todate = txt_todate.SelectedDate.Value.ToString("dd-MMM-yyyy");
  
protected void NeedDataSource()
{
    grd_report.Visible = true;
    if (IsPostBack == true && txt_todate.SelectedDate != null && txt_fromdate.SelectedDate != null)
    {
        String _todate = txt_todate.SelectedDate.Value.ToString("dd-MMM-yyyy");
        String _fromdate = txt_fromdate.SelectedDate.Value.ToString("dd-MMM-yyyy");
        obj_sales.initConnection();
        obj_sales.nwideTotalSalesSummary(_todate, _fromdate);
        grd_report.DataSource = obj_sales.getResults();
        grd_report.DataBind();
    }
}
 
protected void PageSizeChanged(object source, Telerik.Web.UI.GridPageSizeChangedEventArgs e)
{
    NeedDataSource();
    grd_report.Rebind();
}
             String _fromdate = txt_fromdate.SelectedDate.Value.ToString("dd-MMM-yyyy");
                obj_sales.initConnection();
                obj_sales.nwideTotalSalesSummary(_todate, _fromdate);
                grd_report.DataSource = obj_sales.getResults();
                grd_report.DataBind();
            }
        }
Abdul
Top achievements
Rank 2
 answered on 26 Nov 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?