Solved

Window events

Posted on 2002-03-31
8
163 Views
Last Modified: 2010-05-02
I have a window which is created runtime from within a form. That window is not an MDIChild but a child window to the form. The only thing I know about the window is its handle( i know that is all would need ). Having said that, how would I capture mouse events or any event in that window.

A code snippet and a little explanation will be of great help.

Thanks
0
Comment
Question by:maggari
  • 5
  • 2
8 Comments
 
LVL 1

Expert Comment

by:COAtheGREAT
ID: 6909098
Is this window vb Form or some other program ?
0
 

Author Comment

by:maggari
ID: 6909459
Its created runtime from a VB form. Its actually a VB window. I don't know if its a form or not. What if its a form?
0
 
LVL 1

Expert Comment

by:COAtheGREAT
ID: 6909864
You can create custom Events like any other class and fire them when you need. On the form that creates your child form dimension the chield form with events.

Dim WithEvents MyForm as vbForm 'this enables you to catch her events

Private Sub MyForm_SomethingHapened()

end sub

0
VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

 

Author Comment

by:maggari
ID: 6912862
Its not a form. Its a window created by one of the Win32 API functions. So, if anyone can tell me how to catch the events from such a window, that will help.
0
 

Author Comment

by:maggari
ID: 6913064
Its not a form. Its a window created by one of the Win32 API functions. So, if anyone can tell me how to catch the events from such a window, that will help.
0
 

Author Comment

by:maggari
ID: 6913305
Its not a form. Its a window created by one of the Win32 API functions. So, if anyone can tell me how to catch the events from such a window, that will help.
0
 

Author Comment

by:maggari
ID: 6913415
Its not a form. Its a window created by one of the Win32 API functions. So, if anyone can tell me how to catch the events from such a window, that will help.
0
 
LVL 49

Accepted Solution

by:
DanRollins earned 50 total points
ID: 7638002
maggari, an EE Moderator will delete this for you.
Moderator, my recommended disposition is:

    DELETE this question.

DanRollins -- EE database cleanup volunteer
0

Featured Post

Are your AD admin tools letting you down?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

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

Suggested Solutions

Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

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