|
-
Feb 6th, 2000, 02:26 PM
#1
Thread Starter
Fanatic Member
Hello!
Does anyone know how to create an event and automatically all of my 43 forms use it? I don't know if this is possible but I know it has to deal with Class Module.
On the same subject, is there a way where I can add some additional code (such as me.caption ="HI") to the RESIZE event and all forms in the project will process this code. The long way would be going through each form and add this code to the RESIZE event.
I appreciate your time and help!!
-
Feb 6th, 2000, 03:02 PM
#2
Hyperactive Member
Automatically not, but you can use something like:
in a code module:
Public Sub FormResize(frm As Form)
' do something
frm.Caption = "Resizing now"
End Sub
and in all form_resize events:
Call FormResize(Me)
-
Feb 7th, 2000, 06:51 AM
#3
Thread Starter
Fanatic Member
Thanks Crazy D!
Before posting my first message, I have been using the method that you posted. I was actually looking for a method to have all forms reference to an EVENT I created. Something like an add on. I don't really find it to be efficient to go through each form and code in each event.
But thanks for your help.
-
Feb 7th, 2000, 07:48 AM
#4
Hyperactive Member
I don't knnow that a class module is the answer...and unfortunately neither is this, because you have already created your 43 forms. But for future reference you can create a form template with the specific piece of code required and every time you add a form to your project you can add the form template that you created.
-
Feb 7th, 2000, 09:51 AM
#5
Thread Starter
Fanatic Member
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|