UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
 
   Reply to this topicStart new topic
> Drag And Drop Wm_dropfiles Windows 2010 Doesn't Work, Any Version    
 
   
STEPH9111
post Aug 7 2018, 08:34 AM
Post#1



Posts: 8
Joined: 2-August 18



Hi, i'm using the excelent code DragDropApi but run with access 2010 and window 10 only when i change HKEY_LOCAL_MACHINE > SOFTWARE > Microsoft > Windows > CurrentVersion EnableLUA at 0

But in case of Access 2016, with the same change, the WS_EX_ACCEPTFILES not fire.

Any idea?

Go to the top of the page
 
GroverParkGeorge
post Aug 7 2018, 09:33 AM
Post#2


UA Admin
Posts: 33,269
Joined: 20-June 02
From: Newcastle, WA


This is an interesting scenario.

Unfortunately, we have only a sketchy look at what you are doing and how.

It's not uncommon for version changes to cause problems like this, although not always inevitable.

Let's start with the basics. Did you install 32bit Office 2016 or 64bit Office 2016?

--------------------
Go to the top of the page
 
JonSmith
post Aug 7 2018, 09:42 AM
Post#3



Posts: 3,694
Joined: 19-October 10



Are you applying it so a single page form or a continuous form?

JS
Go to the top of the page
 
STEPH9111
post Aug 9 2018, 08:17 AM
Post#4



Posts: 8
Joined: 2-August 18



Hi,

first, sorry for my bad english! I make an error it's WM_DROPFILES

Now, i used the DrapDrop y FeeDMe

Window 8.1 with Access 2010 32 bits: work only when turn off EnableLUA

Windows 10 (3 PC) with any version of Access doesn't work even when i turn off EnableLUA

All of mouse event message fire in debug.print comand line

If Msg <> WM_DROPFILES Then
'the hWnd parameter passed to this function by the OS is
'the handle to the form that was hooked. If the message
'is not for a file drop, we'll send the message to that
'form's standard message procedure
CallWindowProc ByVal prevWndProc, _
ByVal hWnd, _
ByVal Msg, _
ByVal wParam, _
ByVal lParam

Debug.Print Msg
Else
'we have a file drop, handle that
Debug.Print "DraDropMessage"
dragDropQueryFiles wParam
End If

Go to the top of the page
 
STEPH9111
post Aug 9 2018, 11:00 AM
Post#5



Posts: 8
Joined: 2-August 18



Hi every body,

my apologies for my bad English, I use an online translator. I write again my previous post badly written.

I noticed a problem with both DragDrop and FeedMe code examples. With Windows versions 8.1 and 10 and with any access version the message WM_DROPFILES is not intercepted by the CallWindowProc API.

I saw in this article that the problem would be due to the different level of security window policies "Drag and drop does not work on some Windows 10 systems" (https://github.com/noryb009/lick/issues/15).

Any idea
Go to the top of the page
 
STEPH9111
post Aug 10 2018, 04:17 AM
Post#6



Posts: 8
Joined: 2-August 18




https://blogs.msdn.microsoft.com/patricka/2...ntrol-and-uipi/


Public Function DragDropInitForm(hWndFrm As Long)
'inits the form for drag/drop
Dim lExStyle As Long

'get the current extended window style
lExStyle = GetWindowLong(hWndFrm, GWL_EXSTYLE)
'add the flag for accepting dragged files
lExStyle = lExStyle Or WS_EX_ACCEPTFILES
'set the new extended window style
SetWindowLong hWndFrm, GWL_EXSTYLE, lExStyle

ChangeWindowMessageFilter WM_DROPFILES, MSGFLT_ADD
ChangeWindowMessageFilter WM_COPYGLOBALDATA, MSGFLT_ADD
ChangeWindowMessageFilter WM_COPYDATA, MSGFLT_ADD


'register the form for drag/drop acceptance
DragAcceptFiles hWndFrm, True

End Function

But doesn't work....
Go to the top of the page
 
JonSmith
post Aug 10 2018, 04:29 AM
Post#7



Posts: 3,694
Joined: 19-October 10



QUOTE
Are you applying it so a single page form or a continuous form?
Go to the top of the page
 
STEPH9111
post Aug 10 2018, 05:09 AM
Post#8



Posts: 8
Joined: 2-August 18



A single page form like the DragDrop simple code.
Go to the top of the page
 
daolix
post Aug 10 2018, 06:33 AM
Post#9



Posts: 3
Joined: 29-September 16



If possible use a "Listview". When dragging files from the Explorer, the code is quite clear.
Go to the top of the page
 
JonSmith
post Aug 10 2018, 06:49 AM
Post#10



Posts: 3,694
Joined: 19-October 10



See attached an example of drag and drop in a form without using any of the methods that get blocked.
Tested in Windows 10 with Office 2010.
Attached File(s)
Attached File  AttachmentExample.zip ( 88.44K )Number of downloads: 5
 
Go to the top of the page
 
STEPH9111
post Aug 10 2018, 12:27 PM
Post#11



Posts: 8
Joined: 2-August 18



no, nothing work, sample, OLE object, activex control, i need to turn off EnableLUA
Go to the top of the page
 
STEPH9111
post Aug 10 2018, 12:27 PM
Post#12



Posts: 8
Joined: 2-August 18



no, nothing work, sample, OLE object, activex control, i need to turn off EnableLUA
Go to the top of the page
 
STEPH9111
post Aug 10 2018, 01:10 PM
Post#13



Posts: 8
Joined: 2-August 18



Found it!!!

The database must be used with a local account. If you open the database with an administrator account the windows security policy blocks the WM_DROPFILES message

Thank you for your participation
Go to the top of the page
 


Custom Search
RSSSearch   Top   Lo-Fi    21st August 2018 - 08:48 AM