Susan Harkins
harkins at iglou.com
Sat Jun 21 22:14:41 CDT 2003
Try adding a Me.Recalc to the form's Load event just in case. Susan H. > Susan, > > I thought about that, but almost all the action is in the queries now > and everything recalculates each time I change records from the record > selector combo box on the form. The only thing that is different > between the form working and it not working is that when I works I open > it first in design view and then switch to form view. If I then select > a record using the on-form combobox it works correctly and all numbers > are calculated and displayed correctly. I can then select another > record and it too is displayed correctly. > > If I open the main form directly in form view, and then select a record > using the combobox I get the error text in the calculated controls. If I > then change the misbehaving form to design view and then back to form > view it works as above. Something seems to be different about how the > form is originally opened. > > I tried the compile all modules, decompile, compact, and recompile > procedure but that didn't make any difference. > > Weird. > > Doug > > > > > -----Original Message----- > From: accessd-bounces at databaseadvisors.com > [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Susan Harkins > Sent: Saturday, June 21, 2003 5:15 PM > To: accessd at databaseadvisors.com > Subject: Re: [AccessD] Subform Errors > > My guess is, you're buying a little calculating time. You may have more > calculations than your subform can handle -- seen it happen before when > counting records in a really large recordset -- can't count them fast > enough, so it returns an error. Any way you can move some of those > expressions to the query? > > Susan H. > > > > > > > > List, > > > > I have an Access 97 database and am having a problem with a > > form/subform. The main form holds data for the parent record and the > > subform shows data for the child records for the parent; a typical > > design. The subform is based on a semi complex query that has some > > calculations in it that sum some cost fields for each record. There > are > > several hidden calculated text boxes on the subform that perform > further > > data aggregations for several fields from each record. I refer to > these > > fields in controls on the parent form to show their value. Hopefully > > this description isn't too confusing. > > > > The problem is that the forms work correctly when the main form is > first > > opened in design view and then switched to form view. When the form > is > > opened in this fashion and a record selected from a selector combo box > > all fields function and calculate correctly. If the main form is > opened > > directly to form view and a record selected the calculated controls > > contain "error". If I then switch the form to design view and back to > > form view it works correctly. There is very little code behind these > > forms and nothing on a form event except docmd.maximize on form > > activate. This is the first time I have run into this situation. Why > > would the form behave differently based on whether it was first opened > > in design view or directly into form view? > > > > Doug > > > > > > _______________________________________________ > > 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 > > > _______________________________________________ > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > >