How to extract data from sheet2 excel to notepad by using reference number in sheet 1 excel

Hi guys,
I need to extract data from sheet2 using sheet1 reference number and put the data in notepad… for example in sheet 2 i ll have

in sheet 1,

i need to extract data of 1, 3 and 4 from sheet 2 and place those data in notepad…
if anyone know please help me guys

Hi Sunitha, you can read both ranges into data tables and then use this solution