MajP
You've got your good things, and you've got mine.
- Local time
- Today, 11:12
- Joined
- May 21, 2018
- Messages
- 9,379
This describes how to create a custom eventHow would I do that?
What You Need to Know About Access Events
There is often a lot of confusion about Access Events and often answering questions posed here is difficult because of inaccurate terminology. People often say "Event" when it is unclear if they mean the actual event that takes place, the event procedure, or the event property. This thread...
www.access-programmers.co.uk
Although you most definitely can create custom events for your form, you cannot create a new event that responds to a physical user form or control interaction (click, enter, exit, double click, etc.). Your event would more likely be data driven or a wrapper on multiple activities.
For example there is no "RightClick" event. However using the mouse down event and determining if it was button 2 I can raise a custom event called RightClick. That case is more like a wrapper of the mouse down event, although it would work like a RightClick event. The example in the link is a data driven event. If the data meets a condition an event is raised.
As written, the above statement is incorrect or at least not clear. I believe it means what I said previously, you cannot create a "hook" for a physical interaction. You can most certainly can create a "hook." For example seethey did not provide this particular hook, therefore, you cannot add it
MS Access: custom control built in another language
the code is old and there is a small change you need to make in several functions, e.g. fIsScrollBar, there is a line which is used to identify the scrollbar for a window If fGetClassName(hWnd_VSB) = "scrollBar" Then this needs to be changed to If fGetClassName(hWnd_VSB) = "NUIscrollBar"...
www.access-programmers.co.uk
This class turns any listbox and a group of command buttons into a sortable listbox where you can move items up and down. I simulate drag and drop using a series of events. I raise a custom "DragDrop" event that returns the index of the item dragged and the index of the item dropped. This however does not really react to the physical drag and drop, but instead is just a wrapper on a some other events and change in data. But once those activities that simulate "drag and drop" complete, I raise the event.
However, going back to this question
Would this simply be the same as the second form trapping when the first form closes?I've been looking for an event that gets fired when one closes the first form and then exits to the second form.
Last edited: