C++/VB - End-user deselecting all items in a Tree-View conrol

Asked By Edward Diener
11-Nov-09 02:36 PM
How does an end-user deselect all items in a Tree-View control ? I know
I can do this programatically, but I need to test when end-user does this.

In general where can I find information about keyboard/mouse
manipulation of Windows controls and UI by an end-user.
FeedList.SelectedItem
(1)
FeedList.HitTest
(1)
EMVP
(1)
PenFact
(1)
HitTest
(1)
Windows
(1)
Catcher
(1)
Boston
(1)
  Dee Earley replied to Edward Diener
12-Nov-09 06:36 AM
Normally just clicking an empty part of the window or selecting a new item.

I did not think the treeview had multiselect without doing it yourself.


I am not sure of an end user reference, but the SDK sometimes documents this.

--
Dee Earley (dee.earley@icode.co.uk)
i-Catcher Development Team

iCode Systems
  Edward Diener replied to Dee Earley
12-Nov-09 10:57 AM
Selecting a new item obviously does not deselect all items. If I click
another part of the window it does not deselect the item selected.


You are correct. It is single select. But I believe there is some way
for the end user of deselecting the currently selected item without
selecting another item. If there is, I need to test this out.


I could not find anything in the MSDN docs about end-use user
keystrokes/mouse for controls. Maybe it is there somewhere but I did not
see it. It should surely be somewhere.
  Dee Earley replied to Edward Diener
13-Nov-09 05:13 AM
I would not say it is obvious...
Especially as the first one I tried did.

Having said that, I do have this in mousedown:
Set FeedList.SelectedItem = FeedList.HitTest(X, Y)

--
Dee Earley (dee.earley@icode.co.uk)
i-Catcher Development Team

iCode Systems
  Edward Diener replied to Dee Earley
13-Nov-09 10:14 AM
I do not understand your answer. I am interested in how the end-user,
not the programmer, can deselect all items in a Tree-View control.
  r_z_are replied to Dee Earley
13-Nov-09 11:13 AM
If you add the style TVS_CHECKBOXES, the treeveiw displays checkboxes
so the user can select multiple items. Functional, but not pretty.


-----------------------------------------
To reply to me, remove the underscores (_) from my email address (and please indicate which newsgroup and message).

Robert E. Zaret, eMVP
PenFact, Inc.
20 Park Plaza, Suite 400
Boston, MA 02116
www.penfact.com
  Dee Earley replied to Edward Diener
13-Nov-09 12:12 PM
There does not appear to be a standard way, but adding that one line of
code (in an appropriate language) allows them to.

I guess this also answers the documentation question as:

--
Dee Earley (dee.earley@icode.co.uk)
i-Catcher Development Team

iCode Systems
  Edward Diener replied to Dee Earley
13-Nov-09 01:50 PM
I have not found HitTest as a Windows API function.

without selecting another tree-view item ? If so, how does the end-user
do that even given that you can tell me where HitTest can be found ?
  Drew replied to Edward Diener
13-Nov-09 02:38 PM
Does Ctrl+click deselect it?
  Edward Diener replied to Drew
15-Nov-09 02:23 AM
No, it does not.
  Dee Earley replied to Edward Diener
16-Nov-09 06:17 AM
The native message is TVM_HITTEST.
I have no idea what language/environment you are using so I cannot say
more than that.


By just clicking on something in the tree that is not an item.
Practically any white space counts as this.
The code (when translated) will select whichever item is under the mouse
pointer on mousedown. If there is no item, nothing is selected.

Fairly intuitive IMO.

--
Dee Earley (dee.earley@icode.co.uk)
i-Catcher Development Team

iCode Systems
help
in windows ce Win32 WinCE Discussions Bruce.Eitman (1) RWIniFiles (1) EMVPEntrek (1) StbINI (1) EMVP (1) MvarstrIniFile (1) StringBuilder (1) CodeProject (1) Write an ini file parser. - - Michael Salamone, eMVP Entrek Software, Inc. www.entrek.com In what way do you plan on using an kinds of wacky answers. In Windows CE, INI files are not typically used. - - Bruce Eitman (eMVP) Senior Engineer Bruce.Eitman AT EuroTech DOT com My BLOG http: / / geekswithblogs.net / bruceeitman EuroTech not, then as Michael said, you will need to write the code yourself. - - Bruce Eitman (eMVP) Senior Engineer Bruce.Eitman AT EuroTech DOT com My BLOG http: / / geekswithblogs.net / bruceeitman EuroTech www.EuroTech.com Thanx On Fri, 3 Oct 2008 12:51:44 -0400, "Bruce Eitman [eMVP]" I strongly disagree. The registry is a shared resource, and I believe in avoiding shared _) from my email address (and please indicate which newsgroup and message). Robert E. Zaret, eMVP PenFact, Inc. 20 Park Plaza, Suite 400 Boston, MA 02116 www.penfact.com On Fri _) from my email address (and please indicate which newsgroup and message). Robert E. Zaret, eMVP PenFact, Inc. 20 Park Plaza, Suite 400 Boston, MA 02116 www.penfact.com keywords: IniFiles
VB Hi, How to buy WinCE license? Thanks! Win32 WinCE Discussions WinCE (1) ComHi (1) EMVP (1) CE (1) License (1) Distributor (1) Salamone (1) Michael (1) Contact a WinCE distributor directory of them on Microsoft's Windows Embedded Partner site - www.mswep.com. - - Michael Salamone, eMVP Entrek Software, Inc. www.entrek.com Hi, Does anyone know if there is a tool
any ideas ? regards, Saju Win32 WinCE Discussions WM_MEASUREITEM (1) GetWindowRect (1) SetWindowPos (1) MoveWindow (1) EMVP (1) SajuThere (1) UGdRfHHA (1) MSFTNGP (1) There are no items in a button, just you want its dimensions. Or MoveWindow / SetWindowPos if you want to resize it. - - Michael Salamone, eMVP Entrek Software, Inc. www.entrek.com It is just that the documentation says owner drawn GetWindowRect Actually it is just for combobox and listbox - which do have items. - - Michael Salamone, eMVP Entrek Software, Inc. www.entrek.com keywords: Ownerdraw, button description: Hi all, Why do not