SNTT: How to quickly check your Mail File Size

Friday 13th July, 2007
Ever wanted a quick way to check your mail file size?  Here's an easy button you can place in an action bar to allow the end user to quickly get an idea of how large their mail file is including the percentage of whitespace without having to open the database properties infobox.  I placed my button as an action in the Form "Switcher Form for Mail" so it appears in the top left corner of my mail file where you switch between Mail, Calendar and Todos.  You can place it anywhere.

The LotusScript is simple and displays a dialog box with the following information as an example:
"170 Megs with 2.7% whitespace for Total Size of 175 Megs"

Sub Click(Source As Button)
       Dim session As New NotesSession
       Dim db As NotesDatabase
       Set db = session.CurrentDatabase
       Dim size As Double
       size = db.Size
       white = db.PercentUsed
       mysize = ((size / 1024) / 1024) * ((white /100))
       Messagebox Cstr(Round(mysize,0)) + " Megs with " + Cstr(Round(100 - white,1)) + "% whitespace for Total Size of " + Cstr(Round((size / 1024) / 1024,0)) + " Megs"
End Sub

[1]