Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / September 2005

Tip: Looking for answers? Try searching our database.

TVS_TRACKSELECT for treeview?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Roland Müller - 19 Sep 2005 15:24 GMT
Hi NG,

i want for my drag and drop treeview control the style TVS_TRACKSELECT
(for example the IE 6 uses this; go to favorites sidebar and drag/drop a
bookmark...): the bold horizontal line between the nodes...

I tried this:

--------------------------------------------------------------------------------
private int TVS_TRACKSELECT = 0x200;
private int GWL_STYLE=-16;
        [DllImport("user32.dll")] private extern static IntPtr
SetWindowLong(IntPtr hWnd, int nIndex, int dwNewLong);
        [DllImport("user32.dll")] private extern static int
GetWindowLong(IntPtr hWnd, int nIndex);

            int style = GetWindowLong(m_SchemaTreeView.Handle,GWL_STYLE);
            SetWindowLong(m_SchemaTreeView.Handle,GWL_STYLE, style |
TVS_TRACKSELECT);
--------------------------------------------------------------------------------

But it does not appear in my treeview. How can I get this style the
right way?

Thanks, Roland!
Atul - 21 Sep 2005 05:05 GMT
The code for enabling TrackSelect is OK, but I don't think enabling this
style causes the treeview to show the dragdrop insertion bold horizontal
line. You have to draw that yourself.

-Atul, Sky Software http://www.ssware.com
Shell MegaPack For ActiveX & .Net - Windows Explorer Like Shell UI Controls

> Hi NG,
>
[quoted text clipped - 20 lines]
>
> Thanks, Roland!

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.