6 Replies Latest reply on Jul 14, 2009 7:44 PM by LaLaBrucey

    Acrobat Crash - Memory could not be read

      First of all sorry if this has been covered before, I searched for a few keywords from my error but couldn't really find anything of any help. I am using Acrobat Professional 7.0 in conjunction with a VB6 program, which calls Acrobats JSO object to execute the menu item "save" to save a currently open PDF (which was also opened via the JSO). The program runs continuiously 24/7, and has no problems apart from the wee-hours of the night. At anywhere between midnight and 2am Acrobat crashes on executing the 'save' function with the following error:

      "The Instruction at "0x2d864aa2" referenced memory at "0x00000008". The memory could not be "read". Click OK to terminate the program"

      Any help much appreciated

      P4 3.2GHz
      2G Ram
      XP SP2
      VB6 SP5
        • 1. Re: Acrobat Crash - Memory could not be read
          It seems that Adobe is not very good at releasing memory and consequently it builds up to a point where it crashes. I have bypassed this problem my keeping an eye on the memory in my programme and then resetting everything when it reaches a peak. Here is an example of what I am doing:

          '---------- CHECK MEMORY (LOOP) -----------

          'Search for 'Acrobat' process

          Processes = Process.GetProcessesByName("Acrobat")

          For Each Instance In Processes

          MemUsage = Format(CLng(Instance.WorkingSet64), "#,##0") & " Bytes"

          'If Memory running at higher than 100MB then close down all acrobat applications and restart to flush memory.

          If Instance.WorkingSet64 > "100000000" Then

          JSO.Console.Clear()

          JSO.Console.Hide()

          Marshal.ReleaseComObject(JSO)

          JSO = Nothing

          Instance.Kill()

          Threading.Thread.Sleep(5000)

          SourceDocument = New AcroPDDoc

          TargetDocument = New AcroPDDoc

          SourceDocument.Open(Str1)

          End If

          Next
          • 2. Re: Acrobat Crash - Memory could not be read
            Patrick Leckey Level 3
            > It seems that Adobe is not very good at releasing memory and consequently it builds up to a point where it crashes.

            Well, not really true at all. What version are you using? 9 has some of the best memory management ever released in an Adobe product, and I have systems where 8.x was routinely open for days at a time and never had any memory problems.

            > 100MB

            Really, that's all you allow it? What if you have to insert and remove pages between two 150MB documents? Open a document with embedded video? Open a PDF Portfolio? You don't allow your users to do any of this?
            • 3. Re: Acrobat Crash - Memory could not be read
              (Aandi_Inston) Level 1
              >Really, that's all you allow it? What if you have to insert and remove pages between two 150MB documents?

              Acrobat certainly should not need to load all of a PDF into memory. I
              can't believe it is that sloppy. The code base dates back to when 16
              MB was a lot, and it could handle 2 GB files in those days.


              Aandi Inston
              • 4. Re: Acrobat Crash - Memory could not be read
                Patrick Leckey Level 3
                > Acrobat certainly should not need to load all of a PDF into memory.

                I don't believe that it does. But some operations, like inserting many pages between large documents or copying pages with a lot of rich content between documents, can certainly consume more than 100MB (depending on the size of the content). I can't believe that 100MB should be a hard limit unless you're very certain of the type of content and operations your users would be performing.
                • 5. Re: Acrobat Crash - Memory could not be read
                  (Aandi_Inston) Level 1
                  > can certainly consume more than 100MB

                  Indeed, and I have seen a pathological case where it reached 2 GB and
                  failed.

                  Aandi Inston
                  • 6. Re: Acrobat Crash - Memory could not be read
                    LaLaBrucey Level 1

                    Hi There, my goodness there is a lot about this all over the net.

                    OPTIMISING

                    I am using Acrobat Professional 7 and *none* of the solutions in the fast few days have worked for me.

                     

                    Everytime I try to optimise a pdf via the menu, the program crashes, it starts to and the I get

                    "The instruction at 0x2d864aa2 refernced memory at 0x00000008. The memory could not be read"

                    and then when I look at the error reporting - the Modname is not what everyone else is reporting - the plugin, my Modname is: acrobat.dll.

                    Optimising works via batch processing though?!

                     

                    Uh oh...

                     

                     

                    What I *eventually found* is this:

                    In the program itself, go to

                    Advanced--> PDF Optimizer. In the left pane, select 'Discard Objects' and UNTICK 'Discard all alternative images'

                     

                    Yay, up and running again

                     

                    I hope this helps someone else out there!