I managed to trace the problem down to the actual calling of the dataStore. If you use the BBQ example, Paul uses a separate Xpage to form the XML input and calls it as the URL reference in his code:
var strURL = "/DanF/TexasBBQ_DGO.nsf/BBQXML_NC.xsp"
var xmlStore = new dojox.data.XmlStore({ url: strURL });
This wouldn't work inside the Notes Client!
My solution was to use an XML restService on the same page to build the input instead. This made the page more self contained and the Notes Client was able to build the page all in one go.
Here is the Xpage if my final result:
(You will need to point the URL for the dataStore to your own Xpage)
<xp:this.resources>
<xp:dojoModule name="dojox.data.XmlStore"></xp:dojoModule>
<xp:dojoModule name="dojox.grid.EnhancedGrid"></xp:dojoModule>
<xp:dojoModule name="dojox.grid.enhanced.plugins.DnD"></xp:dojoModule>
<xp:dojoModule name="dojox.grid.enhanced.plugins.NestedSorting"></xp:dojoModule>
<xp:dojoModule name="dojox.grid.enhanced.plugins.IndirectSelection"></xp:dojoModule>
<xp:dojoModule name="dojox.grid.enhanced.plugins.Filter"></xp:dojoModule>
<xp:styleSheet href="/.ibmxspres/dojoroot/dijit/themes/dijit.css"></xp:styleSheet>
<xp:styleSheet href="/.ibmxspres/dojoroot/dojox/grid/resources/Grid.css"></xp:styleSheet>
<xp:styleSheet href="/.ibmxspres/dojoroot/dojox/grid/resources/tundraGrid.css"></xp:styleSheet>
<xp:styleSheet href="/.ibmxspres/dojoroot/dojox/grid/enhanced/resources/EnhancedGrid.css"></xp:styleSheet>
<xp:styleSheet href="/.ibmxspres/dojoroot/dojox/grid/enhanced/resources/tundraEnhancedGrid.css"></xp:styleSheet>
</xp:this.resources>
<xe:restService id="restService1" pathInfo="xmlStore">
<xe:this.service>
<xe:customRestService contentType="text/xml">
<xe:this.doGet><![CDATA[#{javascript:
// initials xmlStore
var strXmlStore:String = "";
strXmlStore = "<?xml version='1.0' ?>" ;
strXmlStore = strXmlStore + "<joints>" ;
//Get the current application
var db = database;
//Access the People View
var pview:NotesView = db.getView("joints");
//Create Variables to hold the Documents and get the first document
var doc:NotesDocument;
var ndoc:NotesDocument;
doc = pview.getFirstDocument();
var nam:NotesName;
//Create a while loop to process the document in the View
while (doc != null) {
strXmlStore = strXmlStore + "<joint>";
strXmlStore = strXmlStore + "<name>";
strXmlStore = strXmlStore + doc.getItemValueString("Name");
strXmlStore = strXmlStore + "</name>";
strXmlStore = strXmlStore + "<city>";
strXmlStore = strXmlStore + doc.getItemValueString("City");
strXmlStore = strXmlStore + "</city>";
strXmlStore = strXmlStore + "<url>";
strXmlStore = strXmlStore + doc.getItemValueString("URL");
strXmlStore = strXmlStore + "</url>";
strXmlStore = strXmlStore + "<description>";
strXmlStore = strXmlStore + doc.getItemValueString("Description");
strXmlStore = strXmlStore + "</description>";
strXmlStore = strXmlStore + "</joint>";
//Get the next document in the view and store to the placeholder
ndoc = pview.getNextDocument(doc);
//recycle the doc object to preserve memory
doc.recycle();
//set the doc object equal to the placeholder
doc = ndoc;
}
//close the root tag
strXmlStore = strXmlStore + "</joints>";
return strXmlStore}]]></xe:this.doGet>
</xe:customRestService>
</xe:this.service>
</xe:restService>
<xp:panel style="text-align:center;font-family:Comic Sans MS;font-size:16pt"
disableTheme="true">
<xp:label
value="Dojo Enhanced Data Grid With XML Data Source thru Rest Service"
id="label2"></xp:label>
</xp:panel>
<xp:br />
<xp:panel id="gridNode" styleClass="DemoLeft" tagName="div"
style="height:30em;width:42em">
</xp:panel>
<xp:eventHandler event="onClientLoad" submit="false">
<xp:this.script><![CDATA[
var xmlStore = new dojox.data.XmlStore({ url: "Simple_XML.xsp/xmlStore" });
var grid = null;
dojo.addOnLoad(function(){
var layout = [{
defaultCell: { editable: false, type: dojox.grid.cells._Widget },
rows:[
{ field: "name", name: "Name", width: 20 },
{ field: "city", name: "City", width: 20 },
{ field: "url", name: "Web Site", width: 20,formatter: formatHTML },
{ field: "description", name: "Description",width:80}
]
}];
function formatHTML(url, rowIndex){
if(url.firstChild != null || url !=""){
var linkVal = "<a target='_blank' href='"+url+"'>Web Site</a>";
return linkVal;
} else{
return "";
}
}
grid = new dojox.grid.EnhancedGrid({
query: { name: '*' },
store: xmlStore,
structure: layout,
autoHeight:25,
plugins:{nestedSorting: true, dnd: true,filter:true}
}, '#{id:gridNode}');
grid.startup();
});
]]></xp:this.script>
</xp:eventHandler>
</xp:view>