PermaLink My XPage samples and beta 2 - some bug workarounds09/14/2008 08:06 AM
Domino 8.5 - XPages
I received a number of emails from folks who were having issues with some samples on my site and DDE 8.5 beta 2.  I worked with the IBM developers this past week on solving the issues and finding workarounds.  Thanks to Phil Riand and Paul Hannan for working with me on these issues, I now have the below solutions.

There were 2 issues:

Getting a handle on the backend document that represents the current document for the page.  
- when submitting a document, in order to gain full access to the NotesDocument class representing the current document you need to use "doc=document.getDocument();" method.  For example, you would use this method to get a copy of the document when creating a response document for the current document.  With beta 2 the document was discarded after the save occurred and therefore calling this method produced an error.
- The workaround: use this to get a handle on the NotesDocument for the current document "doc=db.getDocumentByID(document.getNoteID());"

Generating dynamic controls for a document collection and binding each document to a panel.
- What was happening was the Save Data Sources simple action was failing.  This is a great feature in that it will save all bound documents that are on the page, instead of having individual save buttons.  You can also call this method in server side script by calling the Global function  "save();".
- The solution is to have the panel document binding computed on Page Load instead of Dynamically

Image:John's Blog - My XPage samples and beta 2 - some bug workarounds

If you click on the Source tab for your XPage, you can change this manually by changing the "#" to a "$" for your script bindings to the document IDs:

Image:John's Blog - My XPage samples and beta 2 - some bug workarounds

I was told that both of these issues are fixed for the GA build, so my previous examples should work without any changes when the product goes gold.

John

Technorati:
This page has been accessed 2179 times. .
Comments :v

1. Jonas12/04/2008 07:18:53 AM


Hi,
Trying out the file upload control in beta 2 and it fails due to no value in DocUNID field ie no value set in parentUNID in the other database resulting in no controls showing up when pressingbutton.




2. Jonas12/08/2008 03:26:30 AM


Thanks for mail answer. Error occurred when setting up databases in subfolders even if coding paths to folders. If moving to Root everything works fine

/J




3. vayasin11/09/2009 03:41:30 AM


Hi, I have a strange problem with xpages, in our system we always work with short url's like:
http: //servername/ __replicaid.nsf/xpage.xsp this to prevent password popups (basic authentication) due to different directories.
Hower this gives a Error "Command Not Handled ExceptionNo information found" when the xpage is loaded for the first time. If I use the long path http: //servername/dir/dbname.nsf/xpage.xsp then there is no problem.
Is there a way to solve this?




4. Michael Garfield11/20/2009 08:53:41 AM


I have been successful in making updates to the discussion template, but found one thing that I need help on. A user can see the "Edit" button (that don't have Editor rights) but can't edit. Now this document was created by the user and the readers field is blank or have their @UserName in the field. Do you know what's wrong?




Search
Partner with us
Need help on your XPages projects?

Talk to the experts! Read more...
XPage Examples
By Category
About Me
Downloads
My Links
Monthly Archive
Powered by
Blogsphere
Lotus Domino ND7 RSS News Feed RSS Comments Feed Geo URL netcraft RSS Validator Lotus Geek Chris. A. Brandlehner OpenNTF BlogSphere