• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Need Help: Compare values of two sheets and pull the value

Praneeth30

New Member
Hey,
I am new to the macros and was trying to come up with a compare macro and looking for help...
I have a workbook with two sheets and i have to compare COLA of Sheet1 to COLA of sheet 2 and capture the corresponding value in COLB of Sheet2 and display it in COLB of Sheet1.

Looking for some assistance here.
 
Hi:

You will have to upload a sample workbook to get proper solution to your problem. If the data set is small you can do with with the help of lookup functions.

Thanks
 
Hi:

You will have to upload a sample workbook to get proper solution to your problem. If the data set is small you can do with with the help of lookup functions.

Thanks
Hi.. I have uploaded a sample file, the fields on colA of Sheet2 gets repeated so i have to capture all related COLB values and not a single time so i cannot use lookup.
 

Attachments

  • Sample Workbook.xlsm
    98.3 KB · Views: 0
Hi:

You are asking to compare column A of sheet 1 to column A of sheet 2 , but column A of sheet is blank.Also clarify which column in sheet 2 should be captured in column B of sheet 1.

Thanks
 
Hi:

You are asking to compare column A of sheet 1 to column A of sheet 2 , but column A of sheet is blank.Also clarify which column in sheet 2 should be captured in column B of sheet 1.

Thanks
I am attaching the updated sheet here.
I want to take the fields of COLA of Sheet2 and do a lookup on COLA of Sheet1 and if i find it twice in COLA of sheet1 i want to capture the corresponding COLB value of Sheet1 and place it in COLB of sheet2. If i find the field twice in COLA of shee1 i have to display both the corresponding values of COLB of sheet1 to COLB and COLC of sheet2. I have to repeat it to each and every field.
Thanks
 
Last edited:
Hey Nebu, I am not able to attach the file again.. So please refer to the old file that i have attached and in that 'FV Fields' refer to COLA of Sheet2 and 'I/P Value1' refer to COLB of sheet2.
 
Hey Nebu, I am not able to attach the file again.. So please refer to the old file that i have attached and in that 'FV Fields' refer to COLA of Sheet2 and 'I/P Value1' refer to COLB of sheet2.

If having trouble in file attachment then send it to me. I will upload the same here.

upload_2015-8-27_14-8-42.png
 
Hi:

I am still not clear on which values you want to fetch. This is what I understood.

You want to compare field "FV Fields" with Column A of Sheet 1
f i find the field twice in COLA of shee1 i have to display both the corresponding values of COLB of sheet1 to COLB and COLC of sheet2

This part of your post is rather confusing.

Thanks
 
Back
Top