Print Page | Close Window

Treeview unable to click node

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Controls
Forum Description: Topics Related to Codejock Controls
URL: http://forum.codejock.com/forum_posts.asp?TID=22445
Printed Date: 02 December 2024 at 4:01pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Treeview unable to click node
Posted By: Arnoutdv
Subject: Treeview unable to click node
Date Posted: 03 November 2014 at 8:09am
When the width of the text of a node exceeds the width of the treeview control then the control will show a kind of tooltip window on the position of the node text.

The node can be clicked on the main form, but if you show another instance of the same form then the tooltip text will block the NodeClick event.

Option Explicit

Private Sub Form_Load()
  With TreeView1
    .UseVisualStyle = True
    .Appearance = xtpAppearanceResource
    .Nodes.Add , , "base:0", "Some text"
    .Nodes.Add "base:0", xtpTreeViewChild, "child:0", "Some longer text"
    .Nodes.Add "base:0", xtpTreeViewChild, "child:1", "Even some longer text"
    .Nodes.Add "base:0", xtpTreeViewChild, "child:2", "The can text can be longer"
    .Nodes.Add "base:0", xtpTreeViewChild, "child:3", "This text is that long that a tooltip will appear, however I can't always be clicked anymore when compiled"
    .Nodes("base:0").Expanded = True
  End With
End Sub

Private Sub Command1_Click()
  Dim f As Form1
  
  Set f = New Form1
  f.Show vbModal
End Sub

Private Sub TreeView1_NodeClick(ByVal Node As XtremeSuiteControls.TreeViewNode)
  Label1.Caption = Node.Text
End Sub

Tested on 16.3.0 and 16.4.0


-------------
VB6 SP6, SuitePro 16.3.0 / 18.2.0, Win10/64



Replies:
Posted By: astoyan
Date Posted: 23 November 2014 at 9:36am
Hello Arnoutdv,

We tried your code on Win7, 16.4.0, compiled in VB6 SP6 but didn't notice any problem at all, regardless the number of forms we opened both the tooltip and the event worked as expected. Can you please do more tests on your side, probably even on different computers, and try to narrow down all possible factors?

Thank you.
Regards,
  Alexander Stoyan


Posted By: Arnoutdv
Date Posted: 24 November 2014 at 4:04am
Same environment:
Windows 7 32 bits, SuitePro 16.3.1, 16.4

Not only my development computer, but also on all client PCs (Windows 7 (32 and 64 bits), Windows 8(.1)), this using SuitePro 16.3.1


-------------
VB6 SP6, SuitePro 16.3.0 / 18.2.0, Win10/64


Posted By: jpbro
Date Posted: 24 November 2014 at 5:33pm
I tried this too using 16.2.6 on WinXP - I can reproduce the problem as described by Arnoutdv. Works fine on the first window, but when you show a subsequent window you can't click the long item when the tooltip appears.


-------------
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6



Posted By: Arnoutdv
Date Posted: 16 December 2014 at 9:04am
As a temporary fix I have set the .HotTracking property to True.
The visual effect is unwanted, but at least the nodes can be clicked.




-------------
VB6 SP6, SuitePro 16.3.0 / 18.2.0, Win10/64



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net