@Name on XPage

I have a computed field on an Xpage that I want to contain the abbreviated name of the current user; I can get the distinguished name into the field via @UserName, but I cannot get @Name to work - even if I copy the sample…

My code

var nm = @UserName;

@Name(“[ABBREVIATE]”, nm);

I also tried

@Name(“[ABBREVIATE]”, @UserName);

and that didn’t work either

The Server’s log error message

HTTP JVM: 07-Jul-2008 14:51:10 com.ibm.commons.log.AbstractLogMgr log

SEVERE: CLFAD####E: Error processing request

com.ibm.xsp.exception.EvaluationExceptionEx: Error while executing JavaScript computed expression

at com.ibm.xsp.binding.javascript.JavaScriptValueBinding.getValue(JavaScriptValueBinding.java:89)

at com.ibm.xsp.page.compiled.ExpressionEvaluatorImpl.getBindingValue(ExpressionEvaluatorImpl.java:150)

at xsp.RRinXPage$RRinXPagePage.createComputedfield1(RRinXPage.java:

The Browser screen…

Unexpected runtime error

The runtime has encountered an unexpected error.

Error source

Page Name:/RRinXPage.xsp

Exception

Error while executing JavaScript computed expression

Script interpreter error, line=2, col=1: Error while executing function ‘@Name

com.ibm.domino.xsp.module.nsf.runtime.NotesDirectory incompatible with com.ibm.designer.runtime.directory.ex.DirectoryServerEx

Javascript code

1: var nm = @UserName;

2: @Name(“[ABBREVIATE]”, nm);

► ▼ Stack Trace

Subject: @Name is broken in Beta 1, but there is a workaround…

@Name() is currently broken in Beta 1. As a workaround, you could use

var name:NotesName = session.createName(@UserName());

name.getAbbreviated();

Thomas Gumz - Advisory Software Engineer - IBM Lotus Software

Subject: Thomas, Thanks

CheersMick