RadAsyncUpload in SharePoint 2010

10 posts, 0 answers
  1. Richard
    Richard avatar
    15 posts
    Member since:
    May 2012

    Posted 30 Sep 2013 Link to this post

    Hi,

    I am trying to use RadAsyncUpload control in SharePoint but so far I am having no luck.

    First of all, I have to say that I have found very little documentation to help me on this. I am currently stuck at a point where I keep getting the following error when I select a file:

    Error: Unhandled Error in Silverlight Application Failed to Invoke: _onSilverlightError.   at System.Windows.Browser.ScriptObject.Invoke(String name, Object[] args)
       at UploadPrototype.EventManager.SilverlightError(String message, Int32 index)
       at UploadPrototype.MainPage.<>c__DisplayClass1f.<ProcessResponse>b__18()

    I have uploaded a screenshot that shows where exactly the error is thrown in ure JS. I have also uploaded a screen shot that shows the UI.

    Can you please clarify what I need to do to get this to work in SharePoint 2010? What changes do I need to make to the Web.Config?

    Thanks
  2. Genady Sergeev
    Admin
    Genady Sergeev avatar
    1596 posts

    Posted 02 Oct 2013 Link to this post

    Hi,

    As it seem you don't have the Telerik.Web.UI.WebResource handler registered in the web.config. Please make sure that you follow the steps, that explain how to register the handler, listed in the RadAsyncUpload troubleshooting article.


    Regards,
    Genady Sergeev
    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.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Richard
    Richard avatar
    15 posts
    Member since:
    May 2012

    Posted 03 Oct 2013 Link to this post

    Hi Genady,

    That does not help.

    Can you kindly detail what exact changes i need to make to my web.config to make this work on sharepoint? Please do not post links as i have spent hours going through all sorts of links and the reason i posted a question in this forum was to get a specific answer from you.
  5. Genady Sergeev
    Admin
    Genady Sergeev avatar
    1596 posts

    Posted 08 Oct 2013 Link to this post

    Hello Richard,

    Please make sure that you have the following handler registered in the handlers section of the web.config:

    <add name="Telerik.Web.UI.WebResource" 
    path="Telerik.Web.UI.WebResource.axd" verb="*"  
    type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Culture=neutral, PublicKeyToken=121fae78165ba3d4"/>

    If you are using IIS6.0 or the Visual Studio integrated server the registration should go the HttpHandlers section. In that case the registration should look like:

    <add path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Culture=neutral, PublicKeyToken=121fae78165ba3d4" verb="*" validate="false"/>



    Regards,
    Genady Sergeev
    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.
  6. Richard
    Richard avatar
    15 posts
    Member since:
    May 2012

    Posted 08 Oct 2013 Link to this post

    I have added it and I am getting the same error (version of telerik 2012.1.501.35):

    SCRIPT5022: Exception thrown and not caught
    ScriptResource.axd, line 239 character 8
    SCRIPT5022: Unhandled Error in Silverlight Application The remote server returned an error: NotFound.   at System.Net.Browser.AsyncHelper.BeginOnUI(SendOrPostCallback beginMethod, Object state)
       at System.Net.Browser.BrowserHttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
       at UploadPrototype.MainPage.ProcessResponse(IAsyncResult asyncResult)
       at System.Net.Browser.BrowserHttpWebRequest.<>c__DisplayClass19.<InvokeGetResponseCallback>b__17(Object state2)
       at System.Threading.QueueUserWorkItemCallback.WaitCallback_Context(Object state)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
       at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
       at System.Threading.ThreadPoolWorkQueue.Dispatch()
       at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()
    eval code (61), line 1 character 1
    SCRIPT5022: Unhandled Error in Silverlight Application Failed to Invoke: _onSilverlightError.   at System.Windows.Browser.ScriptObject.Invoke(String name, Object[] args)
       at UploadPrototype.EventManager.SilverlightError(String message, Int32 index)
       at UploadPrototype.MainPage.<>c__DisplayClass1f.<ProcessResponse>b__18()
    eval code (62), line 1 character 1
  7. Genady Sergeev
    Admin
    Genady Sergeev avatar
    1596 posts

    Posted 11 Oct 2013 Link to this post

    Hello Richard,

    This error tells you that there is no handler registered in the web.config, hence the control complains and says "Not Found". Please make sure that the handlers are registered because this is the only reason AsyncUpload will throw such error.

    In order to verify that the handler is registered try to access the Telerik.Web.UI.WebResource.axd handler the following way:

    http://localhost/{Your web site name}/Telerik.Web.UI.WebResource.axd?type=rau

    An error screen displaying

    { "message" : "RadAsyncUpload handler is registered succesfully, however, it may not be accessed directly." }

    should pop up (because there are no files uploaded, this is just a test request). Is this the case?

    Regards,
    Genady Sergeev
    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.
  8. Richard
    Richard avatar
    15 posts
    Member since:
    May 2012

    Posted 11 Oct 2013 Link to this post

    It comes up with an error complaining that the telerik dll was not found. However I did a further search and found this:

    http://www.telerik.com/help/aspnet-ajax/introduction-troubleshooting.html

    Which states that if the telerik DLL is in the GAC then the handler needs to be registered like this:

    <add name="Telerik.Web.UI.WebResource"  path="Telerik.Web.UI.WebResource.axd" verb="*" type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Version=[ASSEMBLY_VERSION], Culture=neutral, PublicKeyToken=121fae78165ba3d4" />

    So I made this change:

    <add name="Telerik.Web.UI.WebResource" path="Telerik.Web.UI.WebResource.axd" verb="*" type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Version=2012.1.501.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4" />

    And now it works. I really think this needs to be documented more comprehensively as it has taken me weeks to figure this out when the only thing I was missing was a version number.
  9. Genady Sergeev
    Admin
    Genady Sergeev avatar
    1596 posts

    Posted 16 Oct 2013 Link to this post

    Hi Richard,

    Glad that you manage to found a resolution to the problem and thanks for tip. We will update the documentation accordingly.

    Regards,
    Genady Sergeev
    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.
  10. Alex
    Alex avatar
    1 posts
    Member since:
    Jan 2014

    Posted 13 Nov 2014 in reply to Genady Sergeev Link to this post

    Hi,

    please update that documentation accordingly!!!!!It would have saved me exactly 7 hours of digging in the shit if this would have been updated. And the last post is 1 year ago, your documantation under
    http://www.telerik.com/help/aspnet-ajax/introduction-web-resources-troubleshooting.html

    is still not updated.

    Alex
  11. Hristo Valyavicharski
    Admin
    Hristo Valyavicharski avatar
    975 posts

    Posted 18 Nov 2014 Link to this post

    Hi Alex,

    Thank you for your feedback. We will revise this article. Please share with us what is missing? What is your Sharepoint version.

    Regards,
    Hristo Valyavicharski
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017