Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / New Users / July 2006

Tip: Looking for answers? Try searching our database.

Copying and Pasting an Existing Form

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Jack G - 25 Jul 2006 14:58 GMT
Often, I'd like to copy an existing form and paste it back in to the
database with a new name so that I can make revisions without destroying the
form that already works (with the intent of removing the original form after
the new one is working properly).  Trouble is it never seems to work right.
I think I've found that the copy continues to use the underlying code from
the original form.  If this is the case, is there some way to break this
connection to the old code??   From something I read in another post, I
tried unchecking "Track name Autocorrect Info", but that didn't help.

Thanks for any guidance.

Jack
Jeff C - 25 Jul 2006 18:08 GMT
When you copy a form and paste it back with a new name the only thing that
has changed in the name.  The record source remains the same, the code behind
all the command buttons, combo boxes, events etc. all remain the same.  Your
newly named form is not using anything related to the old form, it is the
same as the old form until you change it.

The idea of making a copy to test and update is a good idea-- what is it
that isn't working?  Or what is it you are trying to do?

You can open up the properties of your newly named form and delete any
events that have code but is that really what you want to accomplish??

Jeff C
Live Well .. Be Happy In All You Do

> Often, I'd like to copy an existing form and paste it back in to the
> database with a new name so that I can make revisions without destroying the
[quoted text clipped - 8 lines]
>
> Jack
Jack G - 25 Jul 2006 19:18 GMT
Thanks Jeff,

After I copied the form and pasted and renamed it, I noticed that any code
changes I was making for the OnUpdate event didn't seem to have any affect
at all in my new form.  Then I totally removed the code and
it *still* didn't make any difference - it kept on reacting to the event the
same way the old form did!

I'll keep checking - maybe one of the forms that the code is opening has
some event tied to it that I've forgotten(but I don't think so).

Jack

> When you copy a form and paste it back with a new name the only thing that
> has changed in the name.  The record source remains the same, the code
[quoted text clipped - 29 lines]
>>
>> Jack
Jeff C - 25 Jul 2006 20:32 GMT
You need to remember that the code does not change when you renamed the form.
Since the code did not change, if it was referring to different controls as
if it was on Form A, but now it is on Form B, it is still referring form Form
A perspective.  You really need to check every control on your form to make
sure it is referring to the right thing from the right perspective.  Hope
I've helped a bit.
Signature

Jeff C
Live Well .. Be Happy In All You Do

> Thanks Jeff,
>
[quoted text clipped - 42 lines]
> >>
> >> Jack
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.