hi guys, i have the below code for sumif function
however, is there a cleaner way to loop this through to the last filled cell in column A instead of listing many lines like below? Thanks.
Please Login or Register to view this content.
hi guys, i have the below code for sumif function
however, is there a cleaner way to loop this through to the last filled cell in column A instead of listing many lines like below? Thanks.
Please Login or Register to view this content.
no need for a loop.
Please Login or Register to view this content.
Hi Andy, that works perfectly but then i just notice that my sumif function only return the first number of the criteria rather than returning the sum of the total range in sheets("FRUIT").range("L:L"). can you see if my sumif is wrong?
basically my data is in sheet Fruit between column A to AD and the criteria is in sheet Data2, column A, the column im trying to sum up is sheet Fruit column L, am i missing something here? Thanks.
You need to post example workbook. Include the actual formula you are trying to do via code so we can see expected formula and result.
Sure, i have amended my code and try to incorporate into the one you did but didnt work, my code below, tx
Please Login or Register to view this content.
Can you not post a example workbook?
sure, i have amended my code below
Please Login or Register to view this content.
how does that help with me understand what values are in myrg1 or myrg2 or what the result should be and what it actually is now?
Apols, pls see updated code and attached file, thx
Please Login or Register to view this content.
with attachment
Here is the modified code to replicate your example file.
Please Login or Register to view this content.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks