Forum Discussion

MichaelP's avatar
MichaelP
Contributor
14 years ago

sysTreeView32 not recognised in Windows 7

Hello



The following code works fine when the script is run against Vista, but it always fails to recognise sysTreeView32 in Windows 7.  I'm not sure how to rectify this.  I'm testing remotely on Virtual Machines using Test Execute.



Set sysTreeView32 = Aliases.NXPowerLite.dlgBrowseForFolder.SHBrowseForFolderShellNameSpaceControl.SysTreeView32

  If Not sysTreeView32.Exists then

    Log.Error("sysTreeView32 is not recognised")  'It will always fail at this point in Windows 7 but its OK in Vista

    else

    Log.Message("sysTreeView32 is recognised")

  End if

 

  Call sysTreeView32.ClickItem("|Desktop")

  'Call sysTreeView32.Drag(631, 35, -2, 15)

  Call sysTreeView32.ClickItem("|Desktop|AutomatedTests")



Thanks.



Michael

  

1 Reply

  • Hi,



    The recognition parameters stored in Name Mapping for the 'SysTreeView32' object or one of its parents are incorrect. This can happen with some dialogs which can have different window class in different Windows versions. You need to check your Name Mapping scheme and correct the recognition parameters.



    When executing your code, you should get an 'object not found' error in the log. Check its Additional Information section to find out which exact object wasn't found and then compare properties of this object in Name Mapping and in the Object Browser to find the difference.