Skip to main content link. Accesskey S

The useful resource for IBM Lotus Domino XPages development

Submit Search

Available in the Appstore!All the content of xpageswiki.com for iPhone or iPad for offline access.

Home > Server JavaScript > Work with profile documents

Work with profile documents

ShowTable of Contents

Get value


For example, a text list stored in the field "areas" in the profile named "DBConfig". Then, make a string out of the array using "join()".

var doc = database.getProfileDocument("DBConfig", "");
var l = doc.getItemValue("areas");
l.join(",")

Using an Alias with your field values


I found this out today after playing with my formula for several hours.



If you have this type of value in your keyword/profile document field:




radioGroup4 = "Company | C"



this formula won't work:




var procCd = getComponent("radioGroup4").getValue(); if(procCd == "C") { // do something }



the reason is that unlike using an alias on the client the returned value is everything past the pipe rather than just the alias value itself.



So, to fix this you can either eliminate the space after the pipe or just do a trim() on the returned value



Dwain A Wuerfel


Add Comment

Name:
Comments:
Use  searchlotus.com  for news in the Web related to Lotus Notes and Domino,
and to search those sites.
Check  youatnotes.com  for great Lotus Notes, Domino and XPages software.
Did this information help you?
Please honor our efforts and flattr this!