Hello, I recently had to upgrade Telerik.Web.UI.dll on a client's server (DNN 06.01.05) to 2013.2.717.35 (previous version installed was 2011.*.*.35). I had to do this because I installed some customizations where I use the latest Telerik.dll version that is suitable for IE10 and all that stuff. Then I set up an assembly binding on web.config forcing old functionallity to use new version of the library.
Everything went fine until we discovered a problem trying to upload a file using FileExplorer on a DNN built in feature (not my customization)
It seems that the signature of get_ContentLength() has changed in latest builds from returning an Int32 to an Int64.
The horror!
I'm in DNN 6. I tried to set an assembly binding on web.config to use both versions of the dll (previous DNN functionality using telerik version 2011 and my assemblies using Telerik version 2013). This seems to be working but now I'm getting an internal DNN error:
Since DNN is a very popular CMS I thought may be someone faced the same scenario and could give me a hand.
Any ideas on how to solve this problem?
Thanks in advance.
Juan
Everything went fine until we discovered a problem trying to upload a file using FileExplorer on a DNN built in feature (not my customization)
[MissingMethodException: Method not found: 'Int32 Telerik.Web.UI.UploadedFile.get_ContentLength()'.]
DotNetNuke.Providers.RadEditorProvider.TelerikFileBrowserProvider.StoreFile(UploadedFile file, String path, String name, String[] arguments) +0
Telerik.Web.UI.RadFileExplorer.ProcessUploadedFiles() +1134
Telerik.Web.UI.RadFileExplorer.OnLoad(EventArgs e) +248
System.Web.UI.Control.LoadRecursive() +71
System.Web.UI.Control.LoadRecursive() +190
System.Web.UI.Control.LoadRecursive() +190
System.Web.UI.Control.LoadRecursive() +190
System.Web.UI.Control.LoadRecursive() +190
System.Web.UI.Control.LoadRecursive() +190
System.Web.UI.Control.LoadRecursive() +190
System.Web.UI.Control.LoadRecursive() +190
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3064
It seems that the signature of get_ContentLength() has changed in latest builds from returning an Int32 to an Int64.
The horror!
I'm in DNN 6. I tried to set an assembly binding on web.config to use both versions of the dll (previous DNN functionality using telerik version 2011 and my assemblies using Telerik version 2013). This seems to be working but now I'm getting an internal DNN error:
The base class includes the field '<
componentName
>', but its type (Telerik.Web.UI.RadWindowManager) is not compatible with the type of control (Telerik.Web.UI.RadWindowManager).
Since DNN is a very popular CMS I thought may be someone faced the same scenario and could give me a hand.
Any ideas on how to solve this problem?
Thanks in advance.
Juan
15 Answers, 1 is accepted
0
Hi Juan,
Please, note that version 5.0 or later of DNN uses the Professional provider of RadEditor, which is implementation of the DNN developers and it is not supported by Telerik. Our suggestion is to post your question in the DNN forums and contact the support of DNN for help.
In addition, we are not aware of such problem with RadEditor outside of DNN environment. Are you able to reproduce this error in a standard ASP.NET page? If so, could you please provide sample fully runnable project demonstrating the issue so we can examine and debug it locally?
Regards,
Veselina Raykova
Telerik
Please, note that version 5.0 or later of DNN uses the Professional provider of RadEditor, which is implementation of the DNN developers and it is not supported by Telerik. Our suggestion is to post your question in the DNN forums and contact the support of DNN for help.
In addition, we are not aware of such problem with RadEditor outside of DNN environment. Are you able to reproduce this error in a standard ASP.NET page? If so, could you please provide sample fully runnable project demonstrating the issue so we can examine and debug it locally?
Regards,
Veselina Raykova
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
0
Juan
Top achievements
Rank 1
answered on 30 Sep 2013, 10:24 PM
Hi Veselina, thanks for your reply.
Regarding reproducing the issue, well, its a change on a signature's method. I could be wrong but it seems evident that code compiled against a method expecting an Int32 would fail when you install an update and the same method returns an Int64 (after setting up an assembly binding, etc.)
I'll try to create a smaller project as an example if I have time later this week.
In the meantime, would you be so kind to confirm in which version of Telerik.dll was this change introduced? I tried searching in the release notes but I coudln't find this specific information.
Thansk in advance.
Juan
Regarding reproducing the issue, well, its a change on a signature's method. I could be wrong but it seems evident that code compiled against a method expecting an Int32 would fail when you install an update and the same method returns an Int64 (after setting up an assembly binding, etc.)
I'll try to create a smaller project as an example if I have time later this week.
In the meantime, would you be so kind to confirm in which version of Telerik.dll was this change introduced? I tried searching in the release notes but I coudln't find this specific information.
Thansk in advance.
Juan
0
Hi Juan,
The mentioned change was introduced in the Q2 2013 BETA (2013.2.522) version of RadControls. This improvement has been made in use of the following functionality:
Improved: In order to upload files bigger than 2GB the type of the ContentLength properties in the AsyncUpload is changed to Int64.
You might also find interesting the notes from this release, available here.
Hope this helps.
Kind regards,
Veselina Raykova
Telerik
The mentioned change was introduced in the Q2 2013 BETA (2013.2.522) version of RadControls. This improvement has been made in use of the following functionality:
Improved: In order to upload files bigger than 2GB the type of the ContentLength properties in the AsyncUpload is changed to Int64.
You might also find interesting the notes from this release, available here.
Hope this helps.
Kind regards,
Veselina Raykova
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
0
Juan
Top achievements
Rank 1
answered on 04 Oct 2013, 02:46 PM
Thank you very much Veselina!
0
Kevin
Top achievements
Rank 1
answered on 10 Oct 2013, 09:51 PM
So how do I fix this code then? Can I simply convert the Int64 to Int32?
foreach (UploadedFile file in RadAsyncUpload1.UploadedFiles)
{
foreach (UploadedFile file in RadAsyncUpload1.UploadedFiles)
{
byte[] bytes = new byte[file.ContentLength];
file.InputStream.Read(bytes, 0, file.ContentLength);
}
file.InputStream.Read() requires an int for the third argument, not a long.
0
Hi Kevin,
Yes, you can simply cast the ContentLenght value to Int32 - the only difference will be that you will not be able to upload files bigger than 2GB.
Regards,
Veselina Raykova
Telerik
Yes, you can simply cast the ContentLenght value to Int32 - the only difference will be that you will not be able to upload files bigger than 2GB.
Regards,
Veselina Raykova
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
0
Kevin
Top achievements
Rank 1
answered on 15 Oct 2013, 02:39 PM
Thanks for the reply. That is what I did - I cast the value to Int32.
So just curious then, how would I go about uploading a file larger than 2G? file.InputStream.Read() won't work with a long. Is there another method available for file.InputStream?
So just curious then, how would I go about uploading a file larger than 2G? file.InputStream.Read() won't work with a long. Is there another method available for file.InputStream?
0
Hi Kevin,
This is limitation of the framework and there is no much we can do. The Microsoft reccomendation on the subject is to read content of the files bigger than 2GB in more than one parts, so each of them will be less than Int32 and could be proceed in InputStream.Read().
This issue was discussed in many places in the net so I would suggest you to dig a little dipper into the problem in order to find how to workaround it. For example, you can start your research here:
Reading large file using byte[] gives error
Regards,
Veselina Raykova
Telerik
This is limitation of the framework and there is no much we can do. The Microsoft reccomendation on the subject is to read content of the files bigger than 2GB in more than one parts, so each of them will be less than Int32 and could be proceed in InputStream.Read().
This issue was discussed in many places in the net so I would suggest you to dig a little dipper into the problem in order to find how to workaround it. For example, you can start your research here:
Reading large file using byte[] gives error
Regards,
Veselina Raykova
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
0
Tony
Top achievements
Rank 1
answered on 20 Feb 2014, 04:39 PM
Hi guys,
i am still getting the same error: Method not found: 'Int32 Telerik.Web.UI.UploadedFile.get_ContentLength()'.
i did the following:
var bytes = new byte[(Int32)file.ContentLength];
file.InputStream.Read(bytes, 0, (Int32)file.ContentLength);
Any ideas?
Thanks
i am still getting the same error: Method not found: 'Int32 Telerik.Web.UI.UploadedFile.get_ContentLength()'.
i did the following:
var bytes = new byte[(Int32)file.ContentLength];
file.InputStream.Read(bytes, 0, (Int32)file.ContentLength);
Any ideas?
Thanks
0
Kevin
Top achievements
Rank 1
answered on 20 Feb 2014, 06:46 PM
I used this:
byte
[] bytes =
new
byte
[file.ContentLength];
file.InputStream.Read(bytes, 0, (
int
)file.ContentLength);
0
Tony
Top achievements
Rank 1
answered on 20 Feb 2014, 07:08 PM
same error.
Thanks.
Thanks.
0
Tony
Top achievements
Rank 1
answered on 21 Mar 2014, 08:36 PM
can anybody help on this?
0
Hello Tony,
If you are not able to resolve the issue with the previously provided suggestions, I would recommend you opening a proper support ticket with a simple, locally runnable project that demonstrates the encountered issue.
Regards,
Ianko
Telerik
If you are not able to resolve the issue with the previously provided suggestions, I would recommend you opening a proper support ticket with a simple, locally runnable project that demonstrates the encountered issue.
Regards,
Ianko
Telerik
Build cross-platform mobile apps using Visual Studio and .NET. Register for the online webinar on 03/27/2014, 11:00AM US ET.. Seats are limited.
0
ABA
Top achievements
Rank 1
answered on 06 Mar 2016, 10:57 PM
Hello,
sorry to reopened this question. i have the same problem, and i search a solution. i want to modify the source but i don't know which one i should modify. any help please.
0
Hi,
The thread here is related to a two years old version and it is very likely that the problem encountered to be irrelevant to the discussion.
Therefore, it is suggested to open a support ticket or new forum post with more details about the problem encountered, the scenario and the version you are using. And, if possible, providing some code snippets or even better, a simple, locally runnable project which isolates the issue.
Regards,
Ianko
Telerik
The thread here is related to a two years old version and it is very likely that the problem encountered to be irrelevant to the discussion.
Therefore, it is suggested to open a support ticket or new forum post with more details about the problem encountered, the scenario and the version you are using. And, if possible, providing some code snippets or even better, a simple, locally runnable project which isolates the issue.
Regards,
Ianko
Telerik
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Feedback Portal
and vote to affect the priority of the items