Hi,
I am using the following code to lock ref type fields in the document:
for (com.aspose.words.Field field : document.getRange().getFields()) {
if (field.getType() == FieldType.FIELD_REF) {
field.isLocked(true);
}
}
document.updateFields();
document.updatePageLayout();
But this is taking 30+ seconds for a big document, is there any other efficient way to achieve this?