RadUploadContext.Current

4 posts, 1 answers
  1. Adrian
    Adrian avatar
    3 posts
    Member since:
    Aug 2014

    Posted 08 Aug 2014 Link to this post

    Hi! I've been trying to use RadUpload.Net2 using a simple .aspx page, but i'm getting a null reference for the next line of code

    UploadedFile file = RadUploadContext.Current.UploadedFiles[File1.UniqueID];
    whne using the following controls:
    <input id="File1" type="file" runat="server" />
    <asp:Button ID="Button1" runat="server" Text="Button" Enabled="true" OnClick="Button1_Click"/>
    <radUpload:RadProgressManager runat="server" ID="Radprogressmanager"/>
    <radUpload:RadProgressArea ID="RadProgressArea1" runat="server" />
    I'm using IIS 7.5 with the DefaultAppPool , .Net 4.0 Integrated. The WebConfig is as follows:
    <configuration>
      <appSettings>
        <add key="Telerik.WebControls.RadControlsDir" value="~/Resources/RadControls/" />
        <add key="Telerik.WebControls.RadUpload.TempFolder" value="D:\Projects\ODW\Temp\Upload" />
      </appSettings>
      <system.web>
        <compilation debug="true" targetFramework="4.0">
          <assemblies>
            <add assembly="RadUpload.Net2, Version=2.4.1.0, Culture=neutral, PublicKeyToken=B4E93C26A31A21F0" />
            <add assembly="System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" />
            <add assembly="System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089" />
          </assemblies>
        </compilation>
        <pages enableEventValidation="false" validateRequest="false" controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID" />
        <httpRuntime maxRequestLength="30240" executionTimeout="10" />
        <!--<httpModules>
          <add name="RadUploadModule" type="Telerik.WebControls.RadUploadHttpModule, RadUpload.Net2, Version=2.3.0.0, Culture=neutral, PublicKeyToken=b4e93c26a31a21f0" />
        </httpModules>
        <httpHandlers>
          <add verb="*" path="Telerik.RadUploadProgressHandler.aspx" type="Telerik.WebControls.RadUploadProgressHandler, RadUpload.Net2, Version=2.3.0.0, Culture=neutral, PublicKeyToken=b4e93c26a31a21f0" validate="false" />
        </httpHandlers>-->
        <trace enabled="false" pageOutput="false" requestLimit="40" localOnly="false" />
        <authorization>
            <allow users="*" />
        </authorization>
        <trust level="Full" />
      </system.web>
      <system.webServer>
        <modules runAllManagedModulesForAllRequests="true">
          <add name="RadUploadModule" type="Telerik.WebControls.RadUploadHttpModule, RadUpload.Net2, Version=2.4.1.0, Culture=neutral, PublicKeyToken=b4e93c26a31a21f0" preCondition="integratedMode" />
        </modules>
        <validation validateIntegratedModeConfiguration="false" />
        <handlers>
          <add name="Telerik_RadUploadProgressHandler_ashx" verb="*" path="Telerik.RadUploadProgressHandler.aspx" type="Telerik.WebControls.RadUploadProgressHandler, RadUpload.Net2, Version=2.4.1.0, Culture=neutral, PublicKeyToken=b4e93c26a31a21f0" preCondition="integratedMode" />
        </handlers>
        </system.webServer>
    </configuration>



    The handler is registered in IIS. I've tried it on classic .Net app pools an it's still not working.




  2. Answer
    Hristo Valyavicharski
    Admin
    Hristo Valyavicharski avatar
    975 posts

    Posted 12 Aug 2014 Link to this post

    Hi Adrian,

    The version you are using is very old and is no longer supported. Please upgrade to newer version. Have in mind that the RadUpload was replaced by the RadAsyncUpload.

    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.

     
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Adrian
    Adrian avatar
    3 posts
    Member since:
    Aug 2014

    Posted 12 Aug 2014 in reply to Hristo Valyavicharski Link to this post

    Hi!
    I'm well aware of the situation. The thing is I need to use RadUPload.Net2. It's already in use and it works on the webpage that is used on a server. The issue appears on when trying to debug using localhost on IIS. It only work on 1 out of 5 workstations, on localhost on IIS. I wanted to know if there are some config changes that are required and are unknown to myself.
  5. Adrian
    Adrian avatar
    3 posts
    Member since:
    Aug 2014

    Posted 13 Aug 2014 in reply to Hristo Valyavicharski Link to this post

    We've decided to update to the new library.
Back to Top