More about app.openDoc

Hi,
being a bit further with my work on app.openDoc thanks to the help of this forum, I'm a bit puzzled about the following problem:
var mainDoc = app.openDoc(mainDocPath);
//var mainDoc = app.openDoc("/C/myDoc.pdf");
app.alert(mainDoc);
In this example "mainDocPath" is a valid path and the document opens. Anyway mainDoc is being evaluated as "undefined".
When I use the commented line instead, the alert displays "[Doc_Object]" as I would expect.
What is going wrong here?
Thanks for any help.

I have been breaking down complexity a bit further.
Two documents: C:\Control.pdf and C:\Main.pdf.
The control document has a document level javascript "TestCall" with content:
function TestCall() {
    mainDoc = app.openDoc("/C/Main.pdf");
    //this.closeDoc();
TestCall();
The main document has a javascript "SetDisclosed" with content:
function SetDisclosed()
    this.disclosed = true;
When I run the control javascript while the document is open, everything is fine and it opens the main document. If the javascript runs on document initialization, I get the "NotAllowedError".
If I change the line "mainDoc = app.openDoc("/C/Main.pdf");" to "mainDoc = trustedOpenDoc("/C/Main.pdf");", i.e. running the folder level script
trustedOpenDoc = app.trustedFunction(
     function(pPath) {
          app.beginPriv();
          var trustedDoc = app.openDoc({
               cPath: pPath,
               bUseConv: true
          app.endPriv();
          return(trustedDoc);
everything is still fine when run from the opened control document.
When it runs at document initialization, I get an error dialog stating that an error occurred when opening the document because of an "invalid action object" (this is in german language and I don't know the exact words that it will show in an english language version).
That can't be the intended way of functionality, can it? When reading through the forums, I get a feeling like many people do what I want to do and there is only one more little hint missing and there will be prospering landscapes for my programming efforts if this could be solved. Unfortunately I can't find the point myself and can't see sense and meaning in that ugly behaviour.
I already had the idea that the folder level scrips might not already be loaded when the trusted function is called at document initialization and tried it in a loop with a try/catch construction, but it was never working at document initialization.
Any more hints?

Similar Messages

  • Why would it state under the "more about this mac" that i already have10.8.3 and then in the app store say i need to "resume" do you know what i mean? is it possible i already did download mountain lion entirely once? I am confused and don't want it twice

    why would it state under the "more about this mac" that i already have10.8.3 and then in the app store say i need to "resume" do you know what i mean? is it possible i already did download mountain lion entirely once? I am confused and don't want it twice

    This is cause by the way the App Store checks to see if an application is installed on your system.
    Basically when an app is installed it is in the Applications folder and this is where the MAS looks for them. So it looks at your purchase history for the apps you bought and looks in the Applications folder to see if they are installed. If an app is in your purchase history but not in the Applications folder the MAS says you need to install it.
    For normal apps this works fine but the OS doesn;t install into the Applications folder. So the MAS sees you have Mountain Lion in your purchase history but it's not in the Applications folder and so it says you need to download it.
    Hopefully one of these days Apple wil fix this.
    regards

  • HT1689 I have purchased some app's like Whatsapp, Flashlight and more from App Store and after about 3 days of usage, all refuse to open up. I have received acknowledgement of payment via email. What should I do to reinstate them?

    I have purchased some app's like Whatsapp, Flashlight and more from App Store and after about 3 days of usage, all refuse to open up. I have received acknowledgement of payment via email. What should I do to reinstate them?

    BRAWO!!!! It solves the problem.
    Just hope that i would not be forced to download free Apps every thir day.
    Here by us in South Africa, downloads is costing one.
    Anyhow, thank you once more.

  • I cant login to DPS App Builder. Get this error: ERROR This account does not have permission to access App Builder. Learn more about how to resolve this problem.

    I cant login to DPS App Builder. Get this error: ERROR This account does not have permission to access App Builder. Learn more about how to resolve this problem.

    Then you either need to:
    1) Sign up for Creative Cloud so you can build a Single Edition app. Be warned though: this approach will no longer be valid as of May 1st when we retire support for Single Edition in Creative Cloud, and Single Edition apps are only on iPad devices.
    2) Sign up for a full DPS license. You can request pricing information by filling in Adobe | Request for consultation.
    Neil

  • I am new in using Mac operating system, kindly suggest ebooks , videos or audio books to me so that i can learn more about it?

    i am new in using Mac operating system, kindly suggest ebooks, videos or audio books to me so that i can learn more about it.
    any kind of help would be appriciated. i am very eager to learn.how to make ios application? and how to effectively use terminal? where does the basic programming start in Mac? what are the different tools that can help me make an Mac application and ios application.
    -Thank you
    Shailendra (India)

    Apple has got some great guides to start developing in Objective-C, used for programming OS X and iOS apps > http://developer.apple.com/library/mac/#referencelibrary/GettingStarted/RoadMapO SX/chapters/01_Introduction.html

  • More about  languages

    Hello there...
    As you all probably know it's possible to have multiple menu backgrounds, different button text, different subtitles and audio with dvd studio pro. BUT (yes.. there is one big but in all this) i have a problem when it comes to menus for diferent languagues.
    I know how to make a script to select an audio ou subtitle stream acording to user input (in a language menu).
    My question is: if dvd studio allows you to use diferent menu layouts for diferent project languages, why it doesn't lets you point a script to a specific menu language, "forcing" you to make 2 menus? I mean... the software will read the language value in the sprm, but if the dvd player language settings are different from the avaiable languages on your project? why there isn't a way to choose custum script no select the language instead of forcing it to only realy the sprm value?
    Or there's one, and it's me that need to learn a little more about dvdsp ?
    Can someone please help me with this?
    Thanks!

    The KOffice apps have quite some options for saving files. KWord can do it in MS Word, MS Write and RTF amongst others. The import filters may not be working all too well, have a look at the Supported File Formats. I can't really tell about the quality of those filter, because I for myself have to handle just PDF-files most of the time, and my former MS Word & MS Excel files are not that important (means I don't really care, if I have to make a fresh start with my docs when going with KOffice).

  • Wanting to know more about using my iphone to skype

    Hi, everyone.. i did a quick serach about skype on the forum but there is not much information about it. So i'm going to ask you guys a bit more using the iphone to skype. Me and my husband both of us got iphone4 and many of our friends as well. So can you please let us know more about this skype technology.. i don't really know much about it at all...thanks i am feel a bit stupid asking this but i'm sure someone out there will be happy to help.. thanks in advance

    but if you all have iphone 4's you should use facetime. it is basically apple's version of skype. Turn it on in the settings app then under phone then facetime someone in the contacts app

  • I have an icloud e-mail....I would like to use it more, where can I learn more about their services

    I have an icloud account, I would like to know more about their services, where can I
    get more info....thanks

    In addition to the iCloud FAQ, http://support.apple.com/kb/HT4436 you can go o the App Store and ind several sources like the Guide to iCloud that can be downloaded.

  • I would like to learn more about using the Adobe Digital Publishing Suite.

    I would like to learn more about using the Adobe Digital Publishing Suite. I really don't know much about it nor do I know anyone who uses it yet. Is it specifically for creating apps for tablets? What about smart phones? We sometimes produce PDF publications that are posted to our website. Can DPS be used to produce more interactive online publications? What is a .folio application? What platforms are .folio apps used on?

    DPS currently supports iPads, iPhones, and Large and XLarge Android devices. You can start here to get basic information and watch a few videos:
    http://help.adobe.com/en_US/digitalpubsuite/using/WS67cb9e293e2f1f60174dc2eb12f2ca67c28-80 00.html
    If you have an iPad or other mobile device, you can download and play with any of these apps created with DPS tools:
    http://blogs.adobe.com/digitalpublishinggallery

  • Where can I learn more about Siri?

    Siri works pretty well for me (for a Beta component) since I do not have a strong regional accent,  but I want to learn more about what it can do, how best to pose questions for successful interactions and follow its progress as it is updated by Apple. Any suggestions for good resources?

    Here's a place to start: Learn more about Siri

  • Where can I learn more about the Logic Environment?

    I've been using LogicPro for a while now - since version 7 came out - and I'm ready to learn more about the mysterious Logic Environment. Anyone know of a good tutorial or website on this topic? I don't have a specific question - what I need is a general overview.
    My sessions are primarily audio recording and mixing with a virtual instrument from time to time. I rarely use MIDI except to play the synths and instruments.
    My environmental experience so far has been limited to creating and naming audio objects, accessing "hidden" faders and as an alternate to the mix views provided in the global and track mixers.
    I'd prefer free advice but I'm not against paying if it's worth it. I have read the manual but I have a feeling that it will be more helpful once I have a better grasp on the big picture. It's a reference manual more than a how-to.
    My MIDI devices are an Axiom-61 and PreSonus FaderPort.
    Thanks,
    John
    Message was edited by: John Curley

    Apple has what they call "online seminars" available on the main Logic page
    http://www.apple.com/logicpro/
    If you look on the bottom right hand side of the page, you see a link for online seminars. You'll have to go through a regstration process, then you can watch 3 or 4 streaming Quicktime videos of people using different functions in Logic. There's nothing really in depth there, but it does show you a few useful shortcuts and methods.

  • My Macbook Pro was stolen, and I have replaced it with a Macbook Air. New hard drive is too small for a Time Machine restore. How do I restore my more-expensive apps (ie iWorks) on my new Macbook without repurchasing them?

    My Macbook Pro was recently stolen, and I have replaced it with a Macbook Air. I attempted to simply do a restore from the Macbook Pro's Time Machine backup, but since the new Macbook Air's hard drive is significantly smaller, a Time Machine restore was not possible. I even tried to choose only settings or only my User Profile (option) when restoring, but the backup was still too large to do a restore onto the new machine. How do I restore my more-expensive apps (ie iWorks) onto my new Macbook without repurchasing them? Also, I reaad somewhere that if you went to the Mac App Store and attempted to repurchase the app and clicked BUY, it would simply alert you that you have already purchased the app (and trigger a re-download)... NOT THE CASE... So I just dropped another $19.99 for a second copy of Pages... Not my intention....
    Any help would be greatly appreciated.
    LM

    you should get a usb backup drive as well.  time machine has limited use in my eyes. it saves things. but older things can be errased ad space drops without telling you
    nothing beats data redundancy.  2 saves is. 1.    and 1 is none
    im personally not fond of time machne though i use it only for a recovery parameter for a mac
    id never ever myself consider time machine a genuine data backup tool.  though most do consider it as such
    drive clones such as superduper and carbon copy cloner can clone your entire drive for emergency recovery.  and you can boot from them as well o. another mac

  • Question about app itune, it automatically charge money from my card on Apr/24th, but i have not buy any music or any apps on that day!! what's wrong

    question about app itune, it automatically charge money from my card on Apr/24th, but i have not buy any music or any apps on that day!! what's wrong ??

    Please look at your E-Bill and click report a problem.

  • Want to know more about Business Analytics in SAP and its scope

    Hi all,
    I would like to know more about Business Analytics in SAP and its scope. My wife has finished her MBA (HR) and currently working as HR. She is more interested Business analytics, so please guide her how to startup her career in this field in the entry level, what prerequisites should be met and how the job market will be.
    Thanks a lot in advance.
    Srini

    Dear,
    Its good decision to go with Business Analytics in SAP ERP.
    Both businesses and SAP AG no more requires consultants, requires efficient dynamic skilled business analytics professionals to advance in current international market. Business Strategic planning plays a major role in Business Analytics.
    If you search google with "Business analytics" you will find hundreds of results which everyone of us has to read and learn what really stands for Strategy and Planning.
    http://www.sap.com/corporate-en/press.epx?pressid=14491
    http://marksmith.ventanaresearch.com/2011/02/25/sap-retrofits-business-intelligence-and-information-management-to-meet-it-and-business-needs/
    http://www.sap.com/solutions/sapbusinessobjects/index.epx
    As you mentioned, its not a difficult task for an MBA(HR) person to read and understand the subject available.
    Please check and Best of luck.
    Regards,
    Syed Hussain.
    P.S: "no more requires consultants" my intention is already plenty of consultants in market today. When competition is tough and plenty - invent new technologies and upgrade.
    Edited by: Syed Hussain on Jun 22, 2011 9:21 AM

  • App.opendoc does not display security warning window like e.g. "open a file" function?

    When I link from one PDF to the other via "open a file" function (both PDFs are located in %userprofile%/mydocuments directory), Reader X and XI open a security warning box. If I agree to open the target file, this specific file always opens without displaying the warning again.
    When I link to the same file via app.opendoc, the security warning box does not open. So I do not get a chance to add the target file to the list of trusted files.
    Is there any way to motivate app.opendoc to display security warning boxes due to the new sandboxing technology in Reader >= X? So that I get a chance to add the target PDF to the trusted PDFs?

    Is there any chance that the application is being run from Developer Suite? In other words, is Developer Suite installed on the client machine and hosting the app?
    Regardless, although anything is possible, I have never heard of what you are describing. In all cases, the dialog box should be the java dialog which is a grayish/purple color. The exact color will vary depending on the JRE version you are using.
    If my first point is not the case, I would recommend that you consider using WebUtil 10.1.2.2 and also patch the AS environment to the same version. To get WebUtil to 10.1.2.2, you will need to patch a Developer Suite home and copy frmwebutil.jar to the AS home. After patching, I believe you will also find an updated webutil.pll in the DevSuite \forms directory which will also need to be copied then compiled on the deployment server.
    Also, ensure that you are using Jinitiator 1.3.1.26 or newer. If you are using the Sun JRE, be sure you are using a certified/supported version. For example, you can use the latest 1.5.x Sun JRE with Forms 10.1.2.2, which is 1.5.0_15

Maybe you are looking for