Posts by mahesht

    thanks Carim for your response

    Could you clarify your two remarks :

    1. Which VBA skills would you like to develop ? ( they are several methods to achieve the same final output )

    i knowledge in vba is very poor, i am not sure on the multiple different ways of achieving this. Wondering, If this can be done through filter option

    2. What do you mean by " the Structure in Result will not come in one go " ?

    Whenever i do pivot i will have to drag the field in either row or columns to get the desired result.

    If i have to get the output same sheet "Result", i feel this can be achieved only by vba code. My only issue is i have poor knowledge in understanding vba code.

    HI! all

    I have data in multiple columns, one of the column has date details. I want something similar to pivot table for the date column based on segregate by "Cus Sgm"

    While i am able to do this by Pivot, but i would want to do further segregate by:

    - Current Month (as individual date wise)

    - Next Month ( as consolidated by months)

    - Next Year (as consolidated by Year wise

    is this possible to derive

    i have attached excel sheet with sample in sheet "Result"


    HI! all

    In my excel i have below column heads



    What I am trying to do is count records based on Field_AC using "COUNTIFS" function


    I also want to add one more criteria based on Source (Loc4) using the CountIfs function


    attach image shows the result of the 1st criteria is 1 each for Field_AC and Loc4.

    How can i use both these functions together.



    I have an excel sheet which copies data from tab "X_Reports" to tab "Summary". When i am in Summary sheet and i trigger the below code, the result in Count column is giving me the correct values. However, when i am in different sheet, lets say "Daily Recon" it gives a result in Summary sheet in column Count is Zero

    Kindly help me to modify the code to give a correct value even if i trigger from any other sheet.

    below is the code

    Thanks Carim, and apologies for the confusion.


    Sadly you are not answering the question .... but adding several new issues ...:(

    yes, i have put the code provided in post# 21 and now it exactly tells me the count of each unique rows from the X_Report tab.

    Thank you very much


    It seems to me this question is not exactly the same as the one with which you started this very thread ...

    Am I right or wrong ...???

    Yes, Carim, the question pointed to my 1st thread. but it is indirectly related to this thread.

    the code given in post# 19 is working and keeping the cell empty. But i wanted to move the count to column F. I tried to change the code from If nc1(x) <> "" Then wsMain.Range("E" to If nc1(x) <> "" Then wsMain.Range("F"

    but it seems to copy extra count

    the number of rows in X_Report is not always same. can this be change ($D$12:$D$68) to something D12:D

    it copies the data from column D12 to column E and counts the number of rows from tab X_Report

    below is the code. In my office file it gives me 1888, that is because the number of empty rows in quite high

    in the same file it may be less.

    wsMain.Range("E" & Rows.count).End(xlUp).Offset(1).Value = Evaluate("=COUNTIF(X_Report!$D$12:$D$68,A" & x + 1 & ")")

    I am extremely sorry Sir since that original excel file is in my company folder and i cannot share for security reasons.

    I am sharing the dummy excel which i had tried to replicate the information as close as possible.

    The dummy file does not have this issue, probably the dummy data that i have created is not exactly replicate. But i have shown the result in the Summary tab where the empty rows are counted and shown as 1888

    HI Carim

    to answer to post# 9


    If I understand your remark ... there is a difference in Excel between Empty and Blank ...;)

    Are you copying the data in Column A from another source ...???

    yes, i am copying the data from another sheet from the same excel.

    i have tried as you suggested in post# 11 and am getting the below


    HI Carim, Actually my problem is solved, but i am not sure how to present my issue.

    I can see there is no data in column A. but it still counts the data from adjacent column B.

    If i keep my cursor on that particular field (where there is no data) and hit the delete key, it works post that

    hope you understood my problem