Cannot save documents opened in Oxygen author component
Posted: Wed Jan 30, 2013 6:36 pm
Hi again,
I have some troubles using oxygen author component (AuthorComponentProvider), i can't save documents using keyboard action CTRL+S.
I have implemented a custom action (with CTRL+S mnemonic) accessible in a toolbar to save the content of my document, this works fine only if the cursor is outside my document content.
Otherway, if the cursor is inside my document content (ie : in oxygen component), this seems the action is handled by something else (i think this is something from oxygen), and this throws me the error : "Cannot save the file. protocol doesn't support output"
I load my document using this code coming from demo :
When i open a document, the arguments values are :
xmlSystemId = file:/C:/authorNeo/DM-Sample/A350/DMC-BRAKE-AAA-DA1-00-00-00AA-041A-A_001-00_EN-US.XML
xmlContent = null
Is there anything i'm doing wrong?
I have some troubles using oxygen author component (AuthorComponentProvider), i can't save documents using keyboard action CTRL+S.
I have implemented a custom action (with CTRL+S mnemonic) accessible in a toolbar to save the content of my document, this works fine only if the cursor is outside my document content.
Otherway, if the cursor is inside my document content (ie : in oxygen component), this seems the action is handled by something else (i think this is something from oxygen), and this throws me the error : "Cannot save the file. protocol doesn't support output"
I load my document using this code coming from demo :
Code: Select all
private void setDocument(final String xmlSystemId, final Reader xmlContent)
throws AuthorComponentException {
final Exception[] ex = new Exception[1];
AccessController.doPrivileged(new PrivilegedAction<Object>() {
public Object run() {
// Installs a document modification listener.
try {
authorComponent
.load((xmlSystemId != null && xmlSystemId.trim()
.length() > 0) ? new URL(xmlSystemId)
: null, xmlContent);
} catch (Exception e) {
ex[0] = e;
}
return null;
}
});
if (ex[0] != null) {
throw new AuthorComponentException(ex[0]);
}
}
xmlSystemId = file:/C:/authorNeo/DM-Sample/A350/DMC-BRAKE-AAA-DA1-00-00-00AA-041A-A_001-00_EN-US.XML
xmlContent = null
Is there anything i'm doing wrong?