Solved

Points for Ginsonic

Posted on 2002-05-28
13
183 Views
Last Modified: 2010-04-04
Ginsonic,
here ya go. The first half.

Thanks for your help.

Q2
0
Comment
Question by:quantum2
  • 9
  • 4
13 Comments
 
LVL 9

Expert Comment

by:ginsonic
ID: 7041172
I work now to your request. When finish I will put here a comment.
0
 
LVL 9

Expert Comment

by:ginsonic
ID: 7041390
Hmm, problems .

You wish to hook the mouse for your application or for all running programs ?

Because I can now send messages just to my application. If focus another application I lose the connection between dll and my form:(

Still working .
0
 
LVL 1

Author Comment

by:quantum2
ID: 7042172
This hook needs to work across all applications, but send the message to my application only. In the previous hook, it worked from the DLL with a simple show message across all apps. That is assuming that I do the processing in the DLL after the event fires. However, that calls for a great deal of duplicate code. This is why I wanted my application to listen for the DLL message saying that it trapped a right and left simultaneous click. So, the DLL could broadcast the message but my app would be the only thing that did anything with the message.

Thanks for the help.

Q2
0
Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

 
LVL 9

Expert Comment

by:ginsonic
ID: 7043741
I make it to work now , but with a problem !?!
Somehow look like window lose her handler when is unfocused . So I need to find the new one .
The only way I can fix the problem ( for moment ) is to find the application handler using the title .

In conclusion , to work at this stage with my hook , you need to use a unique title for your mainform .

It's OK ? Still dig on it .

Nick
0
 
LVL 9

Expert Comment

by:ginsonic
ID: 7044236
Have an answer ?
0
 
LVL 9

Expert Comment

by:ginsonic
ID: 7044244
Sorry if I push you, but I'm a little pressed by time. I must add 3.000 points by month to my account to keep me in KPro and I need the last 50 points. Tomorrow is the last day to acumulate points.
After that the counter is reseted .

So please give me an answer soon.
0
 
LVL 1

Author Comment

by:quantum2
ID: 7045109
Sure,
the form name is configure, the application window name is : instant

I am not real sure what focus should have to do with it as the DLL gets called an monitors and then passes a message back to the calling EXE. Then the processing goes from within my application.

Either way, that is the name of the exe.

Thanks

q2
0
 
LVL 9

Expert Comment

by:ginsonic
ID: 7045135
In next 15 minutes the project will be on my site . I will notify when done .
0
 
LVL 9

Accepted Solution

by:
ginsonic earned 250 total points
ID: 7045166
OK the link is :

http://www.ginsonic.ro/NewHook.zip

Don't test under IDE enviroment . Compile the project and then run it as usual program .

I put in dll the case when you double click on left mouse button . The label count your clicks (in and outside the form).

As comment I add the case when wish to capture the simultaneous left&right clicks .

To work your hook the windows must have the name 'instant'.Or can change in dll your own one .

Still work to a version to skip the title name test .
0
 
LVL 9

Expert Comment

by:ginsonic
ID: 7045169
Wait your questions.
0
 
LVL 9

Expert Comment

by:ginsonic
ID: 7046766
??
0
 
LVL 1

Author Comment

by:quantum2
ID: 7046946
I didnt want to keep you waiting so here is the first 250 points. I am going to go look at the code now. Thanks for everything.

Q2
0
 
LVL 1

Author Comment

by:quantum2
ID: 7046962
Ginsonic,
Hey this works great, and I can use it this way if I switch it to the right mouse button. What I was REALLY looking for was if both the right and left mouse buttons were pressed once at the same time. that is ideal. This does indeed work VERY well, and I could use as is.

If you are interested in updating it so that it traps both the left and right mouse buttons being clicked that is great, if not... no problem. I am going to create another question to pass along your other points.

Thanks again

Q2
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

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

Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…

813 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now