To open the Home.xsp Xpage into your favourite browser from the Lotus Notes Client you can use code such as:
REM "Code from http://NotesNinjas.com/#OpenXpageFromClient";
r:=@DbLookup("";@Subset(@DbName;1):"names.nsf";"($Servers)";@Subset(@DbName;1);"HTTP_HostName");
s:=@If(@IsError(r) | @Text(r)=""; @DbLookup("";@Subset(@DbName;1):"names.nsf";"($Servers)";@Subset(@DbName;1);"SMTPFullHostDomain"); r);
@URLOpen("http://"+@Text(s)+"/"+@WebDbName+"/Home.xsp")
To open an Xpage in the Notes Client do this instead:
REM "Code from http://NotesNinjas.com/#OpenXpageFromClient";
@URLOpen("Notes://" + @Name([CN]; @Subset(@DbName; 1)) + "/" + @Text(@ReplaceSubstring(@ReplicaID; ":";""))+"/Home.xsp?OpenXpage")
This is the lotusscript version of opening an xpage in the client, stick it in a button.
' Lotusscript version from http://NotesNinjas.com/#OpenXpageFromClient
Dim s As New notessession
Dim db As notesdatabase
Set db = s.CurrentDatabase
Dim sname As New NotesName(db.Server)
notesurl = |notes://| + sname.common+ "/" + Cstr(db.Replicaid) + "/Home.xsp?OpenXPage"
Dim uiw As New notesuiworkspace
Call uiw.URLOpen(notesurl)
NB you need the ?OpenXPage bit in there for it to work