ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   be able to access worksheet while form is running (https://www.excelbanter.com/excel-programming/384541-able-access-worksheet-while-form-running.html)

Monte0682

be able to access worksheet while form is running
 
How is this possible to do? I want to run a form and be able to select
what worksheet I want...


Tom Ogilvy

be able to access worksheet while form is running
 
Private Sub Userform_Initialize()
Dim sh as Worksheet
for each sh in worksheets
combobox1.AddItem sh.Name
Next
End Sub

Private Sub Combobox1_Click()
if combobox1.ListIndex < -1 then _
worksheets(combobox1.Value).Activate
End sub

--
Regards,
Tom Ogilvy

"Monte0682" wrote:

How is this possible to do? I want to run a form and be able to select
what worksheet I want...



Tom Ogilvy

be able to access worksheet while form is running
 
If you mean physically select a sheet while the userform is displayed

Userform1.show vbModeless

--
Regards,
Tom Ogilvy


"Monte0682" wrote:

How is this possible to do? I want to run a form and be able to select
what worksheet I want...



Bob Phillips

be able to access worksheet while form is running
 
There is a set of tabs at the bottom of the workbook. And you can see the
list by right-clicking the navigation buttons to the left of them.

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Monte0682" wrote in message
ups.com...
How is this possible to do? I want to run a form and be able to select
what worksheet I want...




Bob Phillips

be able to access worksheet while form is running
 
oops, mis-read it.

Try

Worksheets("Sheet2").Activate

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Monte0682" wrote in message
ups.com...
How is this possible to do? I want to run a form and be able to select
what worksheet I want...





All times are GMT +1. The time now is 09:09 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com