Linking a worksheet commandbutton to a userform commandbutton

  • I want to change the caption of a worksheet activex control from a userform.


    In VB, how do I access the worksheet component from the userform (i.e. when I click the cmdClose button on the userform it will change cmdSummary button on Sheet 1, for example).


    Thank you.

  • Re: Linking a worksheet commandbutton to a userform commandbutton


    Put this in your cmdClose click event

    Code
    Sheet1.cmdSummary.Caption = "new caption"

    Few things in life are better than helping someone.

Participate now!

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