Copy Record

kevygee

Registered User.
Local time
Today, 16:34
Joined
Jun 7, 2005
Messages
32
I have this form that contains a good number of bound fields. The behaviour I would like to add to this form is, upon the press of a button, a new form would pop open (same form) as a copy of the current. This would make entering in multiple items with very few differing fields much easier.

I don't know a good way to do this. I mean I could list out each control, enter it in a new row in the database, and then open the new form pointing to that record, but that seems ridiculous. That would be like 500 lines of just gathering the data and inserting.

So I decided to cycle through all the controls, pick out the types I need, such as textboxes etc, and then get the value from that and put it in a new entry. So I would end up getting the name of the field in a variable, (named field), but I am unable to extract the value from the form from this string. Something like _ Me. & field & .Value _ really doesn't work. Anyway I can use a variable to get the value of a field?
 
So the link you posted redirects to the microsoft home page, so I don't know which sample file you are talking about. I tried searching for some keywords and didn't find anything relevant (I tried this before). Maybe you could post the name of the file or the title so that I can find the database, this might be helpful.

Thanks for your help.
 
Sorry about that,

What you should search for (google) is FrmSampl.exe

The full name is:
Access 2000 Sample: Database of Sample Forms

When you open it scroll down the list box until you see;

Filling a New Record with Values from a Previous Record.

I will try again:

Click Here

( I tested it this time and it works......for me)
 

Users who are viewing this thread

Back
Top Bottom