Posts by rollis13

    Make these two changes I marked and then move the macro to the ThisWorkBook module. It will then work on every sheet.

    Have a try with this macro to be copied into the ThisWorkbook module. Every time you open the workbook it will check column B and D; if B is checked (1) and D is major than Today it will delete the row.

    Copy this macro in the sheets vbe module and give it a try:

    Presuming that your names are in column A from row 1 and have a single comma and a 2 charcter initial you could use this macro. To keep the initials aligned you will have to format the column with a monospaced font (ex. Courier New).

    It's tricky to use 'Find' with both month and year due to local formatting of dates so I had to change approach, try with this:

    If I correctly understood your request, could be:

    Note that I also added Event checking to avoid redundant triggering.

    The relevant part of my macro is all in the 'If/Then/End If' so all you have to do is add it to your macro, where depends on how your's is structured, maybe just before your 'End Sub'.

    Since I have no idea how your project is structured, I believe that a solution for your second request would be the same, create and add a new 'If/Then/End If' and in it change the references to columns and rows.

    Have a try with this macro to be placed in the sheets module.

    Points and trophies are arranged automatically by the Forum, all you can do is use "Likes" for the best posts.

    You asked for a macro to do the dirty work, I usually use this one to be found here: Link

    Never test on original files.

    You need to Delete (not only Clear) all rows and columns after the last valid cell.

    For rows: Select first empty row, hold Shift, tap End then Down Arrow, release Shift, apply Delete

    For columns: Select first empty column, hold Shift, tap End then Right Arrow, release Shift, apply Delete

    That's because with MID you extract a string, so when you compare A1=71 it is a string to a number. Should be atleast string to string (or number to number) so your formula in A3 will work with:

    =IF(A2="71","seventyone","ERROR")

    or

    =IF(VALUE(A2)=71,"seventyone","ERROR")

    Looks like it should be (but I'm unable to test it):

    Code
    1. Cells(7, iKVI).Value = "=" & Cells(7, iSum).Address(RowAbsolute:=False, ColumnAbsolute:=False) & "/SUM(" & Range(Cells(7, iSales), Cells(LastRow, iSales)).Address & ")"

    You have an extra double-quote after:

    Code
    1. ColumnAbsolute:=False)