This event executes twice… and regardless of the value of the Continue parameter, the PostDragDrop also executes. Apparently this event is all messed up rendering it worthless.
Subject: Another bug…
Apparently the querydragdrop and postdragdrop are all messed up. Regardless of whether Continue is set to true or false, the postdragdrop event also executes. Apparently the bug in QueryDragDrop has rendered this event worthless.
Subject: Stop code running twice workaround
Very irritating bug, may lead to my client ditching Notes.
To avoid the double execution add a global variable and insert this code in the querydragdrop event:
If queryDragCheck = “RAN_ALREADY” Then
queryDragCheck = ""
Else
Call DragDropFunction(Source) 'this is the code you want to run
queryDragCheck = "RAN_ALREADY"
End If
The problem with the stopping the drag/drop only seems to affect the mail file. I can get this to work on custom databases. This is not much comfort as I need it to work in the mail file. Seems to be an old bug as affects 6.5 too.
Anyone know of a workaround?
Subject: Workaround for QueryDragDrop
This works for my calendar problem at least.
Put all your QueryDragDrop code at the beginning of your PostDragDrop sub. If you want to prevent the drop then exit the sub before the existing PostDragDrop code runs.
I think the confusion lies in that I expected the QueryDragDrop code to run before the document moved and the PostDragDrop to run afterwards but this is not the case. The document only moves during the Post event.
So during the Post event I can see where the user is moving the document to and cancel the operation if necessary.