Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Digital Aisle on Mar 23, 2009 14:53
open dhtmlx forum
DHTMLXGRID cookie saving problem.

Settings such as

enableAutoSizeSaving()
enableSortingSaving()
enableOrderSaving()
enableAutoHiddenColumnsSaving()

do not save between sessions (i.e. change width of column, close browser, go back to page, setting not loaded anymore).
they do however work if i just refresh the page without closing the browser.

i have tested this with both firefox & ie, and have completley turned off any form of i.e. cookie security so i'm confident its not that.

thank you for your help,
Jeff.
Answer posted by dhxSupport on Mar 24, 2009 02:28

If you want to restore size, sortina, column order and hidden state from cookies you should also use methods loadSizeFromCookie(), loadSortingFromCookie(), loadOrderFromCookie(), loadHiddenColumnsFromCookie(). You should call this method only after grid was fully loaded:

mygrid.enableAutoSizeSaving();

mygrid.enableSortingSaving();

mygrid.enableOrderSaving();

mygrid.enableAutoHiddenColumnsSaving();

mygrid.loadXML("grid.xml",function(){

mygrid.loadSizeFromCookie();

mygrid.loadSortingFromCookie();

mygrid.loadOrderFromCookie();

mygrid.loadHiddenColumnsFromCookie();

});