Running a module issue

  • Hi

    I have a module that i want to run by the click of a button.

    "run.application" is what i need but how do i pair the module with this.

    The module name is "Send_rows"

    Any help would be appreciated

  • This Might Help

    Assuming that you have added a button to a worksheet using Excel Control Toolbox:

    Make sure you have selected Design Mode on the Control Toolbox and then double-click on the button.

    You should then be moved to the VBE (Visual Basic Editor) where a private sub for the button when it is clicked has been started for you.

    Private Sub btnPCSelRptPrd_Click()

    End Sub

    You then add your Application.Run statement

    Private Sub btnPCSelRptPrd_Click()
    Application.Run "SelectReportPeriod"
    End Sub

    If you change the name of the button after creating the private sub, you will have to go into the code (from Excel when in Design Mode, right-click and select View Code) and edit the control's name the private sub.

    Hope this helps.

    Barbara - aka The Cat Lady :cat:

    Please do not U2U (private message) me directly for questions that should be posted to the forum; any such U2Us, unless requested by me, will be deleted.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!