Link to home
Start Free TrialLog in
Avatar of Joseph Krausz
Joseph Krausz

asked on

MS Access Form, Datasheet view, Toggle \ show Totals Row via VBA

I had this question after viewing VBA Datasheet view Ms Access how to reference the total row cells.

I have tried to use this solution to show the totals row on a Form' Datasheet view, for some reason it's not working  -the totals row does not show up (PS. There's a mistake in the referred post, instead of TotalRow it should be TotalsRow)
Avatar of Rey Obrero (Capricorn1)
Rey Obrero (Capricorn1)
Flag of United States of America image

a sample db will help figure out the problem.
Avatar of Joseph Krausz
Joseph Krausz

ASKER

open th datasheet form and select the column you want to sum
then from the ribbon
 Home > Total

\see sample db
post back if you have any questions
Sample-TotalsRow.accdb
I want to be able to do it with VBA, not from the Home tab
From your form, while running the form. Select:
Home > Totals.
You need to do it once, as if part of design. You may turn it off if not required.
If you click any field in the total row, while running the form, you can select any applicable aggregate .

Trying to find a way to toggle it to show or hide, the totals, using VBA.  This may be useful if using custom ribbons.
ASKER CERTIFIED SOLUTION
Avatar of Hamed Nasr
Hamed Nasr
Flag of Oman image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
This is the solution!!!
Actually, I was looking for a way to execute the msoid and didn't find the way... now i got it. Thanks
Welcome!