Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
155 views
I am using the RadUpdate/ProgressArea control to allow a user to upload a file and then view the status of the import process. The first progress bar is handled automatically during the update process by the progress area. The second part of the process, the import, I am using the secondary progress bar to give them feedback (processing line x of y).

************* ERROR MESSAGE *****************

RadUpload Ajax callback error. Source url returned invalid content:

var rawProgressData = {InProgress:true,ProgressCounters:true,PrimaryPercent:'100'System.InvalidOperationException: Collection was modified; enumeration operation may not execute.

   at System.ThrowHelper.ThrowInvalidOperationException(ExceptionResource resource)
   at System.Collections.Generic.Dictionary`2.KeyCollection.Enumerator.MoveNext()
   at Telerik.Web.UI.Upload.ProgressData.Serialize(TextWriter writer)
   at Telerik.Web.UI.RadProgressContext.Serialize(TextWriter writer)
   at Telerik.Web.UI.RadUploadProgressHandler.ProcessRequest(HttpContext context)

Telerik.RadUploadProgressHandler.ashx?RadUrid=9ab592e1-0d6a-43f2-8f5e-9eddc5e20105

Did you register the RadUploadProgressHandler in web.config?

Please, see the help for more details: RadUpload for ASP.NET Ajax - Configuration - RadUploadProgressHandler.

***************** End of Error ******************


Any ideas what is causing this?

Thanks!




**************** Sample Code ********************
UploadedFile file = UploadedFile.FromHttpPostedFile(Request.Files[0]);

string fileName = MapPath("uploads") + "\\" + file.GetName();

file.SaveAs(fileName, true);

if (!Object.Equals(file, null))
{
     importFile(fileName);
}


 private void importFile(string fileName)
    {
        ArrayList lines = new ArrayList();

        RadProgressContext progress = RadProgressContext.Current;
        DateTime startTime = DateTime.Now;

        progress.SecondaryTotal = 100;
        progress.SecondaryValue = 0;
        progress.SecondaryPercent = 0;
        progress.CurrentOperationText = "Reading File..";

        StreamReader reader = new StreamReader(fileName);

        try
        {
            int totalLines = 0;

            while (!reader.EndOfStream)
            {
                totalLines++;
                lines.Add(reader.ReadLine());
            }
            
            progress.SecondaryTotal = totalLines;
            progress.CurrentOperationText = "Importing Data...";

            for (int line = 0; line < totalLines; line++)
            {
                    //progressContext.PrimaryPercent = (int)Math.Round(((decimal)i / count) * 100, 0);
                    progress.SecondaryValue = line;
                    progress.CurrentOperationText = "Importing Data...(" + line + " of " + totalLines + ")";

                TimeSpan elapsed = DateTime.Now.Subtract(startTime);
                progress.TimeElapsed = string.Format("{0:D2}:{1:D2}:{2:D2} s", elapsed.Hours, elapsed.Minutes, elapsed.Seconds);

                double estimatedMillisecons = 24 * 60 * 60 * 1000;
                if (line != 0)
                {
                    estimatedMillisecons = totalLines * elapsed.TotalMilliseconds / line;
                }
                TimeSpan estimated = TimeSpan.FromSeconds(1);
                if (estimatedMillisecons > 1)
                {
                    estimated = TimeSpan.FromMilliseconds(estimatedMillisecons);
                }
                progress.TimeEstimated = string.Format("{0:D2}:{1:D2}:{2:D2} s", estimated.Hours, estimated.Minutes, estimated.Seconds);

                double speed = 0.0d;
                if (elapsed.TotalSeconds > 0)
                {
                    speed = line / elapsed.TotalSeconds;
                }
                progress.Speed = string.Format("{0:0.00} steps/s", speed);

                if (!Response.IsClientConnected)
                {
                    //Cancel button was clicked or the browser was closed, so stop processing
                    break;
                }
            }
        }
        catch (Exception ex)
        {
            App.ProcessException(this, ex);
            throw ex;
        }
        finally
        {
            if (reader != null)
                reader.Close();
        }
    }   


Hristo Valyavicharski
Telerik team
 answered on 23 Mar 2016
1 answer
239 views
 angular.js:11358 RangeError: Maximum call stack size exceeded
    at kendo.all.min.js:78
    at Object.a [as compile] (kendo.all.min.js:78)
    at e.support.browser.msie.e.support.browser.version.e.Observable.extend._compileFormula (kendo.all.min.js:77)
    at .<anonymous> (kendo.all.min.js:77)
    at e.support.browser.msie.e.support.browser.version.e.Observable.extend.batch (kendo.all.min.js:77)
    at e.support.browser.msie.e.support.browser.version.e.Observable.extend.fromJSON (kendo.all.min.js:77)
    at e.support.browser.msie.e.support.browser.version.e.Observable.extend.fromJSON (kendo.all.min.js:78)
    at new e.support.browser.msie.e.support.browser.version.e.Observable.extend.init (kendo.all.min.js:78)
    at new e.support.browser.msie.e.support.browser.version.e.ui.Widget.extend.init (kendo.all.min.js:85)
    at HTMLDivElement.<anonymous> (kendo.all.min.js:26)

 

I am trying to load about 29 thousand rows of data into the kendo spreadsheet and I get the above error. What I am doing is converting data from a ExcelPackage to a Telerik.Web.Spreadsheet workbook on the back-end. Then I convert the workbook via the ToJson method, send that data to the front-end, parse the received string data to a JSON and then load that JSON into the spreadsheet directly as a object or via the spreadsheet.fromJSON(data) method.

It works for less data, but doesn't for this. Also I can have hundreds of thousands of rows with no problems but with data it's another story. Can you tell me if there is some better way to do this, or how to work around this error.

Thank you in advance.

Bozhidar
Telerik team
 answered on 23 Mar 2016
0 answers
84 views

Hi,

I want to make mediaplayer playist back color black. I also want to change the font color and image size.

 

Could you help.

Ali
Top achievements
Rank 1
 asked on 23 Mar 2016
1 answer
50 views

Hi, I have issues with custom button / markup in RadEditor. Here's my scenario:

 

- I have a custom button added through: Telerik.Web.UI.Editor.CommandList[rteButtonCommand] ...

- Then I show some external dialog ( editor.showExternalDialog(...) ) which returns back some markup.

- I inject that markup where the cursor was, ie. like:

<div class="some-css-class">

[myCustomComponent]123456789[/myCustomComponent]

</div>

- Instead of having that custom tag, I would like to show some image instead indicating what kind of component it is and more importantly be able to select it like an image and be able to move it or bring back the dialog with selected values. 

 

I read quite a lot of reference, but couldn't find anything related. 

 

Can anybody help me with this?

 

Thanks

Ianko
Telerik team
 answered on 23 Mar 2016
1 answer
278 views

Hi,

 

I have faced a problem with Rad Editor that When we change font size to maximum of content and export to PDF, the text is overlap. Igo through the followint demo and able to replicate the issue..

http://demos.telerik.com/aspnet-ajax/editor/examples/import-export/pdf-export/defaultcs.aspx

 

After i changed font size, Please see the attchment name STEP1.png

Then exported to PDF, the text overlap between the lines. Please see the attachment name Result.png

Please help me.

Ianko
Telerik team
 answered on 23 Mar 2016
3 answers
51 views

Hello All,

In my page I have 3 RadHtmlChart placed inside the RadDock control in my aspx page.

All the 3 RadHtmlChart constructed as a separate page. pragmatically loaded them in RadDock.

when the window resize happens only the last chart get repainted whereas the other 2 still remains the same.

please do the needful its bit urgent.

Many Thanks

Amjath

Amjath
Top achievements
Rank 1
 answered on 23 Mar 2016
2 answers
61 views

so it look similar as on grid view?  then I could add custom filtering to it.

thanks

Robert
Top achievements
Rank 1
 answered on 22 Mar 2016
2 answers
172 views

I have a radwindow, inside of which is a div with overflow-y:scroll. Inside the div is a radlistbox. The idea is to allow
scrolling to the bottom of the sometimes long list of items to be checked and unchecked in the listbox. Upon page load if
you don’t scroll the listbox, the checkboxes work and I am able to check and uncheck items in the list. However, if I
scroll, to view more items, I cannot check any checkboxes because the radlistbox first scrolls to the top, and then ignores
the click attempt. I have tried autopostback=false, and causesvalidation=false with no success. How do I work around this?

NOTE: This “feature” only exists in IE. In Firefox, I can check and uncheck regardless of the position of the scroll.

There was another post about this a year ago, but it was never properly addressed:
http://www.telerik.com/forums/list-box-scrolling-to-top-when-checkbox=true

(IIS 7.5, Windows Server 2012, VS 2012, C#, ASP.NET, Telerik runtime version 4.0.30319, IE11, Firefox 45.0)


Paul
Top achievements
Rank 1
 answered on 22 Mar 2016
5 answers
48 views

I'm new to Telerik controls.  I've inherited an ASP.NET project and downloaded the latest controls last week, and went through the upgrade wizard in Visual Studio 2015 (the previous developer had used a 2013 version).

Just about everything works on my development computer as it works on our production site, but one thing that got broken is that in the Month View I no longer see the Day # in the left corner of each box (i.e. today is March 16, so I would expect to see "16" as link to that day).

Here's the MonthView tag on the .aspx page:

<MonthView AdaptiveRowHeight="false" VisibleAppointmentsPerDay="100" ShowDateHeaders="true" DayHeaderDateFormat="dd" />

Besides the ShowDateHeaders setting, where else might I have to look for rendering the day number?

 

Ivan Danchev
Telerik team
 answered on 22 Mar 2016
0 answers
169 views

Along with our long-term vision to achieve visual consistency among the build-in skins of our controls, the MetroTouch skin for RadPanelBar in Lightweight RenderMode has been improved with the Q1 2016.1.225 SP1 release.

The changes implemented are as follows:

  • The foreground color of the items has been changed to darker gray;
  • The padding of items has been changed;
  • The indent of items has been changed;
  • Additional animated selection of items has been added, using CSS rules; 

In addition to the above, the predefined font for almost all skins has been removed.

In some cases, these changes could result in undesired change of look and feel of the RadPanelBar. In order to revert back the styling of the control to its MetroTouch look from before the Q1 2016.1.225 SP1 release, one could apply the following CSS rules:

html .RadPanelBar_MetroTouch {
    color: #767676;
    font-size: 16px;
}
 
html .RadPanelBar_MetroTouch .rpLink {
    padding: 0 16px;
}
 
html .RadPanelBar_MetroTouch .rpGroup .rpLink {
    padding-top: 4px;
    padding-bottom: 4px;
    border: 1px solid transparent;
}
 
html .RadPanelBar_MetroTouch .rpRootLink {
    color: inherit;
    padding-top: 5px;
    padding-bottom: 4px;
    font-size: 1.375em;
    line-height: 2em;
}
 
html .RadPanelBar_MetroTouch .rpLevel1 .rpLink {
    line-height: 1.25em;
}
 
html .RadPanelBar .rpLevel2 .rpLink {
    padding-left: 2em;
}
 
html .RadPanelBar .rpLevel3 .rpLink {
    padding-left: 3em;
}
 
html .RadPanelBar_MetroTouch .rpLink .rpHovered {
    background-color: transparent;
    border-color: transparent;
}

Telerik Admin
Top achievements
Rank 1
Iron
 asked on 22 Mar 2016
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?