Validate copied data in excel

Solved/Closed
chint99 Posts 2 Registration date Wednesday June 21, 2017 Status Member Last seen June 22, 2017 - Jun 21, 2017 at 10:57 AM
chint99 Posts 2 Registration date Wednesday June 21, 2017 Status Member Last seen June 22, 2017 - Jun 22, 2017 at 08:51 PM
Hi, I have a below scenario

one row is copied and pasted, this pasted row needs data validation such that total of each cell shouldn't exceed the respective cell of parent row.

e.g

R1 2 4 6 8
R2 (copy of R1) 2 4 6 8

changing values of both the rows above.

R1 changed - 1 2 3 4

R2 - changed 3 5 7 9 - over here can we trigger an excel macro on click of save ? such that value e.g "3" in R2 changed row shouldn't be allowed as total of (1+3) should be equal to original value i.e "2" (refer R1 first cell)

so edited values should be

R1 changed - 1 2 3 4
R2 changed - 1 2 3 4

1 response

TrowaD Posts 2921 Registration date Sunday September 12, 2010 Status Moderator Last seen December 27, 2022 555
Jun 22, 2017 at 11:03 AM
Hi Chint99,

It might just be a confusing example, but all I get from your query is that R2 needs to match R1.

Also, Excel doesn't keep track of all the different entry's made to a cell. So the Original value might be 2, when it is replaced by 1, then the 2 is lost. If you want to keep track of your entries use another row.

Best regards,
Trowa
0
chint99 Posts 2 Registration date Wednesday June 21, 2017 Status Member Last seen June 22, 2017
Updated on Jun 22, 2017 at 08:51 PM
Thanks TrowaD.
0