ContributionsMost RecentMost LikesSolutionsRe: DirectUIHWND in Windows 7Try to use MSAA plug-in (read "Testing with Microsoft Active Accessibility" help topic). You should add class name of you problematic control (e.g. "DirectUIHWND") to the list of windows that will be shown as MSAA objects. To do this just open "Default Project Properties" dialog, navigate to the "Project -> Open Applications -> MSAA" node, and add class name of your control, which should be recognized as MSAA object (e.g. "DirectUIHWND"). Also note, that "MSAA Open Application" plug-in should be installed. Once expanded via MSAA, the "DirectUIHWND" object exposes properties, methods and child objects you can use to work with it. In your Object Browser you should see something like that: ...Window("SHELLDLL_DefView", "ShellView", 1).List("Items View").ListItem("$Recycle.Bin") ...Window("SHELLDLL_DefView", "ShellView", 1).List("Items View").ListItem("my test file.txt") ...Window("SHELLDLL_DefView", "ShellView", 1).List("Items View").ListItem("My_Test_Folder") and so on... But here you can be faced with the next issue. List("Items View") MSAA object shows only visible child objects in the Object Browser tree (e.g. children, with Visible = true). Also List("Items View").ItemCount shows only number of visible children ListItem. To find some item, which is not visible on screen, you should do some scroll with mouse wheel on you control, and review the children objects of List("Items View") object.Re: Enable to connect to Oracle DB from Virtual machine using ADOHi David, Thanks for your suggestion, but looks like it also won't work. Now I got the following message at attempt to connect to DB from virtual machine: "Oracle client and networking components were not found. These components are supplied by Oracle Corporation and are part of the Oracle Version 7.3.3 or later client software installation. Provider is unable to function until these components are installed." I will appreciate any suggestion. (Oracle database is installed on Win 7 platform, and I try to connect to this database from Win XP platform, that is run under virtual machine). Thanks.Enable to connect to Oracle DB from Virtual machine using ADOLooks like my question is not related to TestComplete, but might someone can help me to solve the problem. I have installed Oracle Database 10g Express Edition on my PC (full PC name is "MyPC.MyDomain.com"). After that I am trying to execute some SQL query (with help of TestComplete) to data base called "XE" with the following code snippet: var connection = new ActiveXObject("ADODB.Connection") ; var connectionstring = "Driver={Microsoft ODBC for Oracle};Server=MyPC.MyDomain.com:1521/XE;Uid=MyUid;Pwd=MyPwd;"; connection.Open(connectionstring); ... This piece of code works fine on my local PC, but it won't work when I am trying to run the same code from virtual machine that is run on PC where Oracle database is installed. I get the following error: "The Oracle(tm) client and networking components were not found. These components are supplied by Oracle Corporation and are part of the Oracle Version 7.3 (or greater) client software installation." I have also tried to change connectionstring to the following: var connectionstring = "Provider=OraOLEDB.Oracle;dbq=MyPC.MyDomain.com:1521/XE;Database=XE;User Id=MyUid;Password=MyPwd;"; In this case I also can query data base on my local machine (e.g. on PC named "MyPC.MyDomain.com") without any problems. But I got the following error message at attempt to run the same script from virtual machine: "Provider cannot be found. It may not be properly installed." Could someone help me to solve the problem? Also can someone tell me whether it is possible to execute SQL query with help of JScript on some database that is running on some server somewhere in the internet (of course in case I have login credentials to this data base). Thanks in advance.Re: Selecting the application in the trayHi, Below is the script, that I am currently use (JScript): var LOCK_ICON // global variable that will contain reference to system tray (will be initialized in "FindIconInSystemTray" function) function ClickIconInSystemTray(sIconTitle, bIsLeftMouseButton, bIsDoubleClick, bRShiftPressed) { if(typeof(bIsLeftMouseButton) != "boolean") bIsLeftMouseButton = false; if(typeof(bIsDoubleClick) != "boolean") bIsDoubleClick = false; if(typeof(bRShiftPressed) != "boolean") bRShiftPressed = false; if(FindIconInSystemTray(sIconTitle) == -1) { Log.Message("Can't click icon in the system tray, because of icon with '" + sIconTitle + "' title does not exist here!"); return false; } try { if(bRShiftPressed) { Win32API.keybd_event(Win32API.VK_RSHIFT, 0, Win32API.KEYEVENTF_EXTENDEDKEY, 0); BuiltIn.Delay(500); } if(bIsLeftMouseButton) { if(bIsDoubleClick) ICON_TRAY.DblClickItem(sIconTitle + "*", true, skNoShift); else ICON_TRAY.ClickItem(sIconTitle + "*", true, skNoShift); } else { if(bIsDoubleClick) ICON_TRAY.DblClickItemR(sIconTitle + "*", true, skNoShift); else ICON_TRAY.ClickItemR(sIconTitle + "*", true, skNoShift); } if(bRShiftPressed) { BuiltIn.Delay(500); Win32API.keybd_event(Win32API.VK_RSHIFT, 0, Win32API.KEYEVENTF_EXTENDEDKEY | Win32API.KEYEVENTF_KEYUP, 0); } } catch(e) { Log.Message("Can't click icon in the system tray!", e.description); return false; } return true; } function FindIconInSystemTray(icon_title) // return index of required icon in the system tray { var oSysTray = null; var start = getTime(); do { oSysTray = Sys.Process("Explorer").WaitWindow("Shell_TrayWnd", "*", 1, 1000).WaitWindow("TrayNotifyWnd", "*", 1, 1000); if(! oSysTray.Exists) continue; ICON_TRAY = oSysTray.WaitWindow("SysPager", "*", 1, 1000).WaitWindow("ToolbarWindow32", "*Notification Area", 1, 1000); if(! ICON_TRAY.Exists) { oSysTray.Refresh(); BuiltIn.Delay(100); continue; } for(var s=0; s<ICON_TRAY.wButtonCount; s++) { if(ICON_TRAY.wButtonText(s, true).indexOf(icon_title) != -1) return s; } ICON_TRAY.Refresh(); BuiltIn.Delay(100); } while(getTime() - start < 10000) return -1; }Re: Problem with calling function from user32.dllThanks Jared for your answer! I will try to find some solution. Might be you can answer one more question. I have created some jscript, which I run with WScript. In this script I use TestComplete's COM (integration object) to retrieve main window object of my tested application and to check caption of this window. I run this script automatically when I start test cases execution from TestComplete (e.g. I have added run of this external script to the "OnStartTestCase" event) So when my test cases starts in TestComplete, this external script also starts throw command line and it checks whether main window of my tested application contains "Not Responding" string in the window caption. The problem is that my external script alway return only real caption of my window at runtime even in case this window contains "Not Responding" string (e.g. external script return caption of the window without "Not Responding"). TestComplete see caption of the hung window correctly in case I stop scripts execution, and navigate to my hung window in Object tree. Could you please tell me why this happens and how can I catch window with "Not Responding" caption at runtime? Re: Problem with calling function from user32.dllHi Jared! I have added parent process of the window (window, on which test complete hung, when this window hung) to the list of Freeze Diagnostics properties of my test project, but this does not help. One of the child window still hung during scripts run and TestComplete hung with this window at attempt to send some event (might be click event) to this window. Do you have other suggestion on how I can recognize whether some WINDOW (NOT parent PROCESS) stops responding? Thanks in advance!Re: Problem with calling function from user32.dllHi Jared! Thanks for your quick response. Do you have some suggestion how can I check some window (not process) for responding? I have tried to find window with "*Not Responding*" caption buy using FindAllChildren function of the process, but this function return nothing even in case when window with such caption displayed on the screen. Any suggestion will be helpful. Thanks.Problem with calling function from user32.dllHi, I am trying to create script which will check whether some process have hung window. I have found "IsHungAppWindow" Win32Api function (http://msdn.microsoft.com/en-us/library/ms633526(VS.85).aspx) that is suitable for my purposes, but I have problems with its calling from my script. Attempt to call this function via Win32API TestComplete's program object leads to error: "Object doesn't support this property or method". var oWnd = Sys.WaitProcess("MyProccess").WaitWindow("MyWindow"); if(oWnd.Exists) { var bIsHungWnd = Win32API.IsHungAppWindow(oWnd.Handle); // Here I got error message. ... } Also I have found information that "IsHungAppWindow" function defined in "user32.dll". So I am trying to call this function via DLL TestComplete's program object in the following way: var oWnd = Sys.WaitProcess("MyProccess").WaitWindow("MyWindow"); if(oWnd.Exists) { var Def_Environment = DLL.DefineEnvironment(true); var Def_DLL = Def_Environment.DefineDLL("USER32"); Def_DLL.DefineProc("IsAppWndHung", vt_i4, vt_bool); Def_DLL.DefineAlias("IsHungAppWindow", "IsAppWndHung"); var Lib = Def_Environment.Load("C:\\Windows\\System32\\USER32.dll"); var bIsHungWnd = Lib.IsHungAppWindow(oWnd.Handle); // Here I got error "Object doesn't support this property or method" ... } Could someone help me to solve the problem with using "IsHungAppWindow" Win32 api function, or please just point me to the wrong place in my script. Thanks in advance, John.How to leave slave PC unlocked after task execution on it? Hi there! I have discovered, that TC8 distributed testing works different than this was in TC7. Now TC8 works with Slave PC (network suite) under some user profile, and it leaves PC locked after network job is done. It's not convenient in our case, because on this Slave PC some scripts should be executed according to the scheduling – but if it is locked, scripts will fails. Is there any possibility to leave PC unlocked when network job is completed? Thanks in advance.Re: How can I work with IE Browser back button?Try to use "GoBack" method of "...Window("Shell DocObject View", "", 1).Window("Internet Explorer_Server", "", 1)" object.