Differentiating between multiple runas account windows
Solution 1:
I did find a way to address this via AutoIt. It isn't perfect but I can get most of my windows labeled. My users can launch this and have it run in the background as needed.
#Include <Array.au3>
#include <WinAPIEx.au3>
While ( True )
Sleep( 100 )
Local $PID = 0
Do
$handle = WinGetHandle("[ACTIVE]", "")
$iPID = WinGetProcess($handle)
Until $iPID > 0
Local $aUser = _WinAPI_GetProcessUser($PID)
$UserName=$aUser[0]
$title = WinGetTitle ( $handle )
$result = StringInStr($title, "Owned By")
If ( $Result == 0 ) Then
WinSetTitle($handle, "", $title & " - Owned By " & $UserName)
$title = WinGetTitle ( $handle )
EndIf
WEnd