Solved

Drag And Drop Into Word VBA ListBox Produces No Events

Posted on 2002-04-23
5
1,181 Views
Last Modified: 2012-08-13
In a Word VBA application, I have a ListBox inside of a Tab control and I am trying to drag and drop files into the ListBox.  Inside of the BeforeDropOrPaste method, I put a simple MsgBox to see when the event fires.  Apparently, it never does.  I did the same with the BeforeDrag event and those events come through just fine.  What am I missing?
0
Comment
Question by:tewald
  • 3
5 Comments
 
LVL 3

Expert Comment

by:Bahnass
ID: 6964284
events of listbox or the other file control

May be VB understand it different than U
:-)
0
 
LVL 44

Accepted Solution

by:
bruintje earned 200 total points
ID: 6964918
Hi Tewald,

if i try this it seems to work
-new userform
-listbox on it

Private Sub ListBox1_BeforeDropOrPaste(ByVal Cancel As MSForms.ReturnBoolean _
              , ByVal Action As Long _
              , ByVal Data As MSForms.DataObject _
              , ByVal X As Single, ByVal Y As Single, _
              ByVal Effect As MSForms.ReturnEffect, ByVal Shift As Integer)
  Cancel = True
  Effect = fmDropEffectCopy
  MsgBox "hello"
End Sub

:O)Bruintje
0
 
LVL 44

Expert Comment

by:bruintje
ID: 6982954
Hi Tewald, any update on this one? :O)Bruintje
0
 
LVL 44

Expert Comment

by:bruintje
ID: 7019459
---------------------------
Hi (Name)
 
Any update on this question?

in an effort to clean up old open questions

+----------------------------------------------------+
Your options are:

1. Accept a Comment As Answer (use the button next to the Expert's name).
2. Close the question if the information was not useful to you, but may help others. You must tell the
participants why you wish to do this, and allow for Expert response.  This choice will include a refund
to you, and will move this question to our PAQ (Previously Asked Question) database.  If you found information
outside this question thread, please add it.
3. Ask Community Support to help split points between participating experts, or just comment here with
details and we'll respond with the process.
4. Delete the question (if it has no potential value for others).
 --> Post comments for expert of your intention to delete and why
 --> You cannot delete a question with comments, special handling by a Moderator is required.

For special handling needs, please post a zero point question in the link below, include the question

QID/link. http://www.experts-exchange.com/jsp/qList.jsp?ta=commspt

Please click this Help Desk link for Member Guidelines, Member Agreement and the Question/Answer process:
Click you Member Profile to view your question history and keep them all current with updates as the
collaboration effort continues. http://www.experts-exchange.com/jsp/cmtyHelpDesk.jsp
+----------------------------------------------------+


+----------------------------------------------------+
IMPORTANT #1
+----------------------------------------------------+
EXPERTS:    Please leave any comments regarding this question here on closing recommendations
if this item remains inactive another seven (7) days.
+----------------------------------------------------+


+----------------------------------------------------+
IMPORTANT #2
+----------------------------------------------------+
Bruintjes recommendation
-PAQ
-Points to Bruintje
+----------------------------------------------------+


---------------------------
Thanks
:O)Bruintje
---------------------------
0
 
LVL 5

Expert Comment

by:Netminder
ID: 7065442
Per recommendation, force-accepted by
Netminder
CS Moderator
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Using Word 2013, I was experiencing some incredible lag when typing.  Here's what worked for me....
This article will guide you to convert a grid from a picture into Excel format using Microsoft OneNote and no other 3rd party application.
This video walks the viewer through the process of creating Hyperlinks for the web and other documents. Select the "Insert" tab: Click "Hyperlink":  Type "http://" followed by a web address to reference a website or navigate to a document to ref…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question