You do not necessarily need code to do this, you can do it with a query, use a Select query if yoou just want to see the calculations, or an update query if you actauuly want to update the table (eg say increase price by 10% ) Regards
Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now -
Dim Db as DAO.Database
Dim Rs as DAO.Recordset
Set Db = CurrentDb()
Set Rs = Db.OPenRecordset("SELECT * FROM MyTable;"
WIth Rs
If .REcordCount > 0 Then
Do Until .EOF
.Edit
!MyField = !Myfied * 1.10
.Update
.MoveNExt
Loop
End If
End With
Rs.Close
Set Rs = Nothing
Set Db = Nothing
you must ust your ouwn table name, column names etc of course Regards
Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now -
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.