472,122 Members | 1,452 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,122 software developers and data experts.

VBA excel: How to enable combobox selection

I want to store data’s in selected sheet from drop down menu in userform .Suppose if I select sheet 1 data should be stored in sheet1 if I select sheet2 data’s should be stored in sheet2 . With the code below I can add sheet names in combo box. If someone helps me I shall be grateful to you.
Expand|Select|Wrap|Line Numbers
  1. Private Sub UserForm_Initialize()
  2. Dim i As Integer
  3. For i = 1 To Worksheets.Count
  4.     Me.ComboBox1.AddItem Worksheets(i).Name
  5. Next i
  6. End Sub
Jul 19 '10 #1
1 2407
639 Expert 512MB

That seem fine, so fare, but what is the problem?

Jul 19 '10 #2

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

3 posts views Thread by Ivan V via DotNetMonster.com | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.