Roman,
In brief...
In the form code
Sub lstSomething_Click
DoSomething lstSomething
End Sub
'In a general module
Sub DoSomething(lstName as MsForms.ListBox)
With lstName
msgbox .listcount
End With
End Sub
Robin Hammond
www.enhanceddatasystems.com
"Roman" wrote in message
ups.com...
I have two macros reading data from one of two userform listboxes.
These macros are actually the same but the used listbox. I'd like to
use just one code with variable listbox but I just don't know: how to
declare it?
Thanks for any experience.