};
spreadSheet.setSpreadSheetCategory(spreadsheetCategory); // for columns - must do first
SpreadSheetFieldArray fields=getFields();
if (((ResourcePool)document).isMaster()){
fields=(SpreadSheetFieldArray)fields.clone();
fields.removeField("Field.userRole"); //$NON-NLS-1$
}
spreadSheet.setCache(cache,fields,fields.getCellStyle(),fields.getActionList());
((SpreadSheetModel)spreadSheet.getModel()).setFieldContext(fieldContext);
spreadSheet.setReadOnly(readOnly);