I had to gather information regarding the versions of the Notes Client that people were running throughtout my company. This way we would troubleshoot people a lot faster with upgrades. I placed code into the "QueryOpen" event of the ($Inbox) folder on our mail template and then we let it run throughout the next couple of days. This way we were sure to grab our notes users' information. I also set an environment variable so that the email is sent out only once and I can change the code at a later time in case I need to gather more information. Hope this helps you out.
Dim s As New notessession Dim db As notesdatabase Set db = s.currentdatabase Dim x As Integer x = s.getenvironmentvalue("Checked") If x <> 1 Then Call s.setenvironmentvar("Checked", 1) Dim doc As notesdocument Set doc = db.createdocument doc.Subject = "My notes Version" doc.form = "Memo" doc.sendto = "Administrator" Dim rtitem As notesrichtextitem Set rtitem = New NotesRichTextItem(doc, "Body") Call rtitem.appendtext(s.commonusername) Call rtitem.addnewline(1) Call rtitem.appendtext(s.notesversion) doc.send(True) End If