Lotus Software logo
IBM Lotus Domino Designer 8.5
  Versions 8.5 and 8.5.1






Examples: IsDisabled property, clearHistory method, save method

This agent clears the replication history and disables replication.

import lotus.domino.*;

public class JavaAgent extends AgentBase {
public void NotesMain() {
try {
Session session = getSession();
AgentContext agentContext = session.getAgentContext();
// (Your code goes here)
Agent agent = agentContext.getCurrentAgent();
Database db = agentContext.getCurrentDatabase();
Replication replication = db.getReplicationInfo();
replication.clearHistory();
replication.setDisabled(true);
replication.save();
} catch(Exception e) {
e.printStackTrace();
}
}
}
Related topics
IsDisabled property
clearHistory method




Library | Support | Terms of use |

Last updated: Monday, October 5, 2009