Insufficient memory to execute this function

hewajithhewajith Member Posts: 96
Hi Enyone,

I got following error message when creation purchase invoices in NAV2009SP1

'There is insufficient memory to execute this function this can be caused by recursive function call'

Have anyone faced same sort of situation?


Hewajith

Comments

  • philippegirodphilippegirod Member Posts: 191
    edited 2010-01-04
    This can be due to a modification, maybe in OnInsert in Purchase Header or in one of the Form triggers.
    This kind of problem can occure when a loop never ends, for instance when you have that kind of code
    IF (condition) THEN REPEAT
      (instructions)
    UNTIL (new condition)
    
    Be very carefull to your UNTIL "new condition" sometimes it's something which never happens.

    To discover where is the problem, you could maybe use the Client Monitor.
    My candle burns by both ends, it will not last the night,
    But oh my foes and oh my friends, it gives a lovely light
  • superjetsuperjet Member Posts: 40
    check out your code and find a loop what never ends, as said above,
    maybe you VALIDATE the same field on it's own OnValidate() trigger - it's wrong.
  • ta5ta5 Member Posts: 1,164
    Start the debugger with "breakpoint on triggers = no"
    When the error occurs, you will see the recursive function in the call stack window.
    Hope this helps
    Thomas
  • matttraxmatttrax Member Posts: 2,309
    ta5 wrote:
    When the error occurs, you will see the recursive function in the call stack window.

    Just a note, sometimes it can be hard to see. You may have a recursive call that has 20 functions in it. i.e. A validates B validates C validates D validates E validates F validates A. I know that's not 20, but you get the idea :D
  • hewajithhewajith Member Posts: 96
    Thank you all for your valuable ideas

    In my case users are getting this error randomly. If they click on Ok button on the message they can continue without any issue


    hewajith
Sign In or Register to comment.