Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
240
I am trying to get the WebUpload control to work but it simply does not upload the file.
posted

I am using VS 2008 with .NET 3.5 and after I put the control on the page and let it import it's ig_ui folder I added the following headers.

 

    <link type="text/css" href="ig_ui/themes/ig/jquery.ui.custom.min.css" rel="stylesheet" />
    <link type="text/css" href="ig_ui/themes/base/ig.ui.min.css" rel="stylesheet" />

    <script type="text/javascript" src="js/jquery-1.6.1.min.js"></script>
    <script type="text/javascript" src="js/jquery-ui-1.8.13/jquery-ui.min.js"></script>
    <script type="text/javascript" src="ig_ui/js/min/ig.ui.min.js"></script>

 

I also tried using the Microsoft CDN for jQuery and jQueryUI.  Then end result is that the page opens up and control looks good and brings up the find file dialog as expected but it never actually uploads the file.  The progress bar opens, blinks a bit and then goes away.  No file is to be found in the destination folder.  The Uploaded events don't fire client or server side.

 

I added the modules and handlers shown in the help site and documentation but the behavior was exactly the same.  It doesn't throw any exceptions so I can't even figure out where to start looking.

        <modules>
            <remove name="ScriptModule"/>
            <add name="ScriptModule" preCondition="managedHandler" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
      <add name="IGUploadModule" type="Infragistics.Web.UI.EditorControls.UploadModule" preCondition="managedHandler" />
    </modules>
        <handlers>
            <remove name="WebServiceHandlerFactory-Integrated"/>
            <remove name="ScriptHandlerFactory"/>
            <remove name="ScriptHandlerFactoryAppServices"/>
            <remove name="ScriptResource"/>
            <add name="ScriptHandlerFactory" verb="*" path="*.asmx" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add name="ScriptHandlerFactoryAppServices" verb="*" path="*_AppService.axd" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add name="ScriptResource" preCondition="integratedMode" verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
      <add name="IGUploadStatusHandler" path="IGUploadStatusHandler.ashx" verb="*" type="Infragistics.Web.UI.EditorControls.UploadStatusHandler" preCondition="integratedMode" />
    </handlers>
    </system.webServer>

Any help at all would be greatly appreciated.

 

Parents
  • 1800
    posted

    Hi legionxiii,

    My advice is to check for javascript errors. Also please attach from client side to the javascript event onError. Event handler could look something like this:

    function onError (event, args) {
    alert('errorCode: ' + args.errorCode + ', errorMessage: ' + args.errorMessage + ', errorType: ' + args.errorType);
    }

    It will alert error code and error message(which I hope it will help you debugging).

    Most common errors for your case are:

    1. Not properly set path of httphandler <add name="IGUploadStatusHandler" path="IGUploadStatusHandler.ashx" verb="*" type="Infragistics.Web.UI.EditorControls.UploadStatusHandler" preCondition="integratedMode" />
    2. Not properly set upload folder

    3. Not set write permissions for upload folder

    If you have not set upload folder then default upload folder should be with name "Uploads" in the root folder

    As I see you have configured system.webServer - are you sure you test your site through IIS7. For instance if you are using development server or IIS6 you should configure httphandler/httpmodule in <system.web> section.

    Thanks,
    Miro Hristov

Reply Children