SetItemState(hCurrent,LVIS_FOCUSED|LVIS_SELECTED,LVIS_SELECTED);
This will highlight the entry I am interested in but not give it the focus
with in turn doesn't make it the
selected entry. Anyone?
Thanks
Ralph Krausse
Ralph,
Try:
SetItemState( hCurrent,
LVIS_FOCUSED|LVIS_SELECTED,
LVIS_FOCUSED|LVIS_SELECTED);
Dave
--
My address is altered to discourage junk mail.
Please post responses to the newsgroup thread,
there's no need for follow-up email copies.
Thanks Dave
David Lowndes <dav...@mvps.org> wrote in message
news:cfup3s4c1urmsmm7v...@4ax.com...
Can you explain a little more about your particular situation where it
doesn't work?
Are you actually trying to give the control focus? Have you tried
using SetFocus (or GotoDlgCtrl if the control is in a dialog)?
thanks
David Lowndes <dav...@mvps.org> wrote in message
news:4d664s0ir7ir55aeh...@4ax.com...
If you add some items to the tree, then select one with the mouse to
highlight it, then move focus by selecting another control on the
dialog, is the selection in the tree control still visible? If it
isn't I think all you need is to set the TVS_SHOWSELALWAYS style (show
selection always, on the Styles tab in the dialog editor) for the
control.