showView

Hi

I was just reading about the showView feature. I currently achieve similar functionality with a function “clear” that unloads content and then a function for each “view” I wish to display. Is there any benefit performance/funtionality of the showView feature over my current method?

Thanks
Theo

Hi
Not sure i understood you right, but may be you are asking for some demo to see how it works?
If so, there is the next demo about it:
dhtmlx.com/docs/products/dhtmlxL … views.html
And one more tabbar if you will need someday:
dhtmlx.com/docs/products/dhtmlxT … views.html

If you are asking some other thing - please, clarify your question

Let me rephrase using my current project.

I have many views( forms and grids) that I display in appLayout.cells(“a”).

I currently use a toolbar to change my views using this method:

appSubToolbar.attachEvent("onClick", function (id) { switch (id) { case "btnWorklist": view.patientWorklist(); break;

where in my ‘views.js’ file:

[code] patientWorklist : function(){
callbacks.clearDashboard();//clears using appLayout.cells(“a”).detachObject(true) and also hides some toolbars//
appGrid = appLayout.cells(“a”).attachGrid();
appGrid.setStyle("", “font-size:20px”,"", “”);

    appGrid.setHeader("Name, Patient ID, DOB, Sex, Procedure");
    appGrid.setColTypes("ro,ro,ro,ro,ro");
    appGrid.setColSorting('str,str,str,str,str');
    appGrid.setInitWidths('250,150,150,50,250');
    appGrid.load("data/gridWorklist.php");
    appGrid.init();
});[/code]

My question is there any advantage to using the showView feature rather that my method described above.

This approach is good too. You can use it as well.