Any ideas?
throw new Error("Unhandled Error in Silverlight 2 Application at System.Net.AsyncHelper.BeginOnUI(SendOrPostCallback beginMethod, Object state)\n at System.Net.BrowserHttpWebRequest.EndGetResponse(IAsyncResult asyncResult)\n at Telerik.Windows.Controls.FileUploader.OnResponse(IAsyncResult asyncResult)\n at System.Net.BrowserHttpWebRequest.<>c__DisplayClassd.<InvokeGetResponseCallback>b__b(Object state2)\n at System.Threading._ThreadPoolWaitCallback.WaitCallback_Context(Object state)\n at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)\n at System.Threading._ThreadPoolWaitCallback.PerformWaitCallbackInternal(_ThreadPoolWaitCallback tpWaitCallBack)\n at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback(Object state)");
21 Answers, 1 is accepted
Please follow the steps bellow:
- Check information initialized in UploadServiceUrl and TargetFolder;
- If the info is OK (the paths are the correct ones), please try to access the upload handler directly in your browser and check whether the response looks like:
{"JSONData":[{"Key":"RadUAG_message","Value":"Empty file name"},{"Key":"RadUAG_success","Value":false}]} - If the response is OK please check whether the target folder is physically available and the access rights are OK;
- A possible reason may be if you are trying to upload across different domains. If this is the case please follow the instructions at Making a Service Available Across Domain Boundaries.
Best wishes,
Ivan
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
This is already fixed and the bits will be available later this week as part of the SP release.
Greetings,
Valentin.Stoychev
the Telerik team
Check out Telerik Trainer , the state of the art learning tool for Telerik products.
http://tv.telerik.com/watch/silverlight/video/telerik-silverlight-controls-and-sharepoint-2010-part-5
(Uploading Large Files into SharePoint by using Telerik SilverLight...)
I can get my handler to work if I derive from iHttpHandler, but when I try to derive from RadUploadHandler, I get 401 errors.
Is this becuase the example just won't work with Integrated Windows Authentication?
Thanks,
John
Can you please tell us which version (build) of the Telerik assemblies you are using?
All the best,
Alex Fidanov
the Telerik team
The file version of RadUploadHanlder I am referencing is : 2010.3.1110.35. It is the trial version of 'RadControls for Silverlight Q3 2010'
-John
We are going to look into this, but we will need some time to test this in a real Share Point project. If you have one at hand, it would be great if you sent it to us. Otherwise, I will update you as soon as I have more information on this issue.
All the best,
Alex Fidanov
the Telerik team
Please take a look at this forum post about windows authentitcation and RadUpload. You can also review this link about share point windows authentication. Please let us know if they are helpful.
Regards,
Alex Fidanov
the Telerik team
I faced the same problem and found that different versions of telerik DLL's works in different way. Just run the fiddler and see where it trying to find the handler file. in my case ~ made a big difference with different versions of the telerik DLL's one version looks at the root of the folder and the other version looks at the current folder. I dont why this should make a big difference.
Regards,
Nagendra
First of all, let me assure you that whenever we are updating our controls, we do our best to keep a backward compabilty and not introduce many changes in the logic of the controls.
However, the RadUpload control was significantly improved since its initial implementation. I am not sure what version of the controls you are using, but currently if the path to the UploadHandler begins with "/" or "~/" then it is relative to the root of the domain where the Silverlight application had been loaded.
I hope this info will help you. Still, if you have any issues, please let us know and we will gladly assist you in implementing your scenarios with our controls.
Regards,
Tina Stancheva
the Telerik team
I have been facing this problem for two days now. I'm using the trail version of Telerik silverlight (the latest version I can dowload today) and using it in SP 2010 (running locally on Vista 64-bit) on my laptop.
I have the .ashx file in the layouts folder (just as demonstrated in the video by Sahil Malik) and the .ashx.cs in the root of the solution for SP2010.
Strangely enough, if the handler class is derived from iHttpHandler, all works fine, and I hit a breakpoint as expected. But if I derive my handler class from RadUploadHandler, I get the error "Handler not found....."
So, apparently the path is ok. Can someone help?. I'm feeling it has something to do with the Telerik.Windows.RadUploadHandler DLL?
Any help will be appreciated.
Thank you.
Try running fiddler and see what is the path of handler the request is trying to hit.
Regards,
Nagendra
Thanks for the response.
I'm not very familiar using Fiddler. I have it installed. Can you tell me what I should be checking?
I do get a 404 error though.
As I had mentioned, the path should be ok?
What I do not understand is why I get a 404, if the handler class is derived from RadUploadHandler, but I actually hit a breakpint just fine in my cs code, if the class is derived from iHtttpHandler?.
In both case, I'm not changing the path at all.
The RadUploadHandler handles the upload requests properly in a SharePoint enviroment on condition that:
1. In the UploadHandler.ashx file definition, you need to indicate the full assembly name of the assembly that contains the class that will handle the upload requests. For example if the UploadHandler class should handle the requests and it is in the UploadProject assembly, the following line has to be included in the UploadHandler.ashx file definition:
<%@ WebHandler Language="C#" Class="UploadProject.UploadHandler, UploadProject, Version=1.0.0.0, Culture=neutral, PublicKeyToken=3173a0160b767e01" %>
2. Include the Telerik.Windows.RadUploadHandler.dll into the SharePoint project Package - To ensure that the Telerik.Windows.RadUploadHandler.dll is included in your WSP you have to open the Package Configuration - just open the "Package" node in your SharePoint project and then double click the given entry. Scroll down to the end of the screen and open the Manifest. Make sure it contains the following line:
<Assembly Location="Telerik.Windows.RadUploadHandler.dll" DeploymentTarget="GlobalAssemblyCache"/>
If it doesn't, that means that the Telerik.Windows.RadUploadHandler.dll isn't included in the Package. In order to include it you need to open the Advanced mode. Then use the Add button to Add Existing Assembly and select the Telerik.Windows.RadUploadHandler.dll.
You can examine this forum thread as it will give you further information and you can also download a sample solution demonstrating how to use the RadUpload control in a SharePoint enviroment.Let us know if the information helps.
Regards,
Tina Stancheva
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
Thank you
The solution you mentioned worked for me only when this is a farm solution.
My challenge is that I need to make this work within a Sandbox solution. So, unlike all the examples and videos mentioned and illustrated here, I cannot use the LAYOUTS folder withing my Visual studio solution.
So, my question is, where should the Uploadhandler.ashx and the UploadHandler.cs be placed?.
Can anyone help and let me know on this?. Where exactly do you keep the handlers, so it works in a Sandbox solution?
Thank you.
There isn't a required place for the UploadHandler. The only requirement is that the Silverlight client-part with the RadUpload control needs access to the upload handler. This is why you can place it in any shared folder/accessible destination on any of your servers as long as the client-side of the RadUpload can access it.
All the best,
Tina Stancheva
the Telerik team
Thanks again.
The problem I have now is that althogh I've put the code in the markup in the same file .ASHX and not separate .cs file, this was needed since it is a sandbox solution.
Forget the radupload control, but I'm not even gettiing the JSON back from the handler itself. The handler can't find the Telerik RadUpload DLL.
Mind you I've already included the DLL in my package manifest. Here is what it looks like:
<
Solution
xmlns
=
"http://schemas.microsoft.com/sharepoint/"
SolutionId
=
"55505cf1-886e-4783-a24d-3c40737db3cc"
SharePointProductVersion
=
"14.0"
>
<
Assemblies
>
<
Assembly
Location
=
"Telerik.Windows.RadUploadHandler.dll"
DeploymentTarget
=
"GlobalAssemblyCache"
/>
<
Assembly
Location
=
"SandBoxFileUpload.dll"
DeploymentTarget
=
"GlobalAssemblyCache"
/>
</
Assemblies
>
<
FeatureManifests
>
<
FeatureManifest
Location
=
"SandBoxFileUpload_Feature1\Feature.xml"
/>
</
FeatureManifests
>
</Solution
But when I try to check the handler itself, instead of getting the JSON data I get error that the DLL is not found. I'm now lost.
Can you help?.
If this helps this solotion works perfectly if this was a farm solution, and I had a _layouts folder. But that is not the case, and I need to work in a sandbox solution.
I already posted an answer in your other thread, still in case someone is following this thread as well, I will post the same information here:
When you add the Assembly tag with the Name property, the handler will be looking for the targeted assembly in the GAC. This is why you need to make sure that the Telerik.Windows.RadUploadHandler.dll is in the GAC.
Kind regards,
Tina Stancheva
the Telerik team
Thank you for the answeer. It did not solver my problem though.
If my class code is inside the same file .ASHX (no code behind) then it works perfectly, if I put the RadUploadHandler in the GAC. However, please note this is not an acceptable solution. I need to deply in a SharePoint Sandbox solution. This means no assembly in the GAC either.
So, my question is how to make it work, without putting the RadUploadHandler in the GAC. If I put a code behind, of the handler in a separate .cs file, will this work?. And if so, where do i place the .cs file?.
Thank you.
Unfortunately I am not aware of other approaches for implementing your solution.
All the best,
Tina Stancheva
the Telerik team