referencing a variable from a form in a module
In a General module (not in the userform module, not in a worksheet module, not
in the ThisWorkbook module), declare your 4 variables and make them public.
Option Explicit
Public myVar1 as string
etc
Then when your userform is ready (in the okbutton click event???):
myVar1 = me.textbox1.value
etc
Matthew Dyer wrote:
I have a form with 4 different text boxes in a form. When a command
button is pressed on the form, the values are saved into variables
that I want to use in a module sub saved in the same excel workbook,
but i seem to be striking out... How do i accomplish this?
--
Dave Peterson
|