Dhrumil Shah
Dhrumil Shah

Reputation: 746

Saving preference values from table

I'm having a preference page, which extends PreferencePage (not FieldEditorPreferencePage), and implements IWorkbenchPreferencePage. I have a table in my preference page and user can add any number of rows to the table. All the rows in the table have to persistence in the preference store. I see only setValue() methods in the preference. The problem is I don't know the number of rows in advance and it is dynamic. Can someone tell me how to save the values in the table into the preference store?

Thanks in advance,

Upvotes: 0

Views: 196

Answers (1)

Alexey Romanov
Alexey Romanov

Reputation: 170735

Just store a string which contains contents of all rows (delimited, so that you can break it back into rows when needed).

Upvotes: 1

Related Questions