Sunday 15 September 2013

vba - Excel Macro find and copy corresponding cell apply formula on the value -



vba - Excel Macro find and copy corresponding cell apply formula on the value -

hi new vba script. have next problem.

sheet 1

date sum of cnt 01-04-2014 77 01-06-2014 3 01-07-2014 2 01-08-2014 1 01-09-2014 921

sheet 2

date count (count/sumofcout(sheet1) 01-06-2014 3 01-09-2014 4 01-09-2014 712 01-07-2014 1 01-08-2014 1 01-09-2014 205 .....

i have search every single date sheet 1 if there match in sheet 2 , corresponding count(sheet2)/sum0fcount of date(sheet1) should 3rd column in sheet 2. please help me. have big info multiple values of each day in month.

thanks in advance.

as tim has suggested in comment above...you can utilize vlookup/match (along sumif) results. formula (with different ranges) should job:

if( isna(match(a2,sheet1!$a$2:$a$13,0)),"",b2/sumif(sheet1!$a$2:$a$13,a2,sheet1!$b$2:$b$13))

you can alter ranges a2:a13, b2:b13 adjust according data

excel vba excel-vba

No comments:

Post a Comment