Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. sponsors. rss.
 From: Bernard Bout
  Where is Bernard Bout?
 Brisbane
 Australia
 Bernard Bout
 To: Yousfi Benameur
  Where is Yousfi Benameur?
 El Bayadh
 Algeria
 Yousfi Benameur
 Tags
Subject: RE: drop any image on form & listbox
Thread ID: 232560 Message ID: 233105 # Views: 39 # Ratings: 1
Version: Visual FoxPro 9 SP2 Category: Active X Controls & OLE Automation
Date: Tuesday, June 30, 2009 2:25:34 AM         
   


> >
> >
> >
> >
> > Much better as a scx file.
> >
> > What I meant about using the listbox is why use a listbox at all?
> > If you drag and drop many images you can still see only one file name in the "listbox". As such it acts more like a textbox.
> >
> >
> > Bernard
> >
> > ** If you see someone without a smile, give em one of yours :) **
> > My Blog
>
>
> you want to drag & drop a bomb into my listbox.its normal it is "anti bomb" :-U
> I tried to use a textbox but unsuccessfully. If you have a solution...thanks in advance.
>
> Dont rate please.its only for the pleasure to help.Give me only a feed back.
> Yousfi Benameur

To fix this error,just add this code to your Form::OleDragDrop event:

oDataObject.GetData(15, @aValues )
If EMPTY(aValues) &&<------------------------this is new
	Return
Endif             &&<-------------------- End of new code
For i = 1 To Alen(aValues)


and make the list look like a proper listbox.

Resize it, and AutoHideScrollbar = 0

Now that was much easier to do with a .scx than a prg.

Bernard

** If you see someone without a smile, give em one of yours :) **
My Blog



COMPLETE THREAD
drop any image on form & listbox Posted by Yousfi Benameur @ 6/24/2009 1:08:44 PM
RE: drop any image on form & listbox Posted by Bernard Bout @ 6/25/2009 1:54:50 AM
RE: drop any image on form & listbox Posted by Yousfi Benameur @ 6/25/2009 2:36:18 AM
RE: drop any image on form & listbox Posted by Cesar @ 6/25/2009 3:22:04 AM
RE: drop any image on form & listbox Posted by Yousfi Benameur @ 6/25/2009 11:17:22 AM
RE: drop any image on form & listbox Posted by Cesar @ 6/25/2009 3:12:09 PM
RE: drop any image on form & listbox Posted by Bernard Bout @ 6/29/2009 5:49:47 PM
RE: drop any image on form & listbox Posted by Yousfi Benameur @ 6/29/2009 7:17:56 PM
RE: drop any image on form & listbox Posted by Bernard Bout @ 6/30/2009 2:25:34 AM
RE: drop any image on form & listbox Posted by Yousfi Benameur @ 6/30/2009 10:02:36 AM
RE: drop any image on form & listbox Posted by Bernard Bout @ 6/30/2009 2:04:41 PM
RE: drop any image on form & listbox Posted by Yousfi Benameur @ 6/30/2009 10:37:14 AM
RE: drop any image on form & listbox Posted by Bernard Bout @ 6/29/2009 5:40:21 PM
RE: drop any image on form & listbox Posted by Bernard Bout @ 6/29/2009 5:37:03 PM
RE: drop any image on form & listbox Posted by Glen Villar @ 6/25/2009 1:59:12 AM
RE: drop any image on form & listbox Posted by Yousfi Benameur @ 6/30/2009 10:51:52 AM
RE: drop any image on form & listbox Posted by Bernard Bout @ 6/30/2009 2:10:01 PM
RE: drop any image on form & listbox Posted by Yousfi Benameur @ 6/30/2009 10:24:53 PM