Why is Doc.closeDoc causing memory reference error?

My script worked fine when I tested it with Adobe Pro.  It is only in Adobe Reader X that it crashes and closes the app.
In LiveCycle ES version 8.2, I added JavaScript to do the following in the preSubmit event of a hidden Submit button:
var currentDoc = event.target;
var path = currentDoc.path;
execMenuItem("SaveAs",currentDoc);
var newPath = currentDoc.path;
if (path != newPath){
     //re-open the original document (blank form)
     app.openDoc({cPath:path});
//stop the submit event
xfa.event.cancelAction = true;
//close the current document (completed form)
if (currentDoc.disclosed = true){
   currentDoc.closeDoc();
From the JavaScript API documentation, I learned that the document has to have the disclosed property set to true to be available to other open documents.  I am doing this by calling a document-level function in the form1.docReady event, which I have verified is running when the document opens.  The original document is being opened, the saved document is being closed, but when the "Submit Cancelled" dialog box appears and I click "OK", I get this error:
The instruction at "0xsomething" references memory at "0x00000010".  The instruction could not be "read".
And whether I hit "Cancel" or "OK", the reader closes.  If I comment out the cancelAction, the same thing happens, only without the Submit Cancelled dialog.  So it must be the Doc.closeDoc that is doing it.  I have also tried putting the code in the postSubmit and setting a timeout, but in those cases the close never happened at all. 

Yes, I have read the JavaScript API.  That is how I found out about the "disclosed" property.  If it were a security or permissions issue, I normally find those while debugging in Acrobat Pro, in the JavaScript console.
I know there are some things you can't do in Reader that you can do in Pro, but it doesn't make sense to me that closing a document should be one of them.   If so, why even have the closeDoc method?
It seems like the document is closing before some other task can finish.  I also tried setting a timeout on it, but then it doesn't close at all. 
app.setTimeOut(currentDoc.closeDoc(),5000);
One reason we have to close these documents is that after calling xfa.event.cancelAction = true, none of the select boxes or buttons work anymore.  It is unclear where to set this back to "false".  I tried setting it in the preOpen events of the select lists, but it had no effect.  It can only be called in preSubmit, preOpen, preSign, preSave.  So, I decided it would be better just to close the document.  When they reopen it, everything works again.

Similar Messages

  • Backup causing Memory Critical error

    I have noticed that my Phone has been rebooting on me every night for the past week or so. I have no idea what is causing it, but I tried to put it into Airplane mode for the last few nights to see if that would fix the problem. Well, it didn't reboot on me, but once I turn off airplane mode, the phone would freeze on me and i would have to perform a hard reboot.  I am not sure exactly what is happening, but I then loaded up the Backup app and found another issue...
    It seems like my Palm Profile backup app is causing some major memory errors. Every time I try to run backup, I get "memory critical" errors that freezes my device and I have to do a forced reboot. I have even tried to doctor my phone and it doesn't seem to help.
    I can try to send along any log files as needed, but any idea why the backup app would be causing these errors?
    Adam
    Post relates to: Pre p100eww (Sprint)

    Hello,
    It appears I've been experiencing the same issue.  I noticed I was randomly getting critical memory issues with no apps open.  I couldn't figure out what was causing it.  Through this, the phone gets quite hot and then just freezes on whatever screen it is on.
    Is this due to the recent server authentication changes that HP announced regarding webOS devices?  It's causing my phone to crash pretty regularly in the morning and it's very inconvenient.
    Thanks!
    Chris
    EDIT: Just saw my automatically-assigned avatar.  Apparently I'm a kitten head...  LOL

  • Targetdataline.stop() causes memory alloc error

    Hi,
    Im trying to run a Thread that records Audio when I press a button. I have no problem starting the thread, but I cannot seem to stop it without receiving memory alloc errors. Im try to stop is using targetdataline.stop followed by targetdataline.close .
    I am running Java SE 6 version 1.6.0_29-b11-402, on Mac OS X (I am also using Netbeans IDE 7.1)
    java(20704,0x1100ec000) malloc: *** error for object 0x2f6a6f72706c2e68: pointer being freed was not allocated
    *** set a breakpoint in malloc_error_break to debug
    Java Result: 134
    public AudioThread(String fileName) throws LineUnavailableException {
    soundFile = new File(fileName+ ".wav");
    audioFormat = new AudioFormat(8000.0F, 16, 1, true, false);
    dataLineInfo = new DataLine.Info(TargetDataLine.class,audioFormat);
    targetDataLine = (TargetDataLine) AudioSystem.getLine(dataLineInfo);
    audioInputStream = new AudioInputStream(targetDataLine);
    targetDataLine.open(audioFormat);
    @Override
    public void run(){
    try {
    AudioSystem.write(audioInputStream, Type.WAVE, soundFile);
    catch (IOException ex) {
    Logger.getLogger(AudioThread.class.getName()).log(Level.SEVERE, null, ex);
    public void startThread() throws LineUnavailableException {
    targetDataLine.start();
    super.start();
    public void stopThread() throws IOException{
    targetDataLine.stop();
    targetDataLine.close();
    Thanks,
    Lucas

    It seems to happen after the close() .
    I tried moving the targetdataline.close() at the end of run() function (after the AudioSystem.write() ), but no such luck.
    public void run(){
    try {
    AudioSystem.write(audioInputStream, Type.WAVE, soundFile);
    catch (IOException ex) {
    Logger.getLogger(AudioThread.class.getName()).log(Level.SEVERE, null, ex);
    targetDataLine.close();
    public void stopThread() throws IOException{
    targetDataLine.stop();
    ...

  • UCS Manager Update from 2.1(1a) / 2.1(1b) to full 2.1(3b) cause Policy Reference Error on iSCSI

    Hello,
    I actualy did a UCS firmware upgrade from a mixed 2.1(1a) and 2.1(1b) to a full 2.1(3a) version.
    Chassis are 2208XP, Fabrics are 6248UP and blades are all B200-M3.
    I use firmware policy to update the firmware on the blades.
    Here are the current version of the different componments:
    - CIMC, Adapterers and BIOS Server: 2.1(3b)
    - UCS Software: 2.1(3b)
    - IO Modules:  2.1(1b)
    - Fabric Kernel / System : 2.1(1b)
    After UCS Software update when I connect on UCS Manager I got several warning referencing the error "Policy reference autProfileName does not resolve to named policy" on different parts.
    I have follow some post to resolve some of them:
    - iSCSI nic is created without Authentication profile issues:
    https://tools.cisco.com/bugsearch/bug/CSCui43905
    - Default SOL policy issue:
    https://tools.cisco.com/bugsearch/bug/CSCtl88314
    This resolve a lot of error but I'm still having errors like this on all my iscsi NIC:
    Causing this:
    Right now the update of the IOMs and FIs are on standby until I resolve this.
    Can I have some help please.

    It looks like you are hitting:
    https://tools.cisco.com/bugsearch/bug/CSCui43905
    Symptom:
    Warning with the text "Policy reference  authProfileName  does not resolve to named policy" is seen when creating  an iSCSI nic on a service profile.
    Conditions:
    Issue happens only when iSCSI nic is created without an Authentication profile
    Workaround:
    Use Authentication profile
    Create a Default Authentication Profile
    Existing  warnings from the previous version would still exist even after the  upgrade and that can be isolated only using the above work around. If  new service profiles are created on the 2.2.1b version will not  experience this issue.
    Here is how to create an authentication profile:
    http://www.cisco.com/en/US/docs/unified_computing/ucs/sw/gui/config/guide/2.1/b_UCSM_GUI_Configuration_Guide_2_1_chapter_011111.html#task_5DBBCD17FFA046A395B4493104838B1F

  • How do you identify which script is causing a reference error

    I have recently deleted some fields in a PDF document which I thought were no longer in use.
    I am now getting errors reported in the Javascript Debugger because there is a Calculate script that is trying to reference one of the deleted fields. I cannot work out from the Debugger user guide or the message on the debugger consule, which is the script in question. There are over 30 Calulate scripts in the document.
    Anyone able to offer me advice on how to track down the offending script?
    Thanks

    What's the full error message you're getting? When you use one of the
    built-in calculation options (ie not the custom calculation script), it
    sometimes doesn't print out the name of the field that triggered the
    calculation, or even the name of the field that couldn't be find, and then
    it's a real pain in the neck finding out which one is causing the
    problem... In that case the best option is to think which fields were using
    the field you deleted/renamed, and then try to fix them and see if the
    error goes away.

  • Acrobat Pro X - memory reference error

    I am running XP Pro x86.
    I have Adobe Acrobat Pro X installed w/the lastest patches.
    Every time I open a document for review, I click on the comments button and get the following error:
    "Acrobat.exe -Application Error"
    The instruction at "0x00000000" referenced memeory at "0x00000000". The memory could not be written.
    Click on OK to terminate the program
    Click on CANCEL to debug the program
    If you click on OK or CANCEL the program ends.
    I can use Adobe Acrobat Reader with no issues.
    I have tried uninstalling all adobe products and reinstalling only pro x.
    Same issue.
    I have even replace the ram memory - just in case.
    Same issue.

    Adobe WTF???!!! I have wasted a whole day on this problem and it's pissing me off. I'm trying to do something very simple.
    I have Acrobat Standard X. I installed the software on local administrator User A and it works
    I login as local administrator User B and it doesn't work, says "Cannot use this product under a guest account". Fine.
    I uninstalld software as User A and reboot
    I login as User B and installd the software. Software doesn't run, still says "Cannont use this product under a guest account". Why???!!! This is ridiculous. User B, is a local admin acount, it is not a "guest account". I understand that with this license I can only run the software with one account. I want to run the software with User B, why are you forcing me to run it with User A???!!!
    Can someone from Adobe please give a solution to this ridiculous problem? I'm losing my patience with your products and I am considering going another route...

  • Memory reference error with Net8 easy config

    I've installed the Oracle 9iDS in the Windos 2000 professional. This i have installed in ORAIDS sepate directory with oracle home as ORAIDS. Using Net8 easy config i can establish the connection with oracle server. Then after, I've also installed the Developer with Forms 6I in the same computer in different directory ORAD2k with sepate home ORAD2K. for this I tried to establish a connection through "Oracle Net8 Easy Config". While i select the menu item "Oracle Net8 Easy Config", it gives me an error :
    The instruction at "0x00010111" referenced memory at "0x016286e0". The memory could not be "written".
    Click on OK to terminate the program
    Click on CANCEL to debug the program.
    Can somebody tell me how to make a connection from Developer (Forms6I and Reports 6I)
    Thank you.

    Hi,
    Copy tnsnames.ora file from ORAIDS/network/admin this path to ORAD2K/network/admin path.
    I hope it will work fine.
    -Neeraj

  • [b]httpd.exe causing reference error[/b]

    Hello Everybody,
    We are having problems with iPlanet Web Server version 4.1. We have installed this on Windows 2000.
    We are getting "httpd.exe causing reference error" at the time of booting of the machine as well as at the time of starting the web server.
    We tried numerous times uninstalling and re-installing iPlanet 4.1 after clearing the registry. We even tried formatting the hard drive, set up Windows 2000 and installed iPlanet 4.1.
    But, nothing works and keep on getting the same error...
    KIndly someone get me the solution ASAP as we are working on time bound application.
    Sincerely appreciate your time and efforts in advande ...

    You may be running into this if you are using Pentium 4 machine:
    http://sunsolve.sun.com/pub-cgi/retrieve.pl?doc=fsunone%2F7724&zone_32=pentium%204&wholewords=on
    Try disabling the JIT first as suggested in this article and see if it helps. To disable JIT, add the following to jvm12.conf files of the instances:
    java.compiler=NONE
    Hope it helps.
    Thanks,
    Manish

  • Adding itemCreationPolicy="immediate" on mx:Panel causes null object reference error in Flex 4.x

    The itemCreationPolicy works fine with spark components and other mx component until we hit by mx panel.
    Looks like an error is thrown from StyleProtoChain.
    The interesting thing is the null object reference error both occurs in Flex 4.0 and Flex 4.1, but caused by different objects.
    Is there a workaround to use itemCreationPolicy on mx panel?
    Thank you.

    Yes, there are all kinds of problems when you remove something from the screen that had focus (for instance, at that point you can't capture keyboard events either).
    My code is sprinkled with so many things to make sure something is in focus, I tend to forget that I've done it.
    In your code that changes the currentState, add
    this.setFocus()
    HTH;
    Amy

  • Why does system exec cause a memory leak to occur?

    Sorry if this has been posted before, but I can't quite figure out why this VI is causing a gigantic memory leak (losing nearly 500K of memory a second). It's a simple system exec call, and I even trivialized everything in order to try and discover the problem.
    Does anyone see a huge problem here? I've tried calling up taskkill afterward as well, though that seemed to make little difference.
    If you don't trust my trivial program (and you probably shouldn't), I've also included the source files for the program - it's a one-line C++ program that returns immediately.
    Any insight is greatly appreciated.
    Thanks!
    Attachments:
    Dilution.vi.zip ‏11 KB

    Try putting a wait - even a 0 second wait - in your loop and see if it makes a difference.  Without a wait, LabVIEW will try to run that loop as fast as possible, possibly so fast that it never yields time to free resources.

  • What are the possible causes of following errors in MAX? Are there any references on how to use MAX?

    Hi, it's me again.
    I've checked the encoder response in MAX (-ve ccw, +ve cw) and it seems fine. But when the motor moves MAX will generate a following error message. Is my encoder causing the problem or have I made a mistake in the settings? I've checked the connections to the encoder and they are all correctly wired.Could there be other causes of following errors?
    The motor does stop earlier when I reduced the following error value, so I'm assuming that the motor stops only when it has reached the set number of following errors and NOT because the motor has reached the target position. Any help is greatly appreciated.
    Thank you.

    It may be that the 7344 is missing encoder values, or that the motor isn't tuned correctly. The first thing I'd like for you to check is that the Encoder Counts per Revolution input to the Axis Settings menu in MAX is set correctly (I believe it defaults to 2000 counts). To check this, you can rotate the motor by hand one revolution to see how many counts have accumulated. Most encoders are either 2000 counts per rev or 4000 counts per rev.
    Once you have that confirmed, autotune the motors and make sure the values for Kp, Kd, and Ki are resonable. (Kd is often around 10x Kp) Once these are set, start your motors moving slowly and observe the following error. This can be seen under the Advanced tab of the 1D Interactive menu. If it is slowly incrementing, t
    hen your're missing counts. If it is negative, then the encoder phases may be backward. If there is no following error, or the count stays constant, then try increasing the speed. It could just be that your encoder sends pulses too fast for the 7344 to read.
    Let me know how it goes.
    Kyle V

  • Linked Server Causing Reference Error in Database Project

    Good Morning
    I have a database project that will not deploy to my local because of a reference error to a linked server within the code.  I have searched high and low about how to get a linked server recognized within a TFS Database Project to no avail.  I'm
    probably missing something simple, but any help will be greatly appreciated.
    Regards
    Mark

    Hi Mark,
    I'd like to know how do you deploy your database project, and you use TFS build or something related. If you use TFS build to do continuous deployment, you need to make sure you can build and deploy in local before TFS build.
    Based on your description, you might need to open a new thread in
    SQL Server Data Tools forum for a better response. And update the thread by posting the new thread link here.
    Best regards,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • X6 mass memory full error

    I want to copy some MP3 files to the X6 phone mass memory through windows explorer but it give me a memory full error message.
    Before I start to copy, it indicated 8.40G free out of 15.0G (not sure why it is 15G), but once I start to copy, it pops up the error message. I disconnect the phone and use the phone file manager to check and it has about 8.4G free. Try it again, the same happened.
    While in windows explorer it indicated it is full full, under the ovi suite->view->device information, it has 8,4G free! I know I have the space because I deleted a lot of files recently.
    Firmware: V21.0.004. OS: Windows 7

    I received an email from Nokia support about the issue however unfortunately their advice was useless...
    I will copy/paste it here in-case it might be useful to anyone else.
    Thank you for contacting Nokia Care. 
    We sincerely apologise for any inconvenience this issue may have caused you. In response to your concern with your device, the phone notifies you if the phone memory is getting low. 
    To free phone memory, transfer data to a mass memory in the File mgr application. Mark files to be moved, select Move to folder (or Organise > Move to folder) and then the destination folder.
    In order to free memory, you could also remove or move the following:
    a. Messages from Inbox, Drafts and Sent folders in Messaging 
    b. Retrieved e-mail messages from the phone memory Saved Web pages. Clear the web browser cache to free some memory. 
    c. Saved images, videos, or sound files 
    d.Contact information 
    e.Calendar notes 
    f.Downloaded application packages 
    g.If there are applications which are not needed any more, uninstall them 
    h.Any other data that you no longer need 
    If possible, use the mass memory instead of phone memory in the Camera application. You can also use Image Store available in the Nokia PC Suite or Ovi Suite to transfer images and video clips for example to a compatible PC. 
    If you are deleting multiple items and any of the following notes are shown: Not enough memory to perform operation. Delete some data first or Memory low. Delete some data, try deleting items one by one (starting from the smallest item).
    For future reference, please feel free to check our website. Kindly refer to the link below:
    http://www.nokia.co.uk/home
    You may also call our Customer Care Hotline at 0845 -045-5555, 
    Mon-Fri 9am - 7pm (except bank and public holidays)
    Please do not hesitate to contact us again if you have any questions.
    Yours sincerely, 
    Jacklyn B. 
    Nokia Service Professional 
    UK & Ireland Team
    Nokia Care

  • Open vi reference error

    Hi all,
    I am using LabVIEW 2011 SP1. I am running such a vi which is calling another vi by selecting a boolean button. After opening the new vi, the previous vi will stay opened but being minimized and the new vi will stay maximized untill user forces to close the new vi. All the operations are going successful at the start. But if we keep running it for 12-13hrs, then an error is coming in open vi reference of the previous vi and the previous vi becomes maximized and above the new vi. I have attached the error message herewith. Please give me a solution.
    Attachments:
    error.txt ‏1 KB

    Error 2 is a memory full error. If you right-click on the error cluster you can select "Explain Error". The most likely reason is that you are not closing your references properly, or you are not closing them at all. It could also be something else, such as continously building an array until you run out of memory. Without seeing some code it's impossible to say what the real cause is. If you cannot post your code then you will need to look at your code to see whether you are auto-disposing the VI references. If you are not, then you are responsible for closing them. If it's not a reference issue, then you should use the performance tools to monitor the memory usage of your VIs to see which one is causing unbounded increased memory usage.

  • Unexplainable MEMORY FULL error in 8.2

    Alright, I finally got my client to take a look at LV 8.2 (we've been on LV 7.0 for 3 years).
    So I have it running in Evaluation mode (we haven't purchased it yet).
    I'm running in WinXP Pro/SP2 under Virtual PC 7.0 on a 2x2GHz G5 Power Mac.
    The program works perfectly on LV 7, on a real Win2000 box, and on this Virtual PC setup.
    The first time I try to run one of my programs in LV 8.2, I get this MEMORY FULL error.
    It complains about the INITIALIZE ARRAY function. Notice that it's wired to the #SAMPLES control which is set to the highest I32 value possible (as a default condition). You might think that that's it - I'm trying to allocate 2+ gig of samples, and it just can't do it.
    Here's the kicker:
    The break point at INITIALIZE ARRAY did NOT get hit.
    The break point at the CASE ouside of that did NOT get hit.
    A break point at the CASE outside of that (not shown in this pic) did NOT get hit.
    The FUNCTION control on the front panel is NOT set to INIT, but to "ShutDown", which SHOULD cause a different case to be executed.
    A breakpoint at the parent's call to this VI DID get hit. But if I step IN from there, the first step stops at the WHILE loop, the next step hits the error.
    This VI is not re-entrant, or any other weird setting.
    In other words, it appears to be executing the wrong case.
    This is my first try on LV 8.x, so maybe I'm missing something. Is it trying to be "helpful" and warn me about what it thinks are future problems?
    Why is it executing the wrong case?
    Message Edited by CoastalMaineBird on 11-16-2006 07:16 PM
    Steve Bird
    Culverson Software - Elegant software that is a pleasure to use.
    Culverson.com
    Blog for (mostly LabVIEW) programmers: Tips And Tricks
    Attachments:
    Picture 2.png ‏101 KB

    Alright - here's the bug - the stupidest thing I've ever seen from LabVIEW.
    This library is in LV 7.0 - it works perfectly in LabVIEW 7.
    But in LabVIEw 8.2, in SPITE of the fact that I call it with a function of SHUTDOWN, it insists on complaining about the code that I DON'T EXECUTE.
    Run the BUG CALLER and see for yourself.
    Steve Bird
    Culverson Software - Elegant software that is a pleasure to use.
    Culverson.com
    Blog for (mostly LabVIEW) programmers: Tips And Tricks
    Attachments:
    LV82Bug.llb ‏22 KB

Maybe you are looking for

  • How to open a page from a Form and pass parameters to the form on that page

    I found a similar example on this forum, but it did not work for me: declare l_names owa.vc_arr; l_values owa.vc_arr; i number; begin PORTAL.wwpro_api_parameters.retrieve(l_names, l_values); FOR i in 1..l_names.count LOOP htp.p(l_names(i) || ' ' || l

  • ITunes can't connect to Apple TV sometimes after sleep and wake up

    Hi! There are any issues to find in the discussions depending on problems between the ATV and iTunes but no solution helps me to solve the following problem till now. I am using a Mac mini (middle 2011) as a central storage for multimedia data. The e

  • LaserJet 1320tn Pausing When Trying To Print - Won't Print When Resumed

    Hello Everyone, Until about a week ago users in my office who print to a networked LaserJet 1320tn were able to print to it. Now, when trying to print a document, the printer pauses itself, and continues to pause itself when I try to resume printing.

  • Basic Layer Question ( I should already know).

    Scenario: I open an image/ Background layer. I duplicate that layer, and apply a Levels adjustment that I'm happy with. Next, I decide to do an "effect" layer such as sharpening, etc., but I want to be able to control the effect of the "Sharpening" L

  • My phone has sooooooo many problems

    Hi all, i am having lots of issues since the 2.0 upgrade. First, yesterday i turned on my iphone and it said "connect to itunes". So i powered it off and back on. Problem fixed. But, every single one of my 20 apps open then crash. Second, when using