Rocky Smolin at Beach Access Software
rockysmolin at bchacc.com
Thu Feb 19 09:23:07 CST 2009
Fortunately this is a front end table so no going over the network. And I'm going to try Shamil's Seek approach - be a simple change. But you're right about it being faster in memory anyway. What I'm trying to do is stop the flashing and repainting. What I did yesterday is change the calls in the _Open event to: Echo False Scale the Form Translate the form Maximize the Form Echo On This seem to have had a real good effect on the forms. Also noticed that the first time I open a form I get one quick repaint (I'm using Chinese to test this because it using Unicode and seems to have a little more complexity) - the second time I open the form it's faster - almost like it was already translated even though I close the form on exit. Rocky Smolin Beach Access Software 858-259-4334 www.e-z-mrp.com www.bchacc.com -----Original Message----- From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of jwcolby Sent: Thursday, February 19, 2009 4:49 AM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Find First in an Array? Rocky, A table may or may not be "noticeably slower" however you have already said that you had issues. Once you cache the data, getting data out of a cache structure will be 100 to 1000 times faster. Remember that a table is NOT cached (though a disconnected ADO recordset is I guess). DAO requires a trip to the disk OVER THE NETWORK (if any). As for going back to the beginning, please do but do not let it stop you from implementing what I will build for you. Just remember that a class object is just like any other object in Access (cbo, recordset, query) it is just a tool that anyone can use once built. I will do the building for this instance. John W. Colby www.ColbyConsulting.com Rocky Smolin at Beach Access Software wrote: > I'm wondering if an array or collection will be noticeably faster than > a recordset since there are about 2500 records in the controls table > and so it's probably all in memory already. The fields are not > indexed - so I'll bet I could get a little boost in performance by > indexing the fields I search on. > > OTOH, it's a good opportunity to learn something about classes. I'll > post the table layout tomorrow. But I think to be fair to John and > anyone else who wants to help, I should go back to all those saved > emails on the classes class and start from the beginning. > > > Rocky Smolin > Beach Access Software > 858-259-4334 > www.e-z-mrp.com > www.bchacc.com > > > > -----Original Message----- > From: accessd-bounces at databaseadvisors.com > [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Bobby Heid > Sent: Wednesday, February 18, 2009 7:21 PM > To: 'Access Developers discussion and problem solving' > Subject: Re: [AccessD] Find First in an Array? > > Rocky, > > I would also recommend that you try out collections as people > suggested earlier. But I would also try an array to compare the > speeds of lookups based upon how many items you have. For the array > approach, if the items are sorted, and there are over 100 items, I'd > recommend searching using a binary search - very fast. You could even use an array of structures. > > I would do up a little test module to test using a collection and an array. > Make sure you search for stuff that may be near the top, middle, and > the bottom. > > Thanks, > Bobby > > -----Original Message----- > From: accessd-bounces at databaseadvisors.com > [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Rocky > Smolin at Beach Access Software > Sent: Wednesday, February 18, 2009 5:57 PM > To: 'Access Developers discussion and problem solving' > Subject: [AccessD] Find First in an Array? > > > Dear List: > > I have an app set up for multiple languages. The translations are > pulled from a table at the time the form or report is opened by > cycling through the controls (labels and button captions) and getting > the appropriate translation. To make the thing run faster (there's a > noticeable translation delay), I'm thinking of loading these > translations into an array in memory and fetching the translation from > the array. However, AFAIK, there's no equivalent to a FindFirst in an > array like there is in a recordset. So, is there a better way to find > the right translation in the array short of going through the array in sequence for each item to be translated? > > > MTIA for any ideas, > > > Rocky Smolin > > Beach Access Software > > 858-259-4334 > > www.e-z-mrp.com <http://www.e-z-mrp.com/> > > www.bchacc.com <http://www.bchacc.com/> > > > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com