// Create a new workbook Workbook workbook = new Workbook(); IWorksheet activeSheet = workbook.getActiveSheet(); // Create a anonymous class for creating new signature line with predefined data Callable newSignatureLine = new Callable() { @Override public ISignature call() throws Exception { ISignature signature = workbook.getSignatures().addSignatureLine(activeSheet, 100.0, 50.0); ISignatureSetup setup = signature.getSetup(); setup.setShowSignDate(false); setup.setAllowComments(false); setup.setSigningInstructions("Please check the content before signing."); setup.setSuggestedSigner("Shinzo Nagama"); setup.setSuggestedSignerEmail("shinzo.nagama@ea.com"); setup.setSuggestedSignerLine2("Commander (Balanced)"); return signature; } }; // Create a new signature line and delete with Signature.Delete ISignature signatureForTest; try { signatureForTest = newSignatureLine.call(); } catch (Exception e) { throw new RuntimeException(e); } signatureForTest.delete(); // Create a new signature line and delete with Shape.Delete try { signatureForTest = newSignatureLine.call(); } catch (Exception e) { throw new RuntimeException(e); } IShape signatureLineShape = signatureForTest.getSignatureLineShape(); signatureLineShape.delete(); // Save to an excel file workbook.save("DeleteSignatureLines.xlsx");