This example creates a form that lets users add a note to an active project or process. Since adding a note requires a project or process ID, this code looks first for an active project to pass to the form handler. If one doesn’t exist, the active process ID is used instead. The form created here has a large text box where a user can enter information that, when the Add a Note button is clicked, will display as a note.

<dspel:importbean bean="/atg/epub/servlet/AddNoteFormHandler"/>
  <dspel:form formid="addForm"  action="addNote.jsp" method="post">

     <c:choose>
        <c:when test="${param.projectId ne null}">
           <dspel:input type="hidden" bean="AddNoteFormHandler.projectId"
            value="${param.projectId}"/>
        </c:when>
        <c:otherwise>
           <dspel:input type="hidden" bean="AddNoteFormHandler.processId"
            value="${param.processId}"/>
        </c:otherwise>
     </c:choose>

     <p>Note:<dspel:textarea bean="AddNoteFormHandler.note" rows="4"
      cols="60"></dspel:textarea>

     <dspel:input type="submit" bean="AddNoteFormHandler.addNote" value="Add a
      Note"/>
  </dspel:form>

Copyright © 1997, 2012 Oracle and/or its affiliates. All rights reserved.

Legal Notices