Attaching to a Running Process

From Appmethod Topics
Jump to: navigation, search

Go Up to Debugging Applications Index

You can attach to a process that is running on your local PC, on a remote PC, a Mac OS X machine, or an iOS simulator running on a Mac. For example, attaching to a process can be useful for debugging a program that was not created with Appmethod.

To attach to a running process

  1. Choose Run > Attach to Process to display the Attach to Process dialog box.
    By default, the Attach to Process dialog displays the processes running locally, for which the default debugger is the Embarcadero Win32 Debugger.
  2. Select the appropriate debugger from the Debugger drop-down list:
    Select this debugger If the process is ...

    Embarcadero Win32 Debugger


    • A local 32-bit application
    • An app running on a remote 32-bit PC

    Embarcadero Mac OS X Debugger


    • A Mac OS X app
    • An iOS app running on an iOS simulator on a Mac

    Embarcadero Win64 Debugger

    A 64-bit Windows process, running either:

    • On your local 64-bit Windows development system
    • On a remote 64-bit Windows system
    You cannot select the following debuggers
    • Embarcadero iOS Device Debugger

    Does not support Attach to Process

    • Embarcadero Android Device Debugger

    Does not support Attach to Process

  3. Specify the Remote Machine where the process is running (either host name or IP address):
    For Mac OS X and iOS:
    1. Click the ellipsis in the Remote Machine field, and select an existing connection profile or add a new connection profile on the Select Connection Profile dialog box.
    2. The Platform Assistant must be running on the Mac. These steps are required in order for you to use the integrated debugger in the IDE for debugging.
  4. The list of Running Processes is refreshed to display the processes running either locally or on the remote machine.
    • For multi-device processes, the selected debugger attempts to connect to the specified remote machine.
    • For Mac OS X and iOS, if a connection profile does not exist for the specified remote machine, or if the Platform Assistant server is not running on the Mac, an error is displayed, "Unable to connect to remote host." To Create a Connection Profile or to select from existing connection profiles, click the ellipsis button [...].
  5. Select a process from the list of Running Processes.
  6. To include system processes in the list, check Show System Processes.
  7. If you do not want the process to pause after you have attached to it, uncheck Pause After Attach.
  8. Click Attach. The CPU Windows open.

See Also