Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
306 views
I'm developing a dashboard type web page where I have multiple (6 currently, more will be added later) widgets I would like to load asynchronously after the page loads.  I would like each widget to be it's own UserControl, but if that is not possible, I can put everything on one page.  It is also desired for each widget to have its own loading panel, so a widget is finished loading, their respective panel is hidden and the widget is usable.  

I need these to all begin loading at the same time because each widget is pulling data from different systems and could take several seconds for each one.  If they are loaded serially, it will take a long time for the page to completely load.  I've tried using both the RadAJAXManager and RadAJAXPanels and have been unable to come up with a working solutions.

A similar question was posted (http://www.telerik.com/community/forums/aspnet-ajax/ajax/multiple-radajaxpanel-s-invoked-on-pageload-causes-errors.aspx) but I never saw a solutions posted that worked.

Here is the one version of the code I'm trying.
<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
    <script type="text/javascript">
        function pageLoad(sender, eventArgs) {
            if (!eventArgs.get_isPartialLoad()) {
                $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("LoadWidget1");
                $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("LoadWidget2");
                $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("LoadWidget3");
                $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("LoadWidget4");
                $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("LoadWidget5");
                $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("LoadWidget6");
            }
        }
    </script>
</telerik:RadCodeBlock>
 
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server"></telerik:RadAjaxLoadingPanel>    
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel2" runat="server" BackColor="Red"></telerik:RadAjaxLoadingPanel>    
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel3" runat="server" BackColor="Red"></telerik:RadAjaxLoadingPanel>    
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel4" runat="server" BackColor="Red"></telerik:RadAjaxLoadingPanel>    
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel5" runat="server" BackColor="Red"></telerik:RadAjaxLoadingPanel>    
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel6" runat="server" BackColor="Red"></telerik:RadAjaxLoadingPanel>    
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" RequestQueueSize="10" EnableAJAX="true">
    <AjaxSettings>
        <telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="panel1" LoadingPanelID="RadAjaxLoadingPanel1" />
                <telerik:AjaxUpdatedControl ControlID="panel2" LoadingPanelID="RadAjaxLoadingPanel2" />
                <telerik:AjaxUpdatedControl ControlID="panel3" LoadingPanelID="RadAjaxLoadingPanel3" />
                <telerik:AjaxUpdatedControl ControlID="panel4" LoadingPanelID="RadAjaxLoadingPanel4" />
                <telerik:AjaxUpdatedControl ControlID="panel5" LoadingPanelID="RadAjaxLoadingPanel5" />
                <telerik:AjaxUpdatedControl ControlID="panel6" LoadingPanelID="RadAjaxLoadingPanel6" />
            </UpdatedControls>
        </telerik:AjaxSetting>
    </AjaxSettings>
</telerik:RadAjaxManager>
 
<asp:Panel ID="panel1" runat="server"></asp:Panel><br />
<asp:Panel ID="panel2" runat="server"></asp:Panel><br />
<asp:Panel ID="panel3" runat="server"></asp:Panel><br />
<asp:Panel ID="panel4" runat="server"></asp:Panel><br />
<asp:Panel ID="panel5" runat="server"></asp:Panel><br />
<asp:Panel ID="panel6" runat="server"></asp:Panel><br />


Protected Sub RadAjaxManager1_AjaxRequest(sender As Object, e As Telerik.Web.UI.AjaxRequestEventArgs) Handles RadAjaxManager1.AjaxRequest
    If e.Argument = "LoadWidget1" Then
        System.Threading.Thread.Sleep(1000)
        panel1.Controls.Add(New LiteralControl(Now.ToLongTimeString))
    ElseIf e.Argument = "LoadWidget2" Then
        System.Threading.Thread.Sleep(1000)
        panel2.Controls.Add(New LiteralControl(Now.ToLongTimeString))
    ElseIf e.Argument = "LoadWidget3" Then
        System.Threading.Thread.Sleep(3000)
        panel3.Controls.Add(New LiteralControl(Now.ToLongTimeString))
    ElseIf e.Argument = "LoadWidget4" Then
        System.Threading.Thread.Sleep(4000)
        panel4.Controls.Add(New LiteralControl(Now.ToLongTimeString))
    ElseIf e.Argument = "LoadWidget5" Then
        System.Threading.Thread.Sleep(5000)
        panel5.Controls.Add(New LiteralControl(Now.ToLongTimeString))
    ElseIf e.Argument = "LoadWidget6" Then
        System.Threading.Thread.Sleep(6000)
        panel6.Controls.Add(New LiteralControl(Now.ToLongTimeString))
    End If
End Sub

Any guidance would be greatly appreciated.

Thanks,
Greg
Maria Ilieva
Telerik team
 answered on 08 Nov 2012
1 answer
143 views

Hello Everyone,

We add rows in table dyanmically using javascript. Everything works fine. However, When I use radupload control to upload files, the data entered in table disappears because of full page post back. And without full page postback it is not possible to upload any file.

What could be the alternative to this issue ? Any recommendation is appreciated.

Is there any way/settings raduplaod not require full page postback to upload any file. Or In my scenario how to maintain dynamic table state after page postback ?

Thanks in advance.

Kiran

Plamen
Telerik team
 answered on 08 Nov 2012
3 answers
138 views
I am facing the Telerik RadEditor Issue With ToolbarMode="ShowOnFocus" working with ASP.NET
<telerik:RadEditor ID="RadEditor1" runat="server"  OnClientLoad="OnClientLoad"  EditModes="Design" Width="300px" Height="300px"     Skin="Outlook" ToolbarMode="ShowOnFocus" ToolsFile="~/xml/Tools.xml">                                                   
</telerik:RadEditor>

and add a link button Click me.
<a href="javascript://" onclick="javascript:return Clickme();">Click Me</a>

now on page load i want to load the the tool bar by default, it is happening by doing
    function OnClientLoad(editor, args) {
           editor.setFocus();
          editor.set_html("");
        }

but on anchor click i want to write something on radeditor and the toolbar is not visible. i tried to setFocus and set_html("") both.
function Clickme() {
            var editor = $find("RadEditor1");
           editor.setFocus();
            editor.set_html("");
}

have anyone idea about this issue?

Dobromir
Telerik team
 answered on 08 Nov 2012
1 answer
90 views
<telerik:RadGrid  ID="RadGrid1"
             AllowPaging="true" 
             runat="server" 
                          OnPreRender="RadGrid1_PreRender" 
                          OnItemCommand="RadGrid1_ItemCommand" 
                        OnNeedDataSource="RadGrid1_NeedDataSource1"
                          height="550px"
                          PageSize="40"
                         GridLines="None">
 <MasterTableView  EditMode="InPlace" 
                             CommandItemDisplay="Top" 
                             AutoGenerateColumns="true">

------------------------------------------------------------------------------------------------ 

 

 

foreach (GridColumn column in RadGrid1.MasterTableView.RenderColumns)

 

{

 

 

    if (!string.IsNullOrEmpty(column.UniqueName) && !string.IsNullOrEmpty(column.HeaderText))

 

    {

        columncount++;

        dt.Columns.Add(column.UniqueName,

 

typeof(string));

 

    }

}

 

 


DataRow
dr;

 

 

 

DataTable dtRecords = new DataTable();

 

 

 


foreach
(GridDataItem item in RadGrid1.MasterTableView.Items)

 

{

    dr = dt.NewRow();

 

 

    for (int i = 0; i < columncount + 1; i++)

 

    {

 

 

        foreach (GridBoundColumn col in RadGrid1.MasterTableView.RenderColumns)

 

    {

 

 


    var
iName = item[col.UniqueName].Text;

 

 

 


    if
(Regex.IsMatch(iName, @"^[a-zA-Z]*$"))

 

    {

        dr[col.UniqueName] = iName;

    }

}

 

 

 

I have defined a grid using only AutoGeneratedColumns - bound using OnNeedDataSource. On ItemCommand, I need access to all AutoGeneratedColumns values - but am only able to access the first row. Unsure what I am doing wrong.

Thank you,

SteveO

 

Eyup
Telerik team
 answered on 08 Nov 2012
6 answers
234 views
Hi, i am using RadEditor in .NET custom control. I've an hyperlink in the content area of the editor. Now, whenever the hyperlink is clicked the radeditor displays its properties in the bottom which can be edited. There are four properties namely: URL, Target, Tooltip and ClassName. Both URL and Tooltip have textbox as their inputs. Is there anyway to increase that textbox dimensions?
I am attaching the screenshot as well for the reference.

Thanks.
Dobromir
Telerik team
 answered on 08 Nov 2012
2 answers
180 views
Hello
I am using quite an old version of radcontrols for asp.net ajax (q3 2008)
I have a NoRecordsTemplate for my grid for when there is no data to display but the grid still shows all of the headers and footers, including some custom aggregates I calculate in the ItemDataBound event and display in the grid footer.
How can i get the grid to show nothing else apart from the NoRecordsTemplate when there is no data?

thanks
andieje
Top achievements
Rank 1
 answered on 08 Nov 2012
1 answer
128 views
Hi,
My db contains a field date of birth. Its of type datetime. But in grid I want to show only the date. Im using boundcolumn for displaying dob. Can you provide a solution.

thanks in advance
Savyo
Shinu
Top achievements
Rank 2
 answered on 08 Nov 2012
5 answers
293 views
Hi Freinds,
I have a radgrid with data in the grid having timing as hh:mm:ss whenever i click in excel export the containing hh:mm:ss that get converted to Total second in excel, i bind my radgrid with datatable having timing as total second (60 i.e get converted to 00:01:00 with timespan) but when i export it to excel it shows me as 60 in the column but actualy radgrid contains 00:01:00. Excel also should show 00:01:00. I hav also used

RadGrid1.ExportSettings.Excel.Format = Telerik.Web.UI.

GridExcelExportFormat.ExcelML;
RadGrid.MasterTableview.ExportToExcel()
and

 

RadGrid1_ExcelMLExportStylesCreated,

 

RadGrid1_ExcelMLExportRowCreated.

 

 

I just want get whatever in radgrid as it is in excel.

How to achieve this please let me know.

Thanks in advance.
Manoj Gupta

Daniel
Telerik team
 answered on 08 Nov 2012
3 answers
159 views
Hi,

I need to have a Scheduler / Reminders with reminders.. how can I do this.

Thanks,Chandu
Plamen
Telerik team
 answered on 08 Nov 2012
8 answers
273 views
Hi ,
I have a telerik rad grid  binded on client side using ajax call.In order to Export the Excel and Pdf ,I have a two button for Excel and PDf  out side the grid and on button click the data will be exported from excel  from  a data table which is binded the radgrid  data source . Export to Excel was working as the expected ,but when i click for export to pdf....the  message says " xxxxxxxxx.pdf is Protected.Please Enter a document Open password".I have tried with different passwords and by enabling and disabling the User password in pdf setting .But of no use.Can any one help me out in this please.Below is the code i had used for exporting to pdf.
 In Button Click event
{
             datatable dt;
             RadGrid.DataSource = dt;
            RadGrid.ExportSettings.IgnorePaging = true;
            RadGrid.DataBind();
            RadGrid.MasterTableView.AllowPaging = true;
            RadGrid.MasterTableView.IsItemInserted = true;
            RadGrid.ExportSettings.OpenInNewWindow = true;
            RadGrid.AllowFilteringByColumn = false;
            RadGrid.ExportSettings.ExportOnlyData = true;
            RadGrid.MasterTableView.HierarchyDefaultExpanded = false;
            RadGrid.MasterTableView.ClearChildEditItems();
            RadGrid.ExportSettings.FileName = filename;
 //RadGrid.ExportSettings.Pdf.UserPassword = "XXXX";
             RadGrid.ExportSettings.Excel.Format = GridExcelExportFormat.Html;
            RadGrid.MasterTableView.ExportToPdf();
            RadGrid.Rebind();
}

Kostadin
Telerik team
 answered on 08 Nov 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Dean
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Emil
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Dean
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Emil
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?