This script will list out (ascending) all the database on the current server where you run this script. Put this script at WebQuerySave on the form.
By submitting your personal information, you agree that TechTarget and its partners may contact you regarding relevant content, products and special offers.
Dim ses As New notessession
Dim dbdir As New NotesDbDirectory("")
Dim db,db1 As NotesDatabase
Dim doc As notesdocument
Set doc = ses.documentcontext
Set db = dbdir.GetFirstDatabase(DATABASE)
While Not (db Is Nothing)
' "DBList" field to capture d/b list
doc.DBList =doc.DBList(0) + ";" + db.FilePath
Set db = dbdir.GetNextDatabase