Jump to content

Tree View Node check option is not working in some computers


SIBIKS
 Share

Recommended Posts

I implemented one tree view and try to check the nodes using ControlTreeView() API with "Check" option. It is working fine in both Win 7/10 machines. But the same is not working for some of the Win 10 machines. Is there any specific reason?

Please suggest if you any of you faced this problem.

Link to comment
Share on other sites

  • Moderators

@SIBIKS you will always have better luck if you share your code, so we're not having to guess at what you're doing.

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites


This is the function to check tree view node

Func TreeItemSelect()
; Retrieve a list of window handles.
Local $aList = WinList()
Local $hWnd = 0

; Loop through the array displaying only visable windows with a title.
For $i = 1 To $aList[0][0]
  If $aList[$i][0] = "Select Processing to Perform" Then
   $hWnd = $aList[$i][1]
  EndIf
Next

If $hWnd Then
   MsgBox($MB_SYSTEMMODAL, "", "Window exists", 5000)
Else
   MsgBox($MB_SYSTEMMODAL, "", "Window does not exist", 5000)
EndIf


$hwndTreeView = ControlGetHandle ( $hWnd, "", "SysTreeView321" )
If $hwndTreeView  Then
   MsgBox($MB_SYSTEMMODAL, "", "Tree exists", 5000)
Else
   MsgBox($MB_SYSTEMMODAL, "", "Tree does not exist", 5000)
EndIf

$iRetVal = ControlTreeView($hWnd,"",$hwndTreeView ,"Check","#1")
$iRetVal = ControlTreeView($hWnd,"",$hwndTreeView ,"Check","#1|#0")

$iRetVal = ControlTreeView($hWnd,"",$hwndTreeView ,"Check","#2")
$iRetVal = ControlTreeView($hWnd,"",$hwnd1,"Check","#2|#1")

EndFunc

Link to comment
Share on other sites

  • Moderators

Thought I moved this earlier. @SIBIKS please pay attention to where you post in the future, I have moved your thread to the appropriate forum for you this time. By posting in the correct forum you will get a lot more eyes on the problem. The Technical Support forum is for:

Quote

AutoIt Technical Discussion

Technical discussions, betas, editors, help file, add-on tools, etc.

 

And states:

Quote

Do not post general support questions here, instead use the AutoIt Help and Support forums

 

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...