Copying Module to new form

  • Thread starter Thread starter Mark A. Sam
  • Start date Start date
M

Mark A. Sam

Hello,

I am creating a new form to replace an existing form which I believe to be
corrupt. I copied the module from the old form into the new form and noticed
that the event properties of the form were automaticlly marked as
[EventProcedure], in this case the Current, Open, And Activate properties.
The controls however didn't have their event properties marked for some
reason. I wonder if I can get Access to do this so that I don't have to
click on each control on the original form and select the properties with
event procedure. This will be time comsuming. can Access do this for me?

Thank you and God Bless,

Mark A. Sam
 
Hi Mark,

Usually, if the controlnames are identical, the [EventProcedure] will fill
in when you compile. It may require the control index to be the same though.
I am not positive.

If your form is suspected to be corrupt, you can do several other things to
fix it first before rebuilding. First try (on a copy) to decompile then
recompile. If that doesn't work try saving and rebuilding the form using
text methods as in:

http://www.datastrat.com/Code/DocDatabase.txt
 
Arvin,

I did decompile, but that didn't seem to work. My problem is the entry into
textboxes lags, and I can't duplicate the problem. I am working remotely
through termial service and they are running the DB on their local machines.
When I began this 3 weeks ago, I copied the existing app from a webpage,
then returned it the same way, then after a couple days they set me up to
work remotely, and I think the form got corrupted through the transfers.
There were other corrupted object, a form and two modules that I eliminated
with a new DB. But I can't get it to lag for me.

The procedure you posted seems to save all of the objects to text files. So
that I can recreated them all into a new DB by reversing the process,
"Application.LoadFromText". Is that correct?

God Bless,

Mark


Arvin Meyer MVP said:
Hi Mark,

Usually, if the controlnames are identical, the [EventProcedure] will fill
in when you compile. It may require the control index to be the same
though. I am not positive.

If your form is suspected to be corrupt, you can do several other things
to fix it first before rebuilding. First try (on a copy) to decompile then
recompile. If that doesn't work try saving and rebuilding the form using
text methods as in:

http://www.datastrat.com/Code/DocDatabase.txt
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com


Mark A. Sam said:
Hello,

I am creating a new form to replace an existing form which I believe to
be corrupt. I copied the module from the old form into the new form and
noticed that the event properties of the form were automaticlly marked as
[EventProcedure], in this case the Current, Open, And Activate
properties. The controls however didn't have their event properties
marked for some reason. I wonder if I can get Access to do this so that
I don't have to click on each control on the original form and select the
properties with event procedure. This will be time comsuming. can
Access do this for me?

Thank you and God Bless,

Mark A. Sam
 
Arvin,

Disregard my last post about how the procedure works. I understand it.

Thank you for your help and God Bless,

Mark

Arvin Meyer MVP said:
Hi Mark,

Usually, if the controlnames are identical, the [EventProcedure] will fill
in when you compile. It may require the control index to be the same
though. I am not positive.

If your form is suspected to be corrupt, you can do several other things
to fix it first before rebuilding. First try (on a copy) to decompile then
recompile. If that doesn't work try saving and rebuilding the form using
text methods as in:

http://www.datastrat.com/Code/DocDatabase.txt
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com


Mark A. Sam said:
Hello,

I am creating a new form to replace an existing form which I believe to
be corrupt. I copied the module from the old form into the new form and
noticed that the event properties of the form were automaticlly marked as
[EventProcedure], in this case the Current, Open, And Activate
properties. The controls however didn't have their event properties
marked for some reason. I wonder if I can get Access to do this so that
I don't have to click on each control on the original form and select the
properties with event procedure. This will be time comsuming. can
Access do this for me?

Thank you and God Bless,

Mark A. Sam
 
Back
Top