Hi Sir, I am sending attached excel sheet in which user form display the dynamic range. When we select range in user form with the help of list box data goes to another sheet. Sir My question is the highlighted.: Why we do listcount -1 and other question is that highlight cell .Sir I need your help. Because i am making project . That is my first project .
Dim i As Long, j As Long * For i = 0 To Me.ListBox1.ListCount - 1( Why We do listcount -1)* If Me.ListBox1.Selected(i) Then* Worksheets("Sheet1").Range("A" & i + 2).Resize(1, 6).Copy Worksheets("Sheet2").Range("A" & Rows.Count).End(xlUp).Offset(1) End If Next i* -- ---------------------------------------------------------------------------------- Some important links for excel users: 1. Follow us on TWITTER for tips tricks and links : http://twitter.com/exceldailytip 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310 3. Excel tutorials at http://www.excel-macros.blogspot.com 4. Learn VBA Macros at http://www.quickvba.blogspot.com 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com To post to this group, send email to excel-macros@googlegroups.com <><><><><><><><><><><><><><><><><><><><><><> Like our page on facebook , Just follow below link http://www.facebook.com/pages/discussexcelcom/160307843985936?v=wall&ref=ts
Copy of listbox_multiselect.xls
Description: MS-Excel spreadsheet