Article View: borland.public.cppbuilder.nativeapi
Article #10215Re: Drag Drop of "My Computer"
From: Remy Lebeau (TeamB)
Date: Wed, 05 May 2004 18:57
Date: Wed, 05 May 2004 18:57
30 lines
2059 bytes
2059 bytes
"Marc" <bukwheat@axess.com> wrote in message news:40992897$1@newsgroups.borland.com... > I have implemeted drag and drop functionality on this listbox > using the WM_DROPFILES windows message. This works > well with mostly everything BUT my drop target doesn't accept > the "My Computer", the "My Documents" or the "My Network > Places" when I try to drag them to my list box from my > WindowsXP menu. WM_DROPFILES only works with physical files. Those items are virtual objects instead. You can't use WM_DROPFILES for them at all. You will need to use OLE-based drag&drop instead. Look at the RegisterDragDrop() function and the IDragSource, IDropTarget, nad IDataObject interfaces, amongst other things. This type of drag&drop is vastly more complex to implement than WM_DROPFILES, however it is also the recommended way to handle drag&drop nowadays (WM_DROPFILES is deprecated) because of its flexibility. > Does anyone know if this is possible or does anyone > have any suggestions on how to make a drop target > accept these files. They are not files to begin with. What EXACTLY are you trying to accomplish in the first place? Gambit
Technical Details
Message-ID:
<40993a6e$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!controlnews3.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<40992897$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10cc67,5ac9936a289875fe X-Google-Attributes: gid10cc67,public From: "Remy Lebeau \(TeamB\)" <gambit47.no.spam@no.spam.yahoo.com> Newsgroups: borland.public.cppbuilder.nativeapi References: <40992897$1@newsgroups.borland.com> Subject: Re: Drag Drop of "My Computer" Date: Wed, 5 May 2004 11:57:27 -0700 Lines: 32 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 NNTP-Posting-Host: 67.22.138.253 Message-ID: <40993a6e$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1083783790 67.22.138.253 (5 May 2004 12:03:10 -0700) Path: arc1-ca.pugleaf.net!controlnews3.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail