Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Programming / March 2008

Tip: Looking for answers? Try searching our database.

in Me.lbx.MultiSelect = fmMultiSelectMulti

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
x taol - 24 Mar 2008 02:22 GMT
that case,,, the line have 50,000 data..
i want to select the all data...
but, lbx.selected(i)=true....... is no good... this is slow... for
loop..
at once,one stop,,,, setting
Barb Reinhardt - 24 Mar 2008 03:11 GMT
You don't say a lot about what you are doing, but this might be a way to do it

Dim lRow as long
dim myRange as range

Set myRange = activesheet.cells(1,1)  'First cell of range to select
lRow = activesheet.cells(activesheet.rows.count,myrange.column).end(xlup).row

if lRow > myRange.row then
  Set myRange = myRange.resize(lrow-myrange.row + 1,1)
end if

myRange.select

Signature

HTH,
Barb Reinhardt

> that case,,, the line have 50,000 data..
> i want to select the all data...
[quoted text clipped - 3 lines]
>
> *** Sent via Developersdex http://www.developersdex.com ***
x taol - 24 Mar 2008 03:31 GMT
It is a listbox on the userform.....
in that listbox control......
JLGWhiz - 24 Mar 2008 04:46 GMT
Please review this site, then try again.

http://home.satx.rr.com/badour/html/post.html

> that case,,, the line have 50,000 data..
> i want to select the all data...
[quoted text clipped - 3 lines]
>
> *** Sent via Developersdex http://www.developersdex.com ***
x taol - 24 Mar 2008 08:18 GMT
yes, I explain....
I have a userform.
the userform has a listbox.
a property the listbox is set following below.
lbx.MultiSelect = fmMultiSelectMulti
when the listbox have 10000 data, the problem has.
when the 10000 data is selected... the slow...
and then press a commandbutton on the form, the event occur.
I want to select all data of listbox, fastly.
Office_Novice - 25 Mar 2008 20:04 GMT
Try this worked very quickly @ 6000 + rows

Option Explicit

Private Sub CommandButton1_Click()
   With Me.ListBox1
       .RowSource = "A1:F65536" <--- change for your needs
   End With
End Sub

Private Sub UserForm_Initialize()
With Me.ListBox1
   .ColumnCount = 6< --- change for your needs
End With
End Sub

> yes, I explain....
> I have a userform.
[quoted text clipped - 7 lines]
>
> *** Sent via Developersdex http://www.developersdex.com ***
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.