VBA to cycle through recordset in form

BJF

Registered User.
Local time
Today, 14:06
Joined
Feb 19, 2010
Messages
137
Hi,

This is my first post here and I am definitely a novice programmer, much more of a designer in Access and in much need of help from experienced users!

Ok, here it goes!

I have a form that calculates a cost for a product that we manufacture, composed of several components, based on several specifications for each component, including width, gauge, cost, etc., which are based on numbers from other tables. In other words somewhat complex! The form is doing what i want it do to which is it gives me a cost for that product, which is a stored number that i use in other places in my database.

I've got my form functioning the way I want and it to and it recalculates current pricing when each record hits the 'on current' event of the form, but not until it hits that event.

I want to put an 'update records' type of button on that form that will allow the 'on current' event to trigger for each record in the recordset and update all product pricing in one click.

I was thinking of vba code that would cycle through each record in the form, making the 'on current event' fire and do the math for me upon clicking the button.

I'm positive there must be better ways to update my pricing, however based on the fact that I've got the form working the way i want it to for now, i'd really like to see if i could make an update button work for me for now!

Please help!!! any advice would be greatly appreciated. sorry for such a long explanation, but i'm trying to explain best as i can.

Thanks,
Brian
 

Users who are viewing this thread

Back
Top Bottom