With the help of VBA - check to see if Acrobat Pro is open on the computer of the users

Hi all. I have an access request that generates a lot of single page PDF reports in a folder on the user's computer, then when it's over, it combines all files in a single pdf file on the desktop of users. If the user has left open Acrobat Pro before it begins to run reports, when it starts to try to combine the files, he will receive an error message.

I would check if Adobe Acrobat Pro is open from the beginning of the routine, so that the user doesn't have to spend as much time regenerating reports yet. I was not able to find the VBA code that will do this. Can anyone help?

Thank you

David

Hello test screen name. I do catch the error and generate a friendly error message to ask the user to close Adobe Acrobat. The problem is, according to the criteria they choose for the report, it might take 5-10 minutes before you still see this error because of the hundreds of individual reports pdf it takes to generate. It is not until my code is ready to combine these pdf files they see the message. So, it is not really an error of execution, so to speak.

But, I found the answer to my question and I wanted to share with everyone. The answers are found here:

API: Whether an application is running

API: Get the class name of a running application

What I did, is to paste all of the code in these 2 pages in a new module of access. Then I made sure that Adobe Acrobat is loaded on my machine. I ran the fEnumWindows() void and it printed all my open programs class names. I got the class name for Adobe Acrobat, which is AcrobatSDIWindow. Then, I modified the select case statement in the following function, to include the Acrobat of the string and the name of the class:

[code]

Function fIsAppRunning (ByVal strAppName As String _

Optional FActivate As Boolean) As Boolean

Dim lngH As Long, strClassName As String

Dim GNLX As Long, lngTmp As Long

Const WM_USER = 1024

On Local Error GoTo fIsAppRunning_Err

fIsAppRunning = False

Select Case LCase$ (strAppName)

Case "excel": strClassName = "XLMain".

Case "word": strClassName = "OpusApp".

'Access' box: strClassName = 'Omain '.

Case "powerpoint95": strClassName = "PP7FrameClass.

Case "powerpoint97": strClassName = "PP97FrameClass.

Case 'Notepad': strClassName = "Notepad".

Case 'acrobat': strClassName = "AcrobatSDIWindow."

Case "wordpad": strClassName = "WordPadClass."

Case Else: strClassName = vbNullString

Select end

If strClassName = "" then

lngH = apiFindWindow (vbNullString, strAppName)

On the other

lngH = apiFindWindow (strClassName, vbNullString)

End If

If lngH <> 0 Then

apiSendMessage lngH WM_USER + 18, 0, 0

GNLX = apiIsIconic (lngH)

If GNLX <> 0 Then

lngTmp = apiShowWindow (lngH, SW_SHOWNORMAL)

End If

If fActivate then

lngTmp = apiSetForegroundWindow (lngH)

End If

fIsAppRunning = True

End If

fIsAppRunning_Exit:

Exit Function

fIsAppRunning_Err:

fIsAppRunning = False

CV fIsAppRunning_Exit

End Function

[/ code]

Now I can just send 'acrobat' this function to see if the application is open.

Sincerely,

David

Tags: Acrobat

Similar Questions

  • I have created a new domain with win2012r2 and created users. Add after the client in my area so that the newspaper with the user I get error below.

    Hello

    I have created a new domain with win2012r2 and created users. Add after the client in my area so that the newspaper with the user I get error below.

    "You cannot connect because the logon method, you use is not allowed on this computer, please, see your ad min for more information network"

    Please help me with that and I don't want to give permission to admin for all users group...

    Hello

    Post your question in the TechNet Server Forums, as your question kindly is beyond the scope of these Forums.

    http://social.technet.Microsoft.com/forums/WindowsServer/en-us/home?category=WindowsServer

    See you soon.

  • Upgrade to 8.1 fails "you must use an account with administrator privileges to install Windows 8.1." "Try loggin with the user of an administrator on this PC account and try the update again.

    Hello

    I have some difficulties to try to upgrade to windows 8... The computer asked me to go to 8.1, I click OK and it sends me to the store. Then I click on "Download Windows 8.1 Pro" and I get the message:
    "You must use an account with administrator privileges to install Windows 8.1." Try loggin with the user of an administrator on this PC account and retry the update", as shown in the attached picture.

    The thing is that I am the only administrator account.
    I also checked enable the built-in Administrator, by logging in and trying to here, but from the account built-in administrator is not aloud me to use Store.

    What can I do? Thank you

    Original title: upgrade Windows 8 Pro x 64 to Windows 8.1

    Hello

    I've read reports that uninstalling Windows Update KB2871389, and then put it back solves the problem.

    I read recently that this Fix - It might help...

    http://support.Microsoft.com/kb/971058/en-us

  • Opening a session with the user not admin

    Hi all

    I get this error when I connect with the user not admin.

    "Application is in maintenance mode, new connections are not allowed."

    No idea about this will be really helpful.

    You must identify yourself with the admin user and exit maintenance mode, the steps are here:-http://download.oracle.com/docs/cd/E17236_01/epm.1112/hp_admin/ch10s02s05.html

    That could post even though the steps are sometimes people find a bond far too difficult.

    Select Administration, Application and settings.
    For the show, select Advanced settings.
    Click OK.
    Select system settings.
    Application in Maintenance mode, select an option to allow use of the Application to:

    All users: all users can log in or continue working with the application.
    Administrator: Only administrators can log on. Other users are driven out and prevented to connect until the option is given to all users.
    Owner: Only the owner of the application can connect. All other users are unable to open a session. If they are currently logged in, they are forced from the system until the option is given to all users or administrators. Only the owner of the application can restrict administrators to use the application.

    If your selection is more restrictive than the current setting, click OK.
    Click Save.

    See you soon

    John
    http://John-Goodwin.blogspot.com/

  • You are about to open a session "keiron.me.uk" with the user name "Gerry" site, but the site requires no authentication. Maybe it's attempt to deceive you.

    http://Keiron.me.UK

    This very annoying message what I select my site

    You are about to log on the site "keiron.me.uk" with the user name "Gerry", but the site requires no authentication. Maybe it's attempt to deceive you.

    It is ok with Internet Explorer

    To resolve this problem, simply is to remove all bookmarks you have to keiron.me.uk and then re-create by vising the site by typing the address directly into the address bar.

    If you want to manually fix it then, check the properties of the location of all bookmarks that you have for keiron.me.uk. It is probably similar to http://keiron:[email protected] remove the keiron:password @ section and the dialog box should not appear again.

  • How to create a user local administrator with the user root on the CV

    As says the tile, how to create a user local administrator with the user root on VCS-Express. I lost the password and cannot log in as an admin user, but I can't seem to log as long as user root.

    Once connect you with the root account, type in "tsh", from there, you can create the accounts of local administrators with 'xCommand AdminAccountAdd.  See the reference section of command of the VCS Administrator's Guide, starting on pg 517.

    If your VCS is a virtual machine, you can change the password of admin with vSphere, or if it is a hardware appliance, you can use the serial port, see pg 312 of the Administrator's guide.

  • When I log in with the user account that reflects on the one hand by car, there is no batch file or a script in AD for this user profile

    Hello

    I created a new user in AD (Server 2003).

    When I connect with the user account that reflects on the one hand by car, it not there no batch file or a script in advertising for this user profile. I don't want user to access this part by car.

    If anyone can help.

    Kind regards

    Virendra Tainya

    Hello Virenda,

    Thanks for posting your query on the Microsoft Community.

    I would like to inform you that we have a support forum dedicated to systems on area issues, I suggest you to send your query on Microsoft TechNet forum for this issue. You can get more effective suggestions and adapted by experts familiar with this topic.

    Please visit the link below to find a community that will support what ask you:

     

    Microsoft TechNet

    https://social.technet.Microsoft.com/forums/WindowsServer/en-us/home?Forum=winservergen

    Hope the helps of information. Let us know if you need help with Windows related issues. We will be happy to help you.

    Thank you

  • Failed to connect with the user name "Administrator".

    Hello

    I want to configure vCD in VCO, but I am faced with error. I'm by train through the configuration of the vCO.

    I get the error message https://10.99.133.212:443 , Failed to connect with the user name "Administrator". And the description of the error is: "the API version information could not be obtained for the host https://10.99.133.212:443 () (administrator@System)!'."

    Here are the entries I provide:

    Host: 10.99.133.212

    Organization: System

    Authentication: basic

    Session: shared

    and name of user and password.

    What could be the error here? My vCO has IP 10.99.129.33. And I imported the vCD also SSL certificate.

    Kind regards

    Bethy

    You must first remove the new plug-in...

    VMware KB: Uninstall a plug-in for VMware vCenter Orchestrator

    Remember that you use step 6.3 in this article to delete the contents of the package as well. To verify that the workflow and actions have been removed, check that the following workflow category (and all children of it) no longer exist:

    / Library/vCloud Director

    And all related Action modules should have disappeared as well:

    com.vmware.library.vCloud. *.

    Once you have completed all steps of the KB, install version 5.1 of the plugin, configure and restart the vCenter Orchestrator Server service, once again to complete the installation.

  • How to share proof of publication of dps with the user of the window?

    How to share evidence of a dps publication made on a mac with the user of the window that needs proof it?

    If they are running on Windows 8.1, they install Adobe Content Viewer of the store to see the shared folio. Otherwise, they will need an iOS or Android to see the shared content.

    Neil

  • How can I add a form with the user name and password

    I would like to add a registration form with the user name and password. Are there any embedded html or widget for this

    Hello

    Here you will find a similar description:

    https://forums.Adobe.com/message/6078030

    https://forums.Adobe.com/message/6141887

    Thank you

    Sanjit

  • Failure to logon with the user SYS: ORA-01031: insufficient privileges

    Hello

    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
    PL/SQL Release 11.2.0.1.0 - Production
    CORE 11.2.0.1.0 Production
    AMT for Linux: Version 11.2.0.1.0 - Production
    NLSRTL Version 11.2.0.1.0 - Production

    OS: CentOS 5.5

    I can't log in with the user SYS via PL/SQL Developer. I get the message: ORA-01031: insufficient privileges. PL/SQL Developer is installed on Windows 7 Professional. Version of the Oracle Client is 11.2.0.1.0. However, I connect successfully with SYSMAN and SYSTEM.
    For those who may wonder if I try to connect 'as sysdba' when I use the SYS user, the answer is YES, I do.
    In addition, I think that the name of the tool (PL/SQL Developer) does not matter because I think I'm going to face the same error with any other tool (but I mentioned just in case).

    Server side, I have no problem with the SYS user. I can connect via SQLPlus with connect / as sysdba or connect "virtue sysdba" without fault.

    The sec_case_sensitive_logon initialization parameter is set to FALSE
    SQL > show parameter sensi

    VALUE OF TYPE NAME
    ------------------------------------ ----------- ------------------------------
    SEC_CASE_SENSITIVE_LOGON boolean FALSE

    I use the local name to connect and client side, I have a tnanames.ora file. The sqlnet.ora file looks like this:
    SQLNET.AUTHENTICATION_SERVICES= (NTS)
    
    NAMES.DIRECTORY_PATH= (TNSNAMES, EZCONNECT)
    I read in this forum (another thread) on the use of a password file. I created a password file using orapwd this way:
    orapwd file=orapwDB11G2 entries=100 ignorecase=y password=a_password
    where I replaced "a_password" with the SYS password.

    In fact, I'm not sure that the customer is influenced by the file password anyway because I said to use a local naming.

    Clues?

    Thank you very much!

    So your ORACLE_SID is planet but not DB11G2 , second password file must be located in $ORACLE_HOME/dbs location if you want to connect the planet of database/sid and therefore

    orapwd file= $ORACLE_HOME/dbs/orapwplanet password=syspass
    

    Then try again.

  • Interact with the user interface components

    I'm trying to find a GOOD way to interact with the external classes user interface components. For example, that you have a 'controller' class that needs to access the view of the user interface in some way (define a label text or something else). The controller class does not do anything, it discusses only the logic of what should be the case. Currently, it is created by my top-level class when the program starts. He listens to some events occur and needs to update/interact with the user interface or the State of the application depending on what events are. I do not seem to be a way for this controller class to easily access the UI component that I need to get my hands on.

    I'm trying to do to reduce the size of a file of mxml WindowedApplication growing (LOOK cool but that is not important) and take part of the logic of the application of this file.

    It's complicated by the fact that the label is in a State that does not have the status of 'base' (so it is not a child, or even a subsidiary child of the main class at boot time) and by the fact that it is not yet near a high school component. (If that were the case, I could probably just pass the label object in the constructor for the outdoor classroom.)

    In other words, I can't just call getChild ("labelName") on my 'main' request object because it is buried nested inside OTHER components. I don't think I like the idea to browse all components and sous-composants recursively looking for the component that my outer class trying to ask. I thought about other ideas, but I don't like any of them enough to try them, eh.

    I'm at the point now about where I come to the conclusion that my fundamental design strategy is wrong, or Flex just not allowing complex applications where the GUI components can interact with external classes relatively pain-free. I'm not convinced that "Flex cannot do', I'm looking for advice on some great Flex application in all design patterns.

    Where do you put this kind of control logic, and what happens when it starts to overflow and become so large that you need to break in other files?

    Found a solution, I think that's what I've been looking for:

    http://labs.Adobe.com/wiki/index.php/Cairngorm

  • I do not see my Acrobat Pro 11 upgrade download under my login

    I do not see my Acrobat Pro 11 upgrade download under my login

    Available downloadable Setup files:

    Download and installation help links Adobe

    Download and installation to Prodesigntools help links are located on the most linked pages.  They are essential; especially steps 1, 2 and 3.  If you click on a link that does not have these listed steps, open a second window by using the link to Lightroom 3 to see these "important Instructions". window using the Lightroom 3 link to see these "important Instructions".

  • I need acrobat pro to open a pdf file I created in quark and reduce the size of the file?

    I need acrobat pro to open a pdf file I created in quark and reduce the size of the file?

    It may be preferable to use a downsampling image option in Quark during the pdf creation process.

  • I have CS6 and creative cloud.  I get an error code when you download an update to the CS6.   have tried several times, checked to see if Safari has been opened, the download stops at 50%...then starts again and 100% and then I get error c

    Update for CS6 has a problem downloading... U44M1P7 ON MAC PHOTOSHOP.  I checked to see that Safari did not work, I plugged the Macbook Pro, and I tried for two days to make it work.  Download slows down to 50%, then continues up to 100% before giving the error U44M1P7.  Any suggestions?  I have CS6 and creative Cloud applications.

    Hello

    Please see Installation failed. Error U44M1P7 | Updates

    Hope that helps!

    Kind regards

    Sheena

Maybe you are looking for