DebugConfigPath Property

Applies to TestComplete 12.60, last modified on September 17, 2018

Description

Returns the path to the Flash player configuration file in your system.

Declaration

FlashSettingsObj.DebugConfigPath

Read-Only Property String
FlashSettingsObj An expression, variable or parameter that specifies a reference to a FlashSettings object

Applies To

The property is applied to the following object:

Property Value

A fully qualified path to the Flash player configuration file.

Remarks

The property returns the path to the configuration file of Flash Player for Internet Explorer and Firefox. By default, the file is located at –

<System_Drive>\<Users>\<User_name>\mm.cfg

The configuration file of Flash Player for Google Chrome is in another folder –

<System_Drive>\<Users>\<User_name>\AppData\Local\Google\Chrome\User Data\Default\Pepper Data\Shockwave Flash\System\mm.cfg

Example

The code below checks whether the debug version of Flash player is installed in Internet Explorer. Then it installs the FlashInjector module (if needed), and posts the path to the Flash player's configuration file and file contents to the test log. Then it uninstalls the FlashInjector module:

JavaScript, JScript

function FlashInjectorInstall()
{
  // Check whether FlashInjector is already configured
  if (!Options.FlashSettings.IsInjectorInstalled)
    // Check whether Internet Explorer has the debug version of Flash player installed
    if (Options.FlashSettings.IsDebugVersion())
    {
      // Install the FlashInjector module
      Options.FlashSettings.InstallInjector();
      Log.Message("FlashInjector is successfully installed");

      // Post the path to the configuration file and its contents to the test log
      Log.Message("The path to the configuration file:" + Options.FlashSettings.DebugConfigPath);
      Log.Message("The configuration file contents:" + Options.FlashSettings.DebugConfigContents);

      // Uninstall the FlashInjector module
      Options.FlashSettings.UninstallInjector();
      Log.Message("FlashInjector is successfully uninstalled");
    }
    else

      Log.Message("Debug version of Flash player is not installed in Internet Explorer");
  else

    Log.Message("FlashInjector is already installed");
}

Python

def FlashInjectorInstall():

  # Check whether FlashInjector is already configured
  if not Options.FlashSettings.IsInjectorInstalled:
    # Check whether Internet Explorer has the debug version of Flash player installed
    if Options.FlashSettings.IsDebugVersion():
      # Install the FlashInjector module
      Options.FlashSettings.InstallInjector()
      Log.Message("FlashInjector is successfully installed")

      # Post the path to the configuration file and its contents to the test log
      Log.Message("The path to the configuration file:" + Options.FlashSettings.DebugConfigPath)
      Log.Message("The configuration file contents:" + Options.FlashSettings.DebugConfigContents)

      # Uninstall the FlashInjector module
      Options.FlashSettings.UninstallInjector()
      Log.Message("FlashInjector is successfully uninstalled")
    else:
      Log.Message("Debug version of Flash player is not installed in Internet Explorer")
  else:
    Log.Message("FlashInjector is already installed")

VBScript

Sub FlashInjectorInstall()

  ' Check whether FlashInjector is already configured
  If (Not Options.FlashSettings.IsInjectorInstalled) Then

    ' Check whether Internet Explorer has the debug version of Flash player installed
    If (Options.FlashSettings.IsDebugVersion) Then 
  
      ' Install the FlashInjector module
      Call Options.FlashSettings.InstallInjector()
      Log.Message "FlashInjector is successfully installed"

      ' Post the path to the configuration file and its contents to the test log
      Log.Message "The path to the configuration file:" + Options.FlashSettings.DebugConfigPath
      Log.Message "The configuration file contents:" + Options.FlashSettings.DebugConfigContents

      ' Uninstall the FlashInjector module
      Call Options.FlashSettings.UninstallInjector()
      Log.Message "FlashInjector is successfully uninstalled"

    Else
      Log.Message "Debug version of Flash player is not installed in Internet Explorer"
    End If 

  Else
    Log.Message "FlashInjector is already installed"
  End If

End Sub

DelphiScript

procedure FlashInjectorInstall();
begin

  // Check whether FlashInjector is already configured
  if (not Options.FlashSettings.IsInjectorInstalled) then
    // Check whether Internet Explorer has the debug version of Flash player installed
    if (Options.FlashSettings.IsDebugVersion()) then
    begin
      // Install the FlashInjector module
      Options.FlashSettings.InstallInjector();
      Log.Message('FlashInjector is successfully installed');

      // Post the path to the configuration file and its contents to the test log
      Log.Message('The path to the configuration file:' + Options.FlashSettings.DebugConfigPath);
      Log.Message('The configuration file contents:' + Options.FlashSettings.DebugConfigContents);

      // Uninstall the FlashInjector module
      Options.FlashSettings.UninstallInjector();
      Log.Message('FlashInjector is successfully uninstalled');
    end
    else
      Log.Message('Debug version of Flash player is not installed in Internet Explorer')
  else
    Log.Message('FlashInjector is already installed')
end;

C++Script, C#Script

function FlashInjectorInstall()
{
  // Check whether FlashInjector is already configured
  if (!Options["FlashSettings"]["IsInjectorInstalled"])

    // Check whether Internet Explorer has the debug version of Flash player installed
    if (Options["FlashSettings"]["IsDebugVersion"]())
    {
      // Install the FlashInjector module
      Options["FlashSettings"]["InstallInjector"]();
      Log["Message"]("FlashInjector is successfully installed");

      // Post the path to the configuration file and its contents to the test log
      Log["Message"]("The path to the configuration file:" + Options["FlashSettings"]["DebugConfigPath"]);
      Log["Message"]("The configuration file contents:" + Options["FlashSettings"]["DebugConfigContents"]);

      // Uninstall the FlashInjector module
      Options["FlashSettings"]["UninstallInjector"]()
      Log["Message"]("FlashInjector is successfully uninstalled");
    }

    else
      Log["Message"]("Debug version of Flash player is not installed in Internet Explorer");
  else
    Log["Message"]("FlashInjector is already installed");
}

See Also

FlashSettings Object Properties
FlashSettings Object
Testing Flash and Flex Applications with the Debug Version of Flash Player - Overview

Highlight search results