Posts by Luke M

    Re: delete rows on date


    Put this in the ThisWorkbook module. Code will run when you open the workbook.

    Re: VBA auto populate a cell through lookup


    These two lines:

    Code
    Option Explicit
    Dim newPerson as Boolean


    Need to go at the top of the module, before any other macro. For the VBE, they need to be compiled before it starts to read any of the macros.

    Re: VBA auto populate a cell through lookup


    Right-click on Entry sheet tab, view code, paste this in

    Re: Looking to record an input prompt macro


    Here's an example to get you started. Right-click on sheet tab, view code, paste this in.

    Re: Charts & Secondary Axis


    You should add a dummy series to each axis. So, four total series:
    Average
    Dummy Avg (plug in a random value for now, say 40?)
    Dummy Total (plug in a random value for now, say 40?)
    Total


    Move TotalDummy and Total to Secondary Axis. Then, change the values in the Dummy series to 0. If you have a legend, you can do two single-clicks to select the label, and then hit delete to remove it from the legend.

    Re: Search 2nd Column vs 1st Column from a ComboBox


    Is there any chance we can swap col B and col A in your table? If col A is the "key value" that you do lookups by, it would make sense to have it be the first column. I realize this isn't a direct answer to your question, but perhaps it points to a different issue.

    Re: Lookup cell value in column and post entire row


    This should help you get started.

    Re: checking and clearing checkboxes with a command button


    Checkboxes use Checked/Unchecked, not a strict True/False. Try it this way:

    Re: select a range in column A based on the active cell in col A & the last row in co


    I think this should help you out.

    Re: Checkbox to List. B3, when it is checked, D3=TRUE. If B3=FALSE, want to skip FALS


    Confirm this formula as an array using Ctrl+Shift+Enter, not just Enter. Copy down as far as would ever be needed.
    =IFERROR(INDEX(C:C,SMALL(IF(D$2:D$100,ROW(D$2:D$100)),ROW(A1))),"")


    Our IF function gives us an array of all the rows where we had a TRUE value. We then use the SMALL function to pick out these values in order, starting at top of column (aka, smallest row). The ROW(A1) serves as a counter, allowing the SMALL function to get the 1st smallest, then 2nd, 3rd, etc. The INDEX uses that ROW number and returns the value from col C. The IFERROR is our trap for when we have more formula cells than outputs, as the SMALL function will error out.

    Re: VBA Search for Column and add to macro


    Does this help?

    Re: VBA Return Name of ActiveX Button Just Clicked


    I was able to get a clue from here:
    http://www.excelguru.ca/forums…&p=125&viewfull=1#post125


    Since you are using command buttons, slight modifications are needed.
    Insert a new Class module, call the module cButton
    Within the Class module, paste this code:


    Then, in a regular module, paste this code:


    Run the Activation macro. Now whenever you click on a ActiveX command button, the class macro will be called. It's up to you how you want to use the information at this point.

    Re: Excel data in sheet by row & additional data in multiple columns in another sheet


    Let's assume that the header names "Q1", "Q2", etc. start in cell G1 and go to the right.
    This array formula would return the needed information.
    =INDEX(Sheet2!$C:$C,MATCH($A2&G$1,Sheet2!$A$1:$A$40&Sheet2!$B$1:$B$40,0))


    Confirm formula using Ctrl+Shift+Enter, not just Enter. Then you can top to the right and down as needed.