wfpool class : ExistByProcessName(string) method

Description

Gets a value indicating whether a top-level window with the specified process name exists.

Syntax

wfpoolInstance.ExistByProcessName(string processName)

Arguments

ClassNameDescription
stringprocessNameA process name.

Return value

ClassDescription
boolA value that indicates whether it exists.

Sample code

1:

wfpool wfp;

2:

bool exist = wfp.ExistByProcessName("ApplicationFrameHost");

Notes

The top-level windows are windows that do not have a parent.

A process name for the UWP (Universal Windows Platform) applications like the Edge, Calculator, or windows store application is the "ApplicationFrameHost". That is, these applications can not distinguish by process name.

Links for reference

None

Copyright © Cooker All rights reserved.