Help with time out settings - InfoPath Dev
in

InfoPath Dev

Help with time out settings

Last post 08-26-2010 11:49 AM by Altajeff. 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 08-25-2010 04:36 PM

    • Altajeff
    • Not Ranked
    • Joined on 08-25-2010
    • Sacramento, CA
    • Posts 3

    Help with time out settings

    Needing some help please with a time out error.       Erro: InfoPath cannot submit the form. An error occurred while the form was being submitted. The data operation timed out (30 sec).

    The form is a mileage\expense report. Employee submits it fine and it's e-mailed to a manager. The manager is not able to approve it due to the time out.
    It seems to be a hit and miss on when it can go through. Re-creating the report sometimes work.

    Using 
    InfoPath 2003. Once approved it's sent to a SQL server. Not using web service or SharePoint.
    The SQL server is not set to time out any queries or request. Can't change the settings within SharePoint Central Admin, since it's not being used. Tried adding a code to On Load Event, but that didn't do anything.
    Is there perhaps another setting within InfoPath that defines the time out?

    Thanks

     

  • 08-25-2010 06:23 PM In reply to

    Re: Help with time out settings

    Data connectors have a Timeout property you should be able to set. What was your code that didn't do anything?

    Hilary Stoupa

  • 08-26-2010 08:51 AM In reply to

    • Altajeff
    • Not Ranked
    • Joined on 08-25-2010
    • Sacramento, CA
    • Posts 3

    Re: Help with time out settings

    I actually follow information given by you on another post. http://www.infopathdev.com/forums/t/11369.aspx
    Also tried to simplify it by trying ....
    dAdapt.Timeout = 60
    dAdapt.Query = 60

  • 08-26-2010 09:17 AM In reply to

    Re: Help with time out settings

    So you are using:

    var dAdapt = XDocument.DataAdapters["Test1"];
    dAdapt.Timeout = 60; // Increase to 60 seconds - Default is 30
    dAdapt.Query(); // Issue the query

    Which is the code from the original post. What is the name of your data adapter? Probably not "Test1" -- did you change that to your data adapter? Are you using jscript or vbscript?

    Hilary Stoupa

  • 08-26-2010 11:49 AM In reply to

    • Altajeff
    • Not Ranked
    • Joined on 08-25-2010
    • Sacramento, CA
    • Posts 3

    Re: Help with time out settings

    We're using jscript.
    I found and added the following and it appeared to work. Tested on 2 expense reports so far and it went through fine. Will wait and see if this fixed it.

    {

     XDocument.QueryAdapter.Timeout=120;

    XDocument.Submit();

     

    XDocument.Submit.Timeout=120;

    }

    I added the third line because I was not sure if leaving the second line as is would work.

Page 1 of 1 (5 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.