Say I open a form (MyForm) in design view, then I close it and
dbl-click it in the database window to open it. Shouldn't the Activate
event occur in all such situations? What might the case(s) be if the
Activate event does NOT fire? 9 2560
And what about opening that same form from code - should the
Activate event fire then too?
MLH <CR**@NorthStat e.net> wrote in
news:ap******** *************** *********@4ax.c om: And what about opening that same form from code - should the Activate event fire then too?
I just ran some tests. Activate is firing in all cases.
How are you testing?
How did you insert the code?
Is it possible that the Active event's code has somehow become
disconnected from the form? Try copying the contents of the Activate
event in code, then delete the entire event, and go back to the form
and recreate it.
--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc
Not sure what's going on with your code, but when I open or switch to
(tab to) an already open form with code in the OnActivate event of the
form, it fires just fine. Of course, it won't fire if you don't open
it in Normal mode (ie if you are opening it in design mode, none of
the events fire).
David W. Fenton wrote: MLH <CR**@NorthStat e.net> wrote in news:ap******** *************** *********@4ax.c om:
And what about opening that same form from code - should the Activate event fire then too?
I just ran some tests. Activate is firing in all cases.
How are you testing?
How did you insert the code?
Is it possible that the Active event's code has somehow become disconnected from the form? Try copying the contents of the Activate event in code, then delete the entire event, and go back to the form and recreate it.
Good key combination in these cases is (in VBA window):
Ctrl+A (select all), Ctrl+X (cut), Ctrl+V (paste)
That will re-connect all event procedures.
Well, that is it will in this century's versions of Access, dunno about
the erstwhile ones :-)
--
[OO=00=OO]
On Thu, 21 Jul 2005 19:30:18 +0100, Trevor Best <no****@besty.o rg.uk>
wrote: Is it possible that the Active event's code has somehow become disconnected from the form? Try copying the contents of the Activate event in code, then delete the entire event, and go back to the form and recreate it.
Good key combination in these cases is (in VBA window):
Ctrl+A (select all), Ctrl+X (cut), Ctrl+V (paste)
That will re-connect all event procedures.
Well, that is it will in this century's versions of Access, dunno about the erstwhile ones :-)
I have seen occasions where if the form's module is corrupted, simply
cutting and pasting alone does not remove the corruption.
I generally -
Ctrl+A (select all), Ctrl+X (cut)
On the form's property sheet set HasModule to No (completely remove
current module)
Save the form
Open the form's module (will now be a new module)
Delete the declarations from the top of the module (so they are not
duplicated after pasting)
Ctrl+V (paste)
Trevor Best <no****@besty.o rg.uk> wrote in
news:42******** *************** @news.zen.co.uk : David W. Fenton wrote: MLH <CR**@NorthStat e.net> wrote in news:ap******** *************** *********@4ax.c om:
And what about opening that same form from code - should the Activate event fire then too?
I just ran some tests. Activate is firing in all cases.
How are you testing?
How did you insert the code?
Is it possible that the Active event's code has somehow become disconnected from the form? Try copying the contents of the Activate event in code, then delete the entire event, and go back to the form and recreate it.
Good key combination in these cases is (in VBA window):
Ctrl+A (select all), Ctrl+X (cut), Ctrl+V (paste)
That will re-connect all event procedures.
Well, that is it will in this century's versions of Access, dunno about the erstwhile ones :-)
Um, do you mean in Access 2002 and Access 2003, since the year 2000
was the last one of the 20th century?
--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc
Wayne Gillespie <be*****@NOhotm ailSPAM.com.au> wrote in
news:d3******** *************** *********@4ax.c om: On Thu, 21 Jul 2005 19:30:18 +0100, Trevor Best <no****@besty.o rg.uk> wrote:
Is it possible that the Active event's code has somehow become disconnected from the form? Try copying the contents of the Activate event in code, then delete the entire event, and go back to the form and recreate it.
Good key combination in these cases is (in VBA window):
Ctrl+A (select all), Ctrl+X (cut), Ctrl+V (paste)
That will re-connect all event procedures.
Well, that is it will in this century's versions of Access, dunno about the erstwhile ones :-)
I have seen occasions where if the form's module is corrupted, simply cutting and pasting alone does not remove the corruption.
Er, who was talking about code corruption? I was talking about the
loss of the connection between the object and it's events in code.
Sometimes you can see [EVENT PROCEDURE] in an object's properties
sheet, but the event doesn't fire, and the only solution I've found
is recreating it from scratch, via the property sheet UI.
--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc
"David W. Fenton" wrote Um, do you mean in Access 2002 and Access 2003, since the year 2000 was the last one of the 20th century?
Picky, picky, picky!
Despite the "actual definition", when the leftmost digit rolls, most of the
world views it as "the new millennium" -- the cruise line must have, as the
cruise I took as a Millennium cruise encompassed January 1, 2000, not
January 1, 2001. I figured if the ship's computer suffered Y2K freak-out,
there'd likely be enough food until we drifted to one or the other shores of
the Caribbean.
David W. Fenton wrote: Well, that is it will in this century's versions of Access, dunno about the erstwhile ones :-)
Um, do you mean in Access 2002 and Access 2003, since the year 2000 was the last one of the 20th century?
Would the semantics matter anyway as A2K came out in '99? Let's just say
the versions supported by MS this century.
I'm talking A2K onwards where the VBA model changed to use the separate
code window. I've never tried that method in earlier versions.
--
[OO=00=OO] This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Bradley |
last post by:
Has anyone else noticed this problem? I converted the back-end to A2000
and the performance problem was fixed. We supply a 97 and 2000 version
of our software so we kept the backend in A97 to make upgrading simple
for users. We've done it like that for years but a new client has been
having severe performance issues... solved by converting the backend to
2000.
--
regards,
Bradley
|
by: Randy Harris |
last post by:
I'm working with Access 2K and seem to be getting some behavior that
contradicts the documentation. First, the help says:
"Note The Activate event doesn't occur when a form receives focus back
from a dialog box, popup, or another form."
This doesn't seem to be the case. The form activate consistently fires when
focus moves from another form.
Secondly, the activate event for a report. I am seeing it fire consistently
|
by: MLH |
last post by:
Did A97, perchance, do away with the need for
an AutoExec macro to initiate an autoexec sequence
for databases? Or, must we still suffer with that hideous
macro?
|
by: MLH |
last post by:
open form in design view
then allow it to be opened into form view
from code.
then set its visible propery to false
then open into design view from code
then set its visible propery to false
then open into design view from code
then set its visible propery to false
then open into design view from code
|
by: active |
last post by:
I remember when I checked NewGroups for comments about the VB6 Activate
event and found that many thought it was not a reliable way to keep track of
which form has focus. There was enough bad press that I avoided it.
I now have a project with MDI child forms and non-MDI child forms coming and
going as the user selects different options. I need to know which form is
the active one and thought that I could use the Activate and Deactivate...
| |
by: juststarter |
last post by:
hi there
here is my problem :
there is a main form (frmMain) which calls a searchForm (frmSearch). Then i
select an item (from the returned ones) and open a third form (frmData).
Taking from there i can either :
A. open a fourth form (frmComment) which is just a textbox and a button (and
should return the text entered in the textbox into frmData)
B. open a word document ,and paste its contents into a richtextbox in frmData
The problem...
|
by: David W. Fenton |
last post by:
I ran into a weird problem with a subreport with an OnFormat event
of the subreport detail. When I view the field list in report design
view, all the aliased fields in the recordsource are available. But
when the report runs, the aliased fields are inaccessible. Of
course, this is causing a problem with the report running, and I
can't figure it out.
I've decompiled, I've compacted, I've recreated the recordsource.
I've tried moving the...
|
by: MMcCarthy |
last post by:
VBA is described as an Event driven programming language. What is meant by this?
Access, like most Windows programs, is an event driven application. This means that nothing happens unless it is in response to some event that has been detected by the application.
The steps are fairly straightforward:
An event happens
The event is detected by the application
The application responds to the eventThe Windows OS will automatically detect...
|
by: Salad |
last post by:
Using A97, SP2, most current jet35.
I have a search form. The op enters an id to search/find. If found, a
data entry form is presented for that id. This form has 7 or 8 combos,
a bunch of textboxes, and some command buttons.
At the client site yesterday the user got a "too many databases open"
after entering a bunch of IDs into the search form. Later that day,
after entering a bunch more IDs, she got an out of memory error and the...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |