Skip to main content



      Home
Home » Eclipse Projects » NatTable » ignoring number of persisted rows (while restoring table)
ignoring number of persisted rows (while restoring table) [message #1713939] Sun, 08 November 2015 14:33 Go to next message
Eclipse UserFriend
Hi all,
I'm storing the layout of the NatTable in a properties file. The content
of the table for the list changes on every call. Now, if I restore the
layout from properties file I get always this error message:


Number of persisted rows (2) is not the same as the number of rows in
the data source (1).
Skipping restore of row ordering


(the numbers changes every time). How can I suppress this message? I
only want to store the column widths. Is it possible? Thanks in advance
for your answers.

Ralf.
Re: ignoring number of persisted rows (while restoring table) [message #1714014 is a reply to message #1713939] Mon, 09 November 2015 07:09 Go to previous message
Eclipse UserFriend
Looks like you are using RowReorderLayer or GlazedListsRowReorderLayer and you load and store the NatTable states via build-in Java Properties mechanism.

That mechanims is always storing all current states and loads all of them if applied. If you don't want to consider several states, you should remove them from your Properties object, either on save or on load (I would prefer on save to keep the stored Properties as small as possible). That means, modify the result of NatTable#saveState() by removing the state for the key prefix + RowReorderLayer.PERSISTENCE_KEY_ROW_INDEX_ORDER
Previous Topic:nattable is not getting updated on adding the data to eventlist
Next Topic:Indexing for sorted GlazedList
Goto Forum:
  


Current Time: Sat Jun 21 01:10:33 EDT 2025

Powered by FUDForum. Page generated in 0.03861 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top