Hi
I need to transfer quote a lot of data from one worksheet to another. The data I need is all in column L, but I need to first check the following:
A in the target sheet needs to match B in the source - this is simply a date in dd/mm/yyyy format
AA in the target sheet needs to match I in the source - this is just text...a name
If those two things are correct, then the data in L should be the result in the target sheet
I did have some code for doing this ages ago and just found it tucked away in an email draft. It uses INT in it, which may have indicated that the date cell at the time had both date and time. That is not the case in either source or target, so this code has not worked for me. I guess it is a starting point, so here it is:
Any suggestion on how to have this work correctly to firstly compare the data in the source and target in the above columns and if they match, the copy the required data in column L to the target?
Regards
I need to transfer quote a lot of data from one worksheet to another. The data I need is all in column L, but I need to first check the following:
A in the target sheet needs to match B in the source - this is simply a date in dd/mm/yyyy format
AA in the target sheet needs to match I in the source - this is just text...a name
If those two things are correct, then the data in L should be the result in the target sheet
I did have some code for doing this ages ago and just found it tucked away in an email draft. It uses INT in it, which may have indicated that the date cell at the time had both date and time. That is not the case in either source or target, so this code has not worked for me. I guess it is a starting point, so here it is:
VBA Code:
=IF(ISERROR(MATCH(1,INDEX((INT('monthly_tho_bsp_2020-01-01.csv’!B$2:B$20000)=A2)*('monthly_tho_bsp_2020-01-01.csv’!I$2:I$20000=AA2),),0)),"",INDEX('monthly_tho_bsp_2020-01-01.csv’!L$2:L$20000,MATCH(1,INDEX((INT('monthly_tho_bsp_2020-01-01.csv’!B$2:B$20000)=A2)*('monthly_tho_bsp_2020-01-01.csv’!I$2:I$20000=AA2),),0)))
Any suggestion on how to have this work correctly to firstly compare the data in the source and target in the above columns and if they match, the copy the required data in column L to the target?
Regards