can i set excel to automatically copy and edit data?

Hello there,
I am trying to make this logbook
I have in column A flight date, column B aircraft number
Column C defines whether the pilot (whose name is the title of the sheet) was the pilot in command or the second in command
And column D defines the other crewmember (which can be pilot in command or the second in command)
Here is what I want to do:
When I enter information in JOHN sheet for example, and I set him in column C as Pilot in command, and I assign in column D his copilot STEVE A, is there a way to make excel copy these information to STEVE sheet automatically and set column C as Second in command, and set JOHN as crewmember ?
I hope someone would be able to help.
Thanks in advance

AttachmentSize
Book2.xlsx26.38 KB

Automatically copy and edit data

Hi,

Yes, there is a way to do what you need by using VBA. You can use the Worksheet_Change event to track the changes on the sheet and did some actions on the same sheet or another one. If you not familiar with VBA I can help you, but I need to know more details about your requirements. For example:

 - you want to copy all data in the row or only these in column C and D;

 - is it possible the names of the sheets to be the same as these into the CREWMEMBER's list. Hereby will be more easy to track the pilots and did the corresponding changes;

 - can I assume that the date and the aircraft number together are unique for each record or they are not;

 - ...

 

Best regards.

hi manny,thanks for your

hi manny,thanks for your reply.
I am a beginner with VBA, your help will be much appreciated.
In the sample book i posted earlier, let's take for example the first row in JOHN sheet. I entered the date of the flight, the aircraft number, PIC means he was the pilot in command therefore STEVE A is his copilot.
What i want to do is copy all the information in this row to the STEVE sheet, not only C and D, and edit column C in STEVE sheet to SIC because he was the second in command, and change the crewmember to JOHN E.
As you can see, the second row in JOHN sheet shows that he is also the PIC in his flight with TONY F, but let's say he was the co-pilot (SIC) not the (PIC), then I want to do the same as the first row, I want to copy all the information in this row to the TONY sheet, and edit column C in TONY sheet to PIC...
The aircraft number and date are unique for each record. It is possible to change the names of the sheets to be the same as the ones in CREWMEMBER's list.
Thanks again for your help.