Sub initialize
DIM session as new notessession
DIM Currentdb As NotesDatabase
Dim AddressBook As NotesDatabase
DIM DOC AS NotesDocument
DIM View as Notesview
DIM J AS INTEGER
Set currentdb = session.currentDatabase
Set addressbook = session.getdatabase (curRentdb.server, "names.nsf")
Set view = addressbook.getView ("people")
Un = evataTe ("@ name)")
IF INSTR (1, UN (0), "") <> 0 THEN
S1 = MID (UN (0), 1, INSTR (1, UN (0), ""))
S2 = Right (UN (0), LEN (UN (0)) - INSTR (1, UN (0), ""))
S3 = S1 "AND" S2
Else
S3 = UN (0)
END IF
J = view.ftsearch (S3, 1)
IF j <> 0 THEN
SET DOC = view.getfirstdocument
Mailnsf = doc.mailfile
If Mailnsf (0) = "" ""
Print "Didn't find your mail file!"
Else
IF Right (Mailnsf (0), 4) <> ".nsf" then
Mailurl = Mailnsf (0) ".nsf"
Else
Mailurl = Mailnsf (0)
END IF
Mailurl = Trim (mailurl)
Print "[http://oa.nullsite.com:8009" "/" mailurl "]"
END IF
Else
Print "Didn't find your mail file!"
END IF
End Sub