hi,
do you know if there is the chance to call a Listbox in a Userform trough a variable?
I was thinking about something like this:
x = "Listbox1"
With UserForm1.x
...
End With
Thanks!
hi,
do you know if there is the chance to call a Listbox in a Userform trough a variable?
I was thinking about something like this:
x = "Listbox1"
With UserForm1.x
...
End With
Thanks!
I'm not 100% positive because lists boxes behave differently in VBA then they do in VB.Net but I believe you have to loop through all items in your listbox checking the IF the selected propert = true then x = selected item index number.
Thanks,
Solus
Please remember the following:
1. Use [code] code tags [/code]. It keeps posts clean, easy-to-read, and maintains VBA formatting.Highlight the code in your post and press the # button in the toolbar.2. Show appreciation to those who have helped you by clicking below their posts.
3. If you are happy with a solution to your problem, mark the thread as [SOLVED] using the tools at the top.
"Slow is smooth, smooth is fast."
Hi,
Maybe I wasn't clear in asking the question. I know how to handle the items in the listbox. The problem is that I want to "call" the Listbox through a variable.
I hope like this is more clear:
Please Login or Register to view this content.
Thank you
Please Login or Register to view this content.
Works fine.
Thanks
simply
Please Login or Register to view this content.
Josie
if at first you don't succeed try doing it the way your wife told you to
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks