Posts by johno359


    I have recently had the Mail Manager add-in installed in Outlook. I have some Excel VBA code that automatically sends emails but I want to be able to either over-ride or temporarily disable the Mail Manager add-in / function. Does anyone know how to do this please?

    Thanks in advance for any help with this.

    Kind regards,


    Re: Ignore If Worksheet Does Not Exist

    Here is the code:


    I am struggling with coming up with a way of writing a line of code in VBA that ignores (or skips) a bit of code everytime a worksheet does not exist.

    Does anyone have any solutions to this?



    The following code removes all macros from my workbook:

    However, I have a macro called Wind() which I do not want removed. The code above references the VB component by a number, X, but this value may vary for Wind() . Therefore, is it possible to reference the VB component by name, and if that name is equal to Wind() , then the VB component will not be removed?

    Many thanks if anyone can help,



    I am using the Worksheet_Change function behind a worksheet that executes some code every time a change is made on the worksheet.


    Private Sub Worksheet_Change(ByVal Target As Range)
    End sub

    Is it possible to disable this function while running another macro? Therefore, when I enable Screen.Updating, the Worksheet_Change function will not be triggered.

    Many thanks to anyone who can help.



    The following code inserts a row below the selected row, and copies the formula of the row above into it.

    Dim Rw as Integer
    Rw = ActiveCell.Row
    Selection.Insert Shift:=xlDown
    Rows("" & Rw - 1 & ":" & Rw - 1 & "").Copy
    Rows("" & Rw & ":" & Rw & "").Paste

    However, I need to alter this to work for inserting more than one row at a time.
    ie. the user selects 'x' number of rows and 'x' rows are inserted below (in the same way 'Insert Row' works in Excel) and the row above the selection is copied down.

    I can't figure out how to do it. Is this possible?


    Re: Multiple Options Per Item In A Listbox

    Thanks Andy

    The number of items in the list varies so is it possible to actually use VBA to write a frame inside the list box?

    Would a frame be needed for each set of three options?




    I am using a listbox in a userform that has an option button per item, that can be selected/deselected.

    However, I need to create a listbox that displays three options per item. The user can then select from one of the three options per item on the list. Note that each item can only have one option selected.

    Is this possible using userforms?

    Many thanks,



    The following code is used to allow the user to double click on any cell in column B or D of that worksheet and peform a routine (in this case, a simple message box appears).

    My problem is that it slows down any work on that worksheet. If I select a cell or anything, the bottom left hand side of the screen says "Calculating cells" and counts from 0 to 100%.

    Any idea of how I can avoid this? It is very annoying!