Solved Saving a revised version of a record and keeping the original (1 Viewer)

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 16:17
Joined
May 7, 2009
Messages
19,230
the function only Copies what is in the current record.
it does not Alter the content of any text in your table, except that it increment the revision number.
it is for You to make the Revision of those text, don't you think?

so if you're cursor is on ID #16 and you Duplicate it,
the only change in the new record is the Revision number.
it does not Prefix, Suffix text to "more text to be edited".
only You know what is the revision, and which text to add, delete, etc.
 

Manicduck

New member
Local time
Today, 09:17
Joined
May 22, 2020
Messages
29
Hi @arnelgp, thanks for you message. sorry, perhaps I haven’t explained myself (my wife always complains about that!)

In the Reporting form, if I use the record arrows to select record 1, with the following data in the 6 fields: accident 1, Dave, Date, aaa, bbb and a revision number of 1. I then manually change the text in the aaa and bbb fields to something else, I.e. xxx and yyy and press the “Add Revision” button, The main table will show a new entry which has been inserted at the end which shows: Accident 1, Dave, Date, xxx and yyy and a revision number of 2 - perfect, just as I had hoped it would - thank you!

unfortunately, the original record (record 1) was also updated with anything that had changed (except the auto number and the revision number) so in this example my data for Record 1 now reads: Accident 1, Dave, Date, xxx, yyy and Revision 1

This is then repeated if I then modify to revision 3, any text revised in revision 3 is copied across to the revision 2

I would like the original record to remain unchanged and only changes to the new record to be saved....

hopefully this makes more sense ?
 

Dag Solder

New member
Local time
Today, 09:17
Joined
May 8, 2020
Messages
19
Hey Manic,

Reading what you have posted, I believe (and forgive me if I am wrong) that you may have misunderstood the code posted by Arnelgp.

His code is designed to be used like this:

Submit a new report using the 'Add Record' button

To perform a revision, select the record you want to edit by using the record selector arrows, i.e. Record 1, revision 1 then press 'Add Revision' this will copy the record to a new line and up issue the revision number, you then add the revised information to this entry and save.

I have tested and it works perfectly for me, so as the OP I would like to thank all who contributed and give a special thanks to Arnelgp!!

If you are in agreement Manic, I would like to mark the post as solved!???
 

Manicduck

New member
Local time
Today, 09:17
Joined
May 22, 2020
Messages
29
oh no! Thanks Dag!

Sorry @arnelgp, as Dag has said, it works perfectly, if you use it as intended!

i need to change a few things on my forms to prevent others from making the same stupid mistake as me, but other than that, a big shout out to @arnelgp for all of his help.

Thanks also Manic for ’sorting’ it out, please go ahead and close the post - cheers (y)
 

Users who are viewing this thread

Top Bottom