Posts by txsal

    ActiveCell.FormulaR1C1 = " =SUMPRODUCT(SUBTOTAL(3,OFFSET(R[4]C[-2]:R[14995]C[-2],ROW(R[4]C[-2]:R[14995]C[-2])-ROW(R[4]C[-2]),0,1)),--(R[4]C[-2]:R[14995]C[-2]="(XXXXX)"))

    Here is my code. Ignore the X's but I keep receiving compile errors and not sure whats going on. Can anyone help?

    Thanks in advance

    Try this. One of the Find parameters specifies an exact or partial match.

    Thank you so much StephenR!!!


    Needed some help finding the exact text in a cell instead of finding a cell that contains even part of the word. Currently the code I'm using finds a cell that contains part of the text and uses it, but what I need is to find the Exact text in a column instead. Here is the code I use:

    Thanks in advance!

    'Delete x

    Set Obj = wsActiveSheet.Cells.Find("x")
    If Obj Is Nothing Then
    MsgBox "Target column is not found"
    AreaY = wsActiveSheet.Cells.Find("x").Row
    AreaX = wsActiveSheet.Cells.Find("x").Column
    End If


    Current code im using to delete columns. It seems the order of the data seems to affect what the code is choosing to delete.

    Hi all,

    I am quite new to the VBA world but needed some help with a code. I have a set of data with certain column titles that I would like the macro to find, delete, and arrange to form a generated report. I have got it to work fine, but recently added more columns to the set of data and now even with adjusting the code it doesnt act right. It seems to pick certain columns before others even though its set to find the proper text in the column header. Im getting stumped and frustrated. Any help would be appreciated!