Solved

MSFlexGrid slow 2nd time around

Posted on 2003-10-28
3
313 Views
Last Modified: 2013-12-25
The problem I'm having is when I try to fill the grid with a different resultset.  The first time it loads it's lightning fast.  The second time I try to load data its very slow.  The order by clause in both statements is indexed.  I'm lost.  It would seem like there is something I'm not doing with the grid

Jim
0
Comment
Question by:JZUPKUS
3 Comments
 
LVL 42

Accepted Solution

by:
frodoman earned 125 total points
ID: 9637974
Try clearing the resultset & grid completely before reloading it.  I found this solved my identical problem.

I can't explain why it worked because it was mainly a trial & error solution but maybe it'll work for you too ;)
0
 
LVL 18

Expert Comment

by:Sethi
ID: 9638154
Please post the code.
0
 

Author Comment

by:JZUPKUS
ID: 9644088
I already use Grid.Clear and closed the resultset.  But, talking/typing this out made me think of something.  The first time the grid is loaded the form is not visible.  So when I went to reload the grid with a different resultset with the form VISIBLE it took a long time.  I added Me.Hide before the load and Me.Show after the grid was populated and it was back to very fast!

This problem has bothered me for a long time and talking it out helped so I'll give you the points Frodoman.  Good thing to remember.  Dec 17th approaches - Return of the King.  

Thanks,
Jim
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

860 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question