Error: Objet reference not set to an instance of an object

Last post 03-21-2012, 10:45 AM by Tux. 22 replies.
Page 1 of 2 (23 items)   1 2 Next >
Sort Posts: Previous Next
  •  11-27-2011, 8:53 AM 71647

    Error: Objet reference not set to an instance of an object

    Hi,
     
    this is the error that some of our customers report on their PCs (see the image below).
     
    It doens't occur on all the PCs, and it doesn't occur on our development servers, thus it's very difficult for us to understand the cause of the problem.
     
    The customer reported that, on the PCs where the error occurs, uploads of files with a size smaller than 150 KBs are always succesful, but a greater size than that generates the problem. We still have to verify this feedback, but it might be a clue.
     
    Waiting for help!
     
    Best Regards.
     
  •  11-28-2011, 4:13 AM 71674 in reply to 71647

    Re: Error: Objet reference not set to an instance of an object

    Tux:
    The customer reported that, on the PCs where the error occurs, uploads of files with a size smaller than 150 KBs are always succesful, but a greater size than that generates the problem. We still have to verify this feedback, but it might be a clue.
     
     
    It's confirmed, the file size makes the difference. In some PCs of the customer (not all of them), if they upload a file smaller than 150 KBs, the upload works fine, if the size is greater then 150 KB..... error!
     
     
  •  11-28-2011, 6:15 AM 71678 in reply to 71674

    Re: Error: Objet reference not set to an instance of an object

    Hi Tux,
     
    Can you create a page by the code below and let your client test it? Does it get the same issue?
     
    <%@ Page Language="C#" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head id="Head1" runat="server">
        <title>example</title>
    </head>
    <body>
        <form id="form1" runat="server">
            <CuteWebUI:Uploader ID="Uploader1" runat="server">
            </CuteWebUI:Uploader>
        </form>
    </body>
    </html>
     
    And let him disable the Anti-virus and firewall to test it too.
     
    Regards,
     
    Ken 
  •  11-29-2011, 7:28 AM 71703 in reply to 71678

    Re: Error: Objet reference not set to an instance of an object

    Dear Kenneth,
     
    thank you for the kind answer.
     
    I will create this page and let the customer  test it. I will ask them to disable the Anti-Virus and the Firewall.
     
    I will let you know the result ASAP.
     
    Kindest Regards,
     
    Tux.
  •  12-01-2011, 8:40 AM 71754 in reply to 71703

    Re: Error: Objet reference not set to an instance of an object

    Dear Kenneth,
     
    our customer performed the test as requested. This is the web page used for the test:
     
    <%@ Page Language="C#" %>
    <%@ Register Assembly="CuteWebUI.AjaxUploader" Namespace="CuteWebUI" TagPrefix="CuteWebUI" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head id="Head1" runat="server">
        <title>Test AjaxUploader</title>
    </head>
    <body>
        <form id="form1" runat="server">
            <CuteWebUI:Uploader ID="Uploader1" runat="server">
            </CuteWebUI:Uploader>
        </form>
    </body>
    </html>
     
    During the test, the Firewall and the Anti-Virus were disabled.
     
    The result is the same: Object reference not set to an instance of an object.
     
    Please let me know what we could do to solve this issue.
     
    Best Regards,
     
    Tux.
  •  12-01-2011, 10:33 AM 71758 in reply to 71754

    Re: Error: Objet reference not set to an instance of an object

    Hi Tux,
     
    Is your site on a load balancing environment?
     
    Does your client get the same issue on demo page http://www.ajaxuploader.com/Demo/select-multiple-files-upload.aspx?
     
    Can you send me the url of your test page abouve? So we can check it too.
     
    And please refer to http://www.ajaxuploader.com/FAQ.htm#16, "How do I handle a large file upload?" section,  ensure that the configuration is correct.
     
    Regards,
     
    Ken 
  •  12-02-2011, 4:06 AM 71762 in reply to 71758

    Re: Error: Objet reference not set to an instance of an object

    Kenneth:
    1) Is your site on a load balancing environment?
     
    2) Does your client get the same issue on demo page http://www.ajaxuploader.com/Demo/select-multiple-files-upload.aspx?
     
    3) Can you send me the url of your test page abouve? So we can check it too.
     
    4) And please refer to http://www.ajaxuploader.com/FAQ.htm#16, "How do I handle a large file upload?" section,  ensure that the configuration is correct.
    1) Yes, it is. We have two Web Servers under load balancement.
     
    2) We will ask them to test it, I'll let you know.
     
     
    4) Ok, I will read it, and eventually report back to you. But I think that our configuration is correct, since the customer is able (on the PCs where the problem doesn't occur) to upload files even larger than 10 MBs.
  •  12-02-2011, 4:31 AM 71763 in reply to 71762

    Re: Error: Objet reference not set to an instance of an object

    Tux:
    Kenneth:
    Please refer to http://www.ajaxuploader.com/FAQ.htm#16, "How do I handle a large file upload?" section,  ensure that the configuration is correct.
    Ok, I will read it, and eventually report back to you. But I think that our configuration is correct, since the customer is able (on the PCs where the problem doesn't occur) to upload files even larger than 10 MBs.
     
    Reporting back to you:
     
    - maxRequestLength: in our web.config we didn't customize this attribute, so I guess we use the default value (4 MBs). Could this be the problem, considering that the size limit of the error is just 150 KBs?
     
    - IIS7 and large files: on our Web Servers we have IIS 6.0 installed.

    Regards,
     
    Tux.
  •  12-02-2011, 6:32 AM 71767 in reply to 71763

    Re: Error: Objet reference not set to an instance of an object

    Hi Tux,
     
    On the load balancing environment, you must set a UNC path for uploader as the TempDirectory, and must use the same location.
     
    UNC path: http://www.cutesoft.net/developer+guide/scr/UNC.htm
     
    TempDirectory: http://www.ajaxuploader.com/document/scr/BeforeYouBegin.htm, the first section
     
    On both servers, the uploader must use the same Temp Directory(mean that, if uploader which on server "A" use '192.168.1.123/photos' as the TempDirectory, the uploader on server "B" must use this folder as the TempDirectory too).
     
    Regards,
     
    Ken 
  •  12-05-2011, 3:49 AM 71784 in reply to 71767

    Re: Error: Objet reference not set to an instance of an object

    Dear Kenneth,

    thanks for your answer, we will follow your instructions and I will let you know the result as soon as possible.

    The customer tried this page on one of the machines where the error normally occurs, but this time the upload was successful.
     
    Regards,
     
    Tux.
  •  02-09-2012, 11:33 AM 72970 in reply to 71784

    Re: Error: Objet reference not set to an instance of an object

    Hi again,
     
    I didn't have the time to investigate further on this problem, but now I have the time again.
    The situation didn't change, unfortunately, our customer still experiences the problem.
    It occurs only for uploads with a size superior than 150 KBs and only for two users in the customer's company.
     
    I followed your suggestions and set the UNC path on the IIS site of the two Web Server, as a virtual directory mapping a physical directory on a third server (our DataBase Server). Then I used this virtual directory inside our web.config (on both servers) to configure the TempDirectory of the AjaxUploader. I made a test, and when I uploaded a file (size: 6 MBs) on the customer's web application I saw the contents of this TempDirectory change (the AjaxUploader created a .resx temporary file). Then I guess it worked fine, but it didn't solve the problem...
     
    What else could we do? Maybe I made a mistake, and I didn't specify that our Load Balancer is not a software LB, is a hardware one, on a different server.
     
    Please let me know and best regards,
     
    Tux.
  •  02-16-2012, 7:08 AM 73047 in reply to 72970

    Re: Error: Objet reference not set to an instance of an object

    Any answer...please?
  •  02-21-2012, 3:31 AM 73097 in reply to 73047

    Re: Error: Objet reference not set to an instance of an object

    Hi,
     
    Maybe there's some http modules have conflict issue with the uploader .
     
    I suggest create a new IIS application to test it .
     
    With the default configuration of ASP.NET over IIS , No extra IIS/ASP.NET modules.
     
    Regards,
    Terry
  •  03-08-2012, 10:05 AM 73382 in reply to 73097

    Re: Error: Objet reference not set to an instance of an object

    cutechat:
    Hi,
     
    Maybe there's some http modules have conflict issue with the uploader .
     
    I suggest create a new IIS application to test it .
     
    With the default configuration of ASP.NET over IIS , No extra IIS/ASP.NET modules.
     
    Regards,
    Terry
     
    Hello,
     
    we checked the configuration of our IIS website, and it doesn't use any extra IIS/ASP.NET module, but just the default configuration of ASP.ENT over IIS.
     
    By means of another test, we understood that the problem is not related to the two specific users who experience the problem, but it's directly related with their computer, because we tested this scenario:
     
    - NT User 1 tested the upload on Machine 1 and the result was OK (no errors).
    - NT User 1 tested the upload on Machine 2 and the result was KO (the error occurred).
     
    NT User 1 was the same on both machines, and Machine 2 is the computer of one of the two users of our customer's company who are experiencing the problem since months. Then we assume that the problem is strictly related to the machines, not to specific NT users or HTTP modules.
     
    Any other suggestion?
    Please help, the problem is becoming stressfull for our customer.
     
    Tux.
  •  03-13-2012, 8:16 PM 73438 in reply to 73382

    Re: Error: Objet reference not set to an instance of an object

    Hi,
     
    I am not sure what's wrong now.
     
    because I can't reproduce it on your website.
     
    please add this into web.config and try again.
     
    <add key="CuteWebUI.AjaxUploader.UseAspNetStream" value="True" />
     
    and also , you can let the user test this page
     
     
    it will show a debug trace box , when get error , please copy the text and paste here .
     
    Regards,
    Terry
     
  •  03-14-2012, 5:34 AM 73441 in reply to 73438

    Re: Error: Objet reference not set to an instance of an object

    cutechat:
    Hi,
     
    I am not sure what's wrong now.
     
    because I can't reproduce it on your website.
     
    please add this into web.config and try again.
     
    <add key="CuteWebUI.AjaxUploader.UseAspNetStream" value="True" />
     
    and also , you can let the user test this page
     
     
    it will show a debug trace box , when get error , please copy the text and paste here .
     
    Regards,
    Terry
     
     
    Hi Terry, thanks a lot for your kind answer.
     
    We have just modified the web.config on our two WebServers, adding the UseAspNetStream key. Our user will test the upload again and we will let you know the result.
     
     If the error will still show up, the user will make another test using the debug mode on the TestUpload.aspx page, as you suggested.
     
    Best Regards,
     
    Tux.
  •  03-14-2012, 10:31 AM 73443 in reply to 73441

    Re: Error: Objet reference not set to an instance of an object

    Hi,
     
    we changed the web.confing inserting this line:
     
    <add key="CuteWebUI.AjaxUploader.UseAspNetStream" value="True" />
     
    Our user tested the upload again, on one of the machines affected by the problem. This time he managed to upload a file larger than 150 KB. Then he tried to upload another file, bigger than the previous one (24 MB) and he got a new, different, error:
     
     
     
    Does this help you understanding the cause of the issue?
    Anyway, this friday I'll pay a visit to our customer and I will perform an upload using the UploaderDebug=1 mode, and report the result back to you. Just one question: in case of error, will I have the time to copy/paste the debug trace, or will the page automatically refresh, removing the contents of the debug panel?
  •  03-14-2012, 8:14 PM 73450 in reply to 73443

    Re: Error: Objet reference not set to an instance of an object

    Hi,
     
    When use the 'UseAspNetStream' mode , the uploader will stop intercept the input stream .
     
    So ASP.NET will handle it , but will be limited by <httpRuntime maxRequestLength="4096" />
     
    please change it to a larger value .
     
     
    Regards,
    Terry
  •  03-15-2012, 4:20 AM 73459 in reply to 73450

    Re: Error: Objet reference not set to an instance of an object

    cutechat:
    Hi,
     
    When use the 'UseAspNetStream' mode , the uploader will stop intercept the input stream .
     
    So ASP.NET will handle it , but will be limited by <httpRuntime maxRequestLength="4096" />
     
    please change it to a larger value .
     
     
    Regards,
    Terry
     
    Hi Terry,
     
    unfortunately this cannot be the problem, since our web.config (on both webservers) already has a larger value for maxRequestLength. This is our current httpRuntime setting:
     

    <httpRuntime executionTimeout="7200" maxRequestLength="2097151"/>

    Is there something else that we have to change? 
  •  03-15-2012, 8:13 PM 73485 in reply to 73459

    Re: Error: Objet reference not set to an instance of an object

    Hi,
     
    Can you post your web.config ?
     
    Make sure there's no other upload components.
     
    Regards,
    Terry
     
Page 1 of 2 (23 items)   1 2 Next >
View as RSS news feed in XML