flat assembler
Message board for the users of flat assembler.
Index
> Windows > DragQueryFileA |
Author |
|
Yardman 10 Aug 2008, 09:16
[ Post removed by author. ]
Last edited by Yardman on 04 Apr 2012, 03:24; edited 1 time in total |
|||
10 Aug 2008, 09:16 |
|
iic2 10 Aug 2008, 17:34
Thanks Yardman for noticing that. I forgot it in the example. That's why it crash. In my code it is included. Anyway, I took care of that (in the code above) and now you will see that the code returns a value for the call to [DragQueryFileA] but you get nothing in the string.
When running the example, than dragging a file to the window and dropping it, it's suppose to show the full path name in the MessageBox. I'm wondering if Windows use a struture to do this like RichEdit use structures for it funtions. If so what are the names and where are they at ??? Between mouse down and while dragging, Windows get the Full-Path-Name. That target-text got to be stored somewhere in-order for Windows to Drop-it or show it in the MessageBox. What am im missing ? |
|||
10 Aug 2008, 17:34 |
|
ManOfSteel 10 Aug 2008, 18:26
Code: PUSH 256 PUSH String1 PUSH 0xffffffff ; 1 0 -1 PUSH [wParam] CALL [DragQueryFileA] Passing 0xffffffff as iFile parameter should return the file count. Try 0. |
|||
10 Aug 2008, 18:26 |
|
iic2 10 Aug 2008, 19:02
I did'nt know what 0xffffffff was really for until now. I guest it mean zero with added meaning, depending on what function it is used with. It just looked so FASM in the drag-thread I read here and I thought I'll try it. Anyway, It's working ...
Thanks ManOfSteel What a relief... I thought I had to study COM |
|||
10 Aug 2008, 19:02 |
|
iic2 10 Aug 2008, 21:27
Now that I know DragQueryFile works, it is not working in my subclassed proc. But I do get empty messageBox when dropped on my window. My coding is all jack-up but I don't want to fix it, I rather find another way and come back to this latter if I have too.
I'm ready to code my own Drag-Drop PROC but there is a few things I need to know before beginning so i can keep it simple as possible. I always wonder about this long before this problem anyway. I mainly need to know at what point does Windows WM_DROPFILES message or DragQueryFile extract the FullPathName from the dragged icon. Is it at the time that the time Left Button is Down, is it during the time of draging it from one pt to the next, or is it's only extracted during release time of the button. I'm hoping it's when to first press the mouse button on the icon, if so, what do I call to extract the information that I am after. I already know I need a hook or something better to get to that point. Is a Driver or System Service a better way to go. If so I'll kill 2 birds with one stone. I always wanted to write a driver ... |
|||
10 Aug 2008, 21:27 |
|
iic2 10 Aug 2008, 22:34
OK, If I try to fix my code, I know for sure that I have to pass the parameter, handles or something to the subclassed window and control. Not using resources I had to even subclass the main window to Load a Icon to show in the Taskbar for the program with LoadImage because the program don't use any resource section. So this may be may be what is blocking the messages.
Anyway, WM_MOUSEMOVE and others work but not WM_DROPFILES, and only WM_DROPFILES, will not accept messages if writen under the Subclassed proc, while most others will. How do i pass (I guest) subclassed to subclassed proc SubClassWin hwnd,wmsg wparam,lparam cmp [wmsg], WM_DROPFILES .... .... messages, that is like under the winmain section to proc SubClassProc hWND,uMSG, wPARAM, lPARAM that is under the subclassed proc that will not receive WM_DROPFILES messages, directly. I hope I explained things properly. I done ran out of ideas |
|||
10 Aug 2008, 22:34 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.