Training details in PD ?

Hi
Can training courses, the history of Training attanded by the employee, Training needs identification as per Appraisals without integration with Training and Event Management sub-module  be incorporated in PD...
Regards

hi Shrikant,
Training needs and history are maintained in module training and Event Management.
if you don't want to use the training & event management, then you might want to use the standard infotype in personnel administration (infotype 22 - education), by setting up the subtype etc.
however, it is not linked with qualification/competence, so you can't transfer qualification once the training is recorded in the system. It is just training history.
secondly, there is no training needs in PA. So you would have to build the infotype to record that, and the link to the training history to say that the training needs have been fulfilled, and it wouldn't be linked with Performance appraisal.
not sure about the scope of your implementation. the best one is still to keep the training & event mgmt. Still there are some work around you might find along the way...
good luck
cheers
salomon

Similar Messages

  • Need SAP XI training details in Bangalore

    Hi Friends,
    I need some information on SAP XI training in <b>Bangalore</b>.
    Can you please provide me the below information.
    1.SAP XI training contents.
    2. whether the SAP XI training includes the <b>SeeBurger EDI</b> adapter also? if not where shall i get this training details..
    3. What will be the individual cost for the training
    4.What will be the corporate cost for training 15 to 16 people.
    5.What will be the duration of the training
    6.What is the basic skillset required before taking the training.
    7.Is the training is instrctor based or e-learning?
    My contact number is <b>9980822104</b> and email is  <b>[email protected]</b>
    Thanks in advance....
    Hope i will hear from you soon..
    Regards
    Venkatesh

    Siemens is the authorized centre available for SAP training.
    Search in google for Siemens contact details and mail them. They will be more than happy to assist you.
    If you take a training at authorized centre, you will get all SAP certification materials. TBIT40,TBIT41,TBIT42,TBIT43,TBIT44.
    Seeburger adapter is not covered in the training since it is a third party adapter. You can get the details on how to use this adpter from service.sap.com
    Regards,
    Jai Shankar

  • XI Training details

    Hi,
    I have enough experience in SAP NetWeaver EP. I have done projects in Web Dynpro Java, PDK and l have little bit Administration knowledge.
    I have knowledge on ABAP development also.
    Now I would like to go for SAP XI / PI training.
    Please guide whether this is the correct path to me to add more value for my profile.
    Let me know if any other relevent modules to get training.
    Thanks

    Hi,
    I would suggest you to talk to some education consultants from SAP India Pvt Ltd; Bangalore.
    As SAP XI and EP trainings in INDIA are deliverd only by SAP India Pvt Ltd.
    They will be able to suggest you much better....
    Regards
    an SAP Education Cosultant

  • Regarding EHS details

    Dear Friend,
    My friend is an Environmental Engineer having 5 years of experience in water and waste water treatment technology. She wants to move to SAP EHS. Kindly suggest if it is recommendable. Also please provide more detail regarding training of EHS.
    Regards,
    Chinmay

    Hi Chinmay,
    Before coming to SAP-EHS one should have the domain knowledge of EHS and needs to be updated with local and international regulations that are in practice for chemicals, wastes etc.
    With Environmental engg. degree and suitable experience, your friend is game for SAP-EHS. It won't be a problem for her as far as learning SAP-EHS is concerned.
    Official SAP-EHS training is provided by Technidata (SAP partner for EHS). Unfortunately that training is not available in India. It is available in Germany and USA. Please visit their website for training details:
    www.technidata.de/ehs-training and www.tdamerica.com/education.
    To start with, Please visit the following links for SAP EHS overview:
    http://www.sap.com/solutions/business-suite/erp/corporate_services/ehs/index.epx
    And here is a link for Help on SAP EHS. This describes the SAP EHS components in details. It gives information about offerings of SAP-EHS :
    http://help.sap.com/saphelp_erp60_sp/helpdata/en/a5/3adda043be11d188fe0000e8322f96/frameset.htm
    Regards,
    Niraj

  • LSO 300 - Interfacing to External Training Providers

    Hello All,
    I'm starting an initial investigation on our options to interface to external training providers. This was mentioned by an SAP consultant some years back when we first implemented but I'm finding relatively little for 300. The document at...
    https://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/329da1a8-0b01-0010-b399-c04517307bcd&overridelayout=true
    ... give some info on 300 options, specifically on page 6. Has anyone know of any more detailed documentation on setting this up in LSO 300?
    Thanks,
    Doug

    Hi Kumar,
    By extrenal trainings, do you mean course type which is of type "External WBT" or "External classroom training"?.
    If so, then usually information is exchanged bewteen the SAP & the other external system in a standard way through pre-defined messages.I have worked only through XI for such a scenario. In Exchange Infrastrcuture, there are standard XML kind of data which is used for LSO & external trainings. Through this, the booking,cancellation & other related data are passed on to the SAP system from the external systems.
    For this to work, there are a few things that need to be ensured.
    The same person should exist in both the systems.
    For WBT, the course content is externally hosted & is linked thru infotype 5042 when the course type is created
    For classroom trainings, the course(E) & not D is linked with infotype 5042 for external training details.
    Regards,
    Sowmya

  • Exadata Instructor-Led Training Vs Live Virtual Classes

    I have seen the Exadata Course Training details on oracle.com/education. Cost of the training is $3000 (3 Days) in US for Instructor-Led Training and $1500 (2 Days) for Instructor-Let /Live Virtual classes.
    Is it worth taking the training since the training is on ODM not on actual machine.
    Which training is better Instructor-Let or live Virtual Classes.
    Did anyone took the training. Any advice from the persons who took the training.

    Hi buddy,
    Which training is better Instructor-Let or live Virtual Classes. As the books are suppose to be the same... One more answer "doesn't matter"... The most important part of those OU training ( at least to me ) are the books not if You'll be able to see the intructor face-to-face.
    Did anyone took the training. Any advice from the persons who took the training.Ask Your boss to buying one and starting working on that as soon as possible.... Also, reading blogs from Kevin Closson/Greg will be very very helpfull ;)
    Good luck!
    Cerreia

  • Mass Upload-Ext Training Results

    Hi Friends
    I have a issue -we need to upload Ext Training results in SAP LSO ,could any one pls share their ideas on how to upload the results is there any std programm is there or we need to upload manually.
    regards
    Kumar

    Hi Kumar,
    By extrenal trainings, do you mean course type which is of type "External WBT" or "External classroom training"?.
    If so, then usually information is exchanged bewteen the SAP & the other external system in a standard way through pre-defined messages.I have worked only through XI for such a scenario. In Exchange Infrastrcuture, there are standard XML kind of data which is used for LSO & external trainings. Through this, the booking,cancellation & other related data are passed on to the SAP system from the external systems.
    For this to work, there are a few things that need to be ensured.
    The same person should exist in both the systems.
    For WBT, the course content is externally hosted & is linked thru infotype 5042 when the course type is created
    For classroom trainings, the course(E) & not D is linked with infotype 5042 for external training details.
    Regards,
    Sowmya

  • SAP PCM Training

    Hi
    I am interested in getting trained on SAP PCM solution. I am in India and have worked on the concept for 9 years. It is the tool that I am interested in. Could somebody provide information on training in India on this? if not the nearest country? approx cost?
    Thanks and regards
    Rajen Patil

    Dear Vasuraj,
    Please find training details at : http://www.sap.com/education
    Link given below has the curriculum for PCM course:
    http://www.sap.com/services/education/catalog/businessobjectstraining/epm/curriculum.epx?context=[[BOBJ_PCM_vXIR2]]|
    Hope this helps!
    Cheers,
    Umesh

  • OpenText training

    I am looking for some OpenText training offerings online. What companies offer training plus a test environment already integrated with ECC 6?

    OpenText itself offers training for its SAP related products such as Archiving , VIM, ECM. You can find training details at www.opentext.com

  • Problem with jsp and controller

    <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core"%>
    <%@ taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt"%>
    <%@ taglib uri="http://www.springframework.org/tags" prefix="spring"%>
    <%@ page import='com.uk.nhs.training.data.ActivityMatrix'%>
    <SCRIPT language="JavaScript" type="text/javascript">
    function bookActivity()
    if (document.bookActivityController.activitySelect.selectedIndex == 0)
    alert("Please Select Activity");
    else if (document.bookActivityController.trainerId.selectedIndex == 0)
    alert ( "Please Select Trainer");
    else if(document.bookActivityController.fromDate.value=="")
    alert("Please supply the Start Date of Activity")
    else
    validateForExistingCourses();
    function validateForExistingCourses()
    flag="wait";
    var trainerId=document.getElementById("trainerId").value;
    var fromDate=document.getElementById("fromDate").value;
    var toDate=document.getElementById("toDate").value;
    var activityId=document.getElementById("activitySelect").value;
    url="ajaxList.htm?actionType=checkBookedCoursesActivities&trainerId="+trainerId+"&fromDate="+fromDate+"&toDate="+toDate+"&activitySelect="+activityId;
    what = "checkForPreBookedCoursesActivities(req.responseXML)";
    doCallback(null);
    function checkForPreBookedCoursesActivities(theXmlResponse)
    // alert("in here in checking prebookedCourses");
    if(theXmlResponse != null)
         var isActivityExisting = theXmlResponse.getElementsByTagName('existingActivity')[0].text;
         var isCourseExisting = theXmlResponse.getElementsByTagName('existingbookedcourse')[0].text;     
              if(isActivityExisting=="Y")
              alert("Activity You are trying to book for Trainer already exists");
              return false;
              else if(isCourseExisting=="Y")
              if(confirm('Conflict Message. The dates choosen conflict with a current booking. Do you want to override'))
    window.open("/training1.1/secure/prebookedEvents.htm","clientwindow",'StatusBar', 'toolbar=yes,resizable=yes,scrollbars=yes,width=500,height=400,left=0,top=0');
    return false;
    else
    document.bookActivityController.action="/training1.1/secure/bookActivityTrainer.htm?actionType=submitForm";
    document.bookActivityController.submit();
    function goHomePage()
         window.location="/training1.1/secure/welcome.htm";
    function showHideAmPm(divId)
    if(document.bookActivityController.halfday.checked==true)
    showDiv(divId);
    else
    hideDiv(divId);
    function showDiv(divId)
    var item = document.getElementById(divId);
    alert("show item"+item);
    if (item)
    item.className='unhidden';
    function hideDiv(divId)
    var item = document.getElementById(divId);
    alert("unhide item"+item);
    if (item)
    item.className='hidden';
    function getActivitiesPm()
    if(document.bookActivityController.am.checked==true)
    document.bookActivityController.pm.checked=false;
    flag="wait";
         url="ajaxList.htm?actionType=activities&keyword=PM";
         what = "setActivities(req.responseXML)";
         doCallback(null);
         document.bookActivityController.activityTimeSelect.value="halfday";
         document.bookActivityController.activityTimeSubType.value="pm";
         // alert("subType"+document.bookActivityController.activityTimeSubType.value);
    function getActivitiesAm()
    if(document.bookActivityController.pm.checked==true)
    document.bookActivityController.am.checked=false;
    flag="wait";
         url="ajaxList.htm?actionType=activities&keyword=AM";
         what = "setActivities(req.responseXML)";
         doCallback(null);
         document.bookActivityController.activityTimeSelect.value="halfday";
         document.bookActivityController.activityTimeSubType.value="pm";
    function getSingleDayActivities()
    if(document.bookActivityController.singleday.checked==true)
    document.bookActivityController.moredays.checked=false;
    document.bookActivityController.halfday.checked=false;
    hideDiv('partofhalfday');
    document.bookActivityController.activityTimeSelect.value="fullday";
    flag="wait";
         url="ajaxList.htm?actionType=activities&keyword=FullDay";
         what = "setActivities(req.responseXML)";
         doCallback(null);
    else
    hideDiv('activitySelect');
    function getMoreDaysActivities()
    alert();
    if(document.bookActivityController.moredays.checked==true)
    document.bookActivityController.singleday.checked=false;
    document.bookActivityController.halfday.checked=false;
    hideDiv('partofhalfday');
    document.bookActivityController.activityTimeSelect.value="moredays";
    flag="wait";
         url="ajaxList.htm?actionType=activities&keyword=FullDay";
         what = "setActivities(req.responseXML)";
         doCallback(null);
    else
    hideDiv('activitySelect');
    showDiv('dateTo');
    function setActivities(theXmlResponse)
              //start filling the Venues Select boxes now
              if(theXmlResponse != null)
                   var coursesBox=document.getElementById("activitySelect");
                   coursesBox.options.length=0;
                   var activityElementsLength=theXmlResponse.getElementsByTagName('activity').length;     
                   var activityElementsArray=theXmlResponse.getElementsByTagName('activity');
                   //alert("length"+activityElementsLength+activityElementsArray);                              
              for(x = 0; x < activityElementsLength; x++)
                        //coursesBox.options[coursesBox.options.length] = new Option(coursesElementsArray[x].firstChild.text, coursesElementsArray[x].lastChild.text);
                        var optn = document.createElement("OPTION");
                   optn.text = activityElementsArray[x].firstChild.text;
    optn.value = activityElementsArray[x].lastChild.text;
    coursesBox.options.add(optn);
         if (activityElementsLength>0)
                   showDiv('activityTD');
              flag="release";
    </script>
    <div id="content"><!-- Top story -->
    <div id="topstory" class="box">
    <div id="topstory-img"></div>
    <!-- /topstory-img -->
    <div id="topstory-desc">
    <div id="topstory-title"><strong>BOOK Activity</strong></div>
    <!-- /topstory-title -->
    <div id="topstory-desc-in"></div>
    <!-- /topstory-desc-in --></div>
    <!-- /topstory-desc --></div>
    <!-- /topstory -->
    <div id="bodycontent">
    <% int errorCount=0; %>          
              <spring:bind path="bookactivityevent.*">
              <c:forEach items="${status.errorMessages}" var="error">
                        <B><font color="red">Error: <c:out value="${error}"/></font><B/>
                        <% errorCount++; %>
              </c:forEach>
              </spring:bind>
    <form method="post" name="bookActivityController" action="<c:url value="/secure/bookActivityTrainer.htm"/>">
    <table align="right" width="50%" border=0>
    <input type="hidden" name="activityTimeSelect"/>
    <input type="hidden" name="activityTimeSubType"/>
    <tr>
    <td align="left">
    <INPUT TYPE="checkbox" NAME="halfday" onclick="showHideAmPm('partofhalfday')">Half Day    
    <div align="left "id="partofhalfday" class="hidden">
    <INPUT TYPE="RADIO" NAME="am" onClick="getActivitiesAm()" value="am">AM <INPUT TYPE="RADIO" NAME="pm" onClick="getActivitiesPm()">PM <BR>
    </div>
    </td>
    </tr>
    <tr><td><INPUT TYPE="checkbox" NAME="singleday" onClick="getSingleDayActivities()"> Single Day</td>
    </tr>
    <tr>
    <td><INPUT TYPE="checkbox" NAME="moredays" onClick="getMoreDaysActivities()"> More Days</td>
    </tr>
         <tr>
              <td align="left" id="activityTD">Activity :
              <c:set var="activityMap" value=${requestScope.activityMap}/>
         <c:choose>
                        <c:when test="${activityMap = null}"
         <spring:bind path="bookactivityevent.userSuppliedActivity.activity.activityId">
              <select name="activitySelect" id="activitySelect" size="1"
                   STYLE="width: 150px">
                   <option value="Choose Activity" default>Choose Activity</option>
              </select>
              </spring:bind>
              </c:when>
              <c:otherwise>      
              <spring:bind path="bookactivityevent.userSuppliedActivity.activity.activityId">
              <select name="activitySelect" id="activitySelect"
                   size="1" STYLE="width: 150px">
                   <option value="" default>Choose Activity</option>
                   <c:forEach var="activity" items="${activityMap}" varStatus="a">
                        <c:choose>
                             <c:when
                                  test="${(bookactivityevent !=null) && (bookactivityevent.userSuppliedActivity.activity.activityId == activity.activityId)}">
                                  <option value="<c:out value="${activity.activityId}"/>" selected><c:out
                                       value="${activity.activityId}" /></option>
                             </c:when>
                             <c:otherwise>
                             <option value="<c:out value="${activity.activityId}"/>"><c:out
                                       value="${activity.activity}"/>
                             </c:otherwise>
                        </c:choose>
                   </c:forEach>
              </select>
         </spring:bind>
         </c:otherwise>
         </c:choose>
         </td>
    </tr>
         <tr>
              <td align="left">Trainer:
              <spring:bind path="bookactivityevent.userSuppliedActivity.trainer.trainerId">
              <select name="trainerId" id="trainerId"
                   size="1" STYLE="width: 150px">
                   <option value="" default>Choose Trainer</option>
                   <c:forEach var="trainer" items="${trainers}" varStatus="a">
                        <c:choose>
                             <c:when
                                  test="${(bookactivityevent !=null) && (bookactivityevent.userSuppliedActivity.trainer.trainerId == trainer.trainerId)}">
                                  <option value="<c:out value="${trainer.trainerId}"/>" selected>
                                  <c:out value="${trainer.firstName}"/>&nbsp<c:out
                                       value="${trainer.surName}" /></option>
                             </c:when>
                             <c:otherwise>
                                  <option value="<c:out value="${trainer.trainerId}"/>"><c:out
                                       value="${trainer.firstName}"/>&nbsp<c:out
                                       value="${trainer.surName}" /></option>
                             </c:otherwise>
                        </c:choose>
                   </c:forEach>
              </select>
         </spring:bind>     
              </td>
         </tr>
         <tr>
              <td align="left" id="dateFrom">From Date
              <spring:bind path="bookactivityevent.userSuppliedActivity.dateFrom">
              <input type="text" name="dateFrom" value=""/>
              </spring:bind>
              <img
                   src="../design/cal.gif" width="16" height="16" border="0"
                   alt="Click Here to Pick up the date"></td>
         </tr>
         <tr>
              <td align="left" id="dateTo" class="hidden">To Date
              <spring:bind path="bookactivityevent.userSuppliedActivity.dateTo">
              <input type="text" name="dateTo" value=""/>
              </spring:bind>
              <img
                   src="../design/cal.gif" width="16" height="16" border="0"
                   alt="Click Here to Pick up the date"></td>
         </tr>
         <tr>
              <td align="left" colspan="2"><input type="submit" name="_target1" value="BookActivity"/></td>
                   <c:if test="${(bookactivityevent != null) && (not empty bookactivityevent.conflictBookings)}">
    <td align="left" colspan="2"><input type="submit" name="_target2" value="OverRideBookings"/></td>
    </c:if>
              <td align="left" colspan="2"><input type="button" name="Cancel"
                   value="Cancel" onClick="goHomePage();" /></td>
         </tr>
    </table>
    </form>
    </div>
    <hr class="noscreen"/>
    <div class="content-padding"></div>
    <script language="JavaScript">
         var cal1 = new calendar1(document.bookActivityController.elements['dateFrom']);
         cal1.year_scroll = true;
         cal1.time_comp = false;
    var cal2 = new calendar1(document.bookActivityController.elements['dateTo']);
         cal2.year_scroll = true;
         cal2.time_comp = false;
    </script></div>
    <!-- /content -->
    package com.uk.nhs.training.controller;
    import java.beans.PropertyEditorSupport;
    import java.text.ParseException;
    import java.text.SimpleDateFormat;
    import java.util.ArrayList;
    import java.util.Date;
    import java.util.HashMap;
    import java.util.List;
    import java.util.Map;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import javax.swing.text.html.HTMLDocument;
    import org.apache.commons.logging.Log;
    import org.apache.commons.logging.LogFactory;
    import org.springframework.util.StringUtils;
    import org.springframework.validation.BindException;
    import org.springframework.validation.Errors;
    import org.springframework.validation.ValidationUtils;
    import org.springframework.web.bind.ServletRequestDataBinder;
    import org.springframework.web.servlet.ModelAndView;
    import org.springframework.web.servlet.mvc.AbstractWizardFormController;
    import org.springframework.web.servlet.view.RedirectView;
    import com.uk.nhs.training.contractUtility.ContractHtmlReader;
    import com.uk.nhs.training.data.Activity;
    import com.uk.nhs.training.data.ActivityMatrix;
    import com.uk.nhs.training.data.BookActivityEvent;
    import com.uk.nhs.training.data.Booking;
    import com.uk.nhs.training.data.BookingDetails;
    import com.uk.nhs.training.data.Client;
    import com.uk.nhs.training.data.Course;
    import com.uk.nhs.training.data.Trainer;
    import com.uk.nhs.training.data.Venue;
    import com.uk.nhs.training.data.ActivityTimeConstants;
    import com.uk.nhs.training.service.ActivityMatrixService;
    import com.uk.nhs.training.service.ActivityService;
    import com.uk.nhs.training.service.BookingDetailsService;
    import com.uk.nhs.training.service.BookingService;
    import com.uk.nhs.training.service.ClientService;
    import com.uk.nhs.training.service.CourseService;
    import com.uk.nhs.training.service.TrainersService;
    import com.uk.nhs.training.service.VenueService;
    public class BookActivityController extends AbstractWizardFormController {
         protected final Log logger = LogFactory.getLog(getClass());
         private BookingService bookingFacade;
         private BookingDetailsService bookingDetailsFacade;
         private CourseService courseFacade;
         private VenueService venueFacade;
         private ClientService clientFacade;
         private ActivityMatrixService activityMatrixFacade;
         private ActivityService activityFacade;
         private TrainersService trainersFacade;
         private SimpleDateFormat dateFormat = new SimpleDateFormat("dd/MM/yyyy");
         public BookActivityController() {
              setCommandClass(BookActivityEvent.class);
         setCommandName("bookactivityevent");
         setBindOnNewForm(true);
         protected Object formBackingObject(HttpServletRequest request)
                   throws Exception {
              BookActivityEvent bookActivityEvent = new BookActivityEvent();
              ActivityMatrix activityMatrix = new ActivityMatrix();
              activityMatrix.setActivity(new Activity());
              activityMatrix.setTrainer(new Trainer());
              List<Booking> bookingList = new ArrayList<Booking>();
              bookActivityEvent.setUserSuppliedActivity(activityMatrix);
              bookActivityEvent.setConflictBookings(bookingList);
              return bookActivityEvent;
         public Map referenceData(HttpServletRequest request, Object command, Errors errors, int Page)
              List trainers = trainersFacade.loadTrainers();
         Map trainersActivitiesMap = new HashMap();
              trainersActivitiesMap.put("trainers", trainers);          
              return trainersActivitiesMap;
         protected ModelAndView processFinish(HttpServletRequest request,
                   HttpServletResponse response, Object command, BindException errors) {
              try {
                   ActivityMatrix activity = (ActivityMatrix) command;
                   activityMatrixFacade.saveActivityMatrix(activity);
                   logger.info("Activity is successfully saved for the trainer");
              } catch (Exception e) {
                   e.getClass();
                   e.printStackTrace();
              return new ModelAndView("bookSuccess");
         @Override
         protected void initBinder(HttpServletRequest request, ServletRequestDataBinder binder) throws Exception {
              dateFormat.setLenient(true);
              binder.registerCustomEditor(java.sql.Date.class, "dateFrom", new SqlDateEditor(true));
              binder.registerCustomEditor(java.sql.Date.class, "dateTo", new SqlDateEditor(false));
              binder.registerCustomEditor(java.sql.Date.class, null, new SqlDateEditor(true));
         protected ModelAndView handleInvalidSubmit(HttpServletRequest request,
                   HttpServletResponse response) throws Exception {
              return new ModelAndView("bookInvalidSubmit");
         @Override
         protected ModelAndView processCancel(HttpServletRequest request,
                   HttpServletResponse response, Object command, BindException errors)
                   throws Exception {
              return new ModelAndView(new RedirectView("welcome.htm"));
         @Override
         protected void onBindAndValidate(HttpServletRequest request,
                   Object command, BindException errors, int page) throws Exception {
              BookActivityEvent bookActivityEvent = (BookActivityEvent) command;
              System.out.println(" PAGE : " + page);
              try {
                   switch (page) {
                   case 0:
                        if (request.getParameter("_target1") != null) {
                             ActivityMatrix userActivityMatrix = bookActivityEvent.getUserSuppliedActivity();
                             buildActivityMatrix(request, bookActivityEvent);     
                             validateActivityMatrix(bookActivityEvent, errors);
                             if (errors.getErrorCount() == 0)
                                  Trainer trainer = (Trainer) trainersFacade.loadTrainersById(userActivityMatrix.getTrainer().getTrainerId());
                                  bookActivityEvent.getUserSuppliedActivity().setTrainer(trainer);
                                  Activity activity= (Activity) activityFacade.loadActivitiesById(userActivityMatrix.getActivity().getActivityId());
                                  bookActivityEvent.getUserSuppliedActivity().setActivity(activity);
                                  boolean activityExists = checkForExistingActivities(userActivityMatrix, errors);
                                  if(!activityExists)
                                  boolean bookingsExist =      checkForBookedCourses(request, bookActivityEvent, errors);
                                  if(bookingsExist)
                                       // inject an error code so that it can be used in GUI
                                       errors.rejectValue("dateFrom","invalid dates","Trainer has Bookings in conflict with the Supplied Activity Dates");
                                  else
                                       errors.rejectValue("dateFrom","Activity Dates supplied already exist");
                        break;
                   case 1:
                        if (request.getParameter("_target2") != null)
                             * Get the user supplied activitymatrix and try to get all the bookings which are in conflict for the trainer
                        List<Booking> conflictBookingsList = (List<Booking>)request.getSession().getAttribute("conflictBookingsList");
                        break;
                   default:
              } catch (Exception e) {
                   System.err.println("Exception :" + e.getMessage());
              super.onBindAndValidate(request, command, errors, page);
         * @param request
         * @param userActivity
         * @param bookActivityEvent TODO
         private ActivityMatrix buildActivityMatrix(HttpServletRequest request, BookActivityEvent bookActivityEvent) {
              ActivityMatrix userActivity = bookActivityEvent.getUserSuppliedActivity();
              userActivity.getTrainer().setTrainerId((String)(request.getParameter("trainerId")));
              userActivity.getActivity().setActivityId((String)(request.getParameter("activitySelect")));          
              String activityTime = (String)request.getParameter("activityTimeSelect");
              String activitySubType = (String)request.getParameter("activityTimeSubType");
              if("fullday".equals(activityTime))
                   userActivity.getActivity().setTime(ActivityTimeConstants.FULLDAY.toString());
              else if("moredays".equals(activityTime))
                   userActivity.getActivity().setTime(ActivityTimeConstants.MOREDAYS.toString());
              else if("halfday".equals(activityTime)&& "am".equals(activitySubType))
                   userActivity.getActivity().setTime(ActivityTimeConstants.AM.toString());               
              else if("halfday".equals(activityTime)&& "pm".equals(activitySubType))
                   userActivity.getActivity().setTime(ActivityTimeConstants.PM.toString());
              if(!("moredays".equals(activityTime)))
                   userActivity.setDateTo(bookActivityEvent.getDateFrom());
              userActivity.setDateFrom(bookActivityEvent.getDateFrom());
              bookActivityEvent.setUserSuppliedActivity(userActivity);
              return userActivity;
         * Create an empty Booking details for client and course...
         * @param booking
         private void setInitialBookingDetails(Booking booking, BindException errors) {
              if (booking.getBookingType().equals("Client-Based")) {
                   if (booking.getClient() == null
                             || booking.getClient().getClientId() == null) {
                        booking.setClient(new Client());
              } else if (booking.getBookingType().equals("Staff")) {
                   booking.setClient(null);
              if (booking.getBookingDetails() == null) {
                   List<BookingDetails> bkDetailsList = new ArrayList<BookingDetails>();
                   BookingDetails bkDetails = new BookingDetails();
                   bkDetails.setCourse(new Course());
                   bkDetailsList.add(bkDetails);
                   booking.setBookingDetails(bkDetailsList);
              } else {
                   List bkDetList = booking.getBookingDetails();
                   if (bkDetList.size() < 1
                             || (bkDetList.size() > 0 && !((bkDetList.get(0)) instanceof BookingDetails))) {
                        BookingDetails bkDetails = new BookingDetails();
                        bkDetails.setCourse(new Course());
                        bkDetList.add(0, bkDetails);
                        booking.setBookingDetails(bkDetList);
                   } else if (((BookingDetails) bkDetList.get(0)).getCourse() == null
                             || ((BookingDetails) bkDetList.get(0)).getCourse()
                                       .getCourseId() == null) {
                        ((BookingDetails) bkDetList.get(0)).setCourse(new Course());
         @Override
         protected void validatePage(Object command, Errors errors, int page,
                   boolean finish) {
              BookActivityEvent activityEvent = (BookActivityEvent) command;
              if (finish) {
              super.validatePage(command, errors, page);
         * Validate client
         * @param booking
         * @param err
         private boolean checkForExistingActivities(ActivityMatrix userSuppliedActivity, Errors err)
              boolean exist = false;          
              List<ActivityMatrix> trainerActivityMatrixList =      activityMatrixFacade.getActivityMatrixBetweenDateRange(userSuppliedActivity.getTrainer().getTrainerId(),
                        userSuppliedActivity.getDateFrom(), userSuppliedActivity.getDateTo());
              if(ActivityTimeConstants.MOREDAYS.equals(userSuppliedActivity.getActivity().getTime()))
                   //checkForDates(trainerActivityMatrixList,);
              else if(ActivityTimeConstants.FULLDAY.equals(userSuppliedActivity.getActivity().getTime()))
                   // checkForDates(trainerActivityMatrixList,);
              else if(ActivityTimeConstants.AM.equals(userSuppliedActivity.getActivity().getTime()) ||
                        ActivityTimeConstants.PM.equals(userSuppliedActivity.getActivity().getTime()))
                   // checkForDates(trainerActivityMatrixList,);
         return exist;          
              * Check for existing bookings for a trainer and sets them on event object
              * @param request request.
              * @param event event.
              * @param err err.
              * @return true- bookings exist else false.
    private boolean checkForBookedCourses(HttpServletRequest request, BookActivityEvent event, Errors err)
         List<Booking> conflictBookingsList =      bookingFacade.loadBookingsByTrainerIdDateRange(event.getUserSuppliedActivity().getTrainer().getTrainerId(),
                   event.getUserSuppliedActivity().getDateFrom(),
                   event.getUserSuppliedActivity().getDateTo());
    request.getSession().setAttribute("conflictBookingsList",conflictBookingsList);     
                   if(conflictBookingsList!=null && conflictBookingsList.size()!=0)
                   event.setConflictBookings(conflictBookingsList);
                   return true;
                   else
                        return false;
         * Validate client
         * @param booking
         * @param err
         private void validateActivityMatrix(final BookActivityEvent activity, Errors err) {
    //          ValidationUtils.rejectIfEmptyOrWhitespace(err, "trainer.trainerId",
    //                    "required.trainer.trainerId", "Valid trainer needs to be selected.");
    ////          ValidationUtils.rejectIfEmptyOrWhitespace(err, "activity.activityId",
    ////                    "required.activity.activityId", "Valid activity needs to be selected.");
    //          if (err.getErrorCount() < 1)
    //                    if (activity.getDateFrom() == null) {
    //                         err.rejectValue("dateFrom", "required.dateFrom",
    //                                   "Valid Activity Start Date is required");
    //                    try
    //                         if (activity.getDateFrom() != null && activity.getDateTo() != null
    //                                   && (activity.getDateTo().before(activity.getDateFrom())))
    //                              err.rejectValue("dateTo", "required.dateTo",
    //                                        "Activity End Date Should be after start date.");
    //                    } catch (Exception ex) {
    //                         err.rejectValue("dateFrom",
    //                                   "dateFrom",
    //                                   "Improper dates, please provide valid dates.");
         * Validate Trainer
         * @param booking
         * @param e
         private void validateTrainer(final Booking booking, Errors e) {
              ValidationUtils.rejectIfEmptyOrWhitespace(e,
                        "bookingDetails[0].startDate",
                        "required.bookingDetails[0].startDate",
                        "Valid Booking Details startDate required.");
              ValidationUtils.rejectIfEmptyOrWhitespace(e,
                        "bookingDetails[0].trainer.trainerId",
                        "required.bookingDetails[0].trainer.trainerId",
                        "Valid Booking Details Trainer required.");
              if (e.getErrorCount() < 1)
                   for (BookingDetails bd : booking.getBookingDetails()) {
                        if (bd.getStartDate() == null) {
                             e.rejectValue("startDate", "required.bbb0",
                                       "Valid Booking details Start Date is required");
                        try {
                             if (bd.getStartDate() != null && bd.getEndDate() != null
                                       && (bd.getEndDate().before(bd.getStartDate())))
                                  e.rejectValue("endDate", "required.bbb0",
                                            "End Date Should be after starting date.");
                        } catch (Exception ex) {
                             e.rejectValue("bookingDetails[0].startDate",
                                       "before.bookingDetails[0].startDate",
                                       "Improper dates, please provide valid dates.");
                        if (bd.getTrainer() != null) {
                             e.rejectValue("trianerId", "required.trianerId",
                                       "Valid Trainer details required.");
         public BookingService getBookingFacade() {
              return bookingFacade;
         public void setBookingFacade(BookingService bookingFacade) {
              this.bookingFacade = bookingFacade;
         public CourseService getCourseFacade() {
              return courseFacade;
         public void setCourseFacade(CourseService courseFacade) {
              this.courseFacade = courseFacade;
         public VenueService getVenueFacade() {
              return venueFacade;
         public void setVenueFacade(VenueService venueFacade) {
              this.venueFacade = venueFacade;
         public ClientService getClientFacade() {
              return clientFacade;
         public void setClientFacade(ClientService clientFacade) {
              this.clientFacade = clientFacade;
         public TrainersService getTrainersFacade() {
              return trainersFacade;
         public void setTrainersFacade(TrainersService trainersFacade) {
              this.trainersFacade = trainersFacade;
         * getter method for activityFacade.
         * @return Returns the activityFacade.
         public ActivityService getActivityFacade() {
              return activityFacade;
         * setter method for activityFacade.
         * @param activityFacade The activityFacade to set.
         public void setActivityFacade(ActivityService activityFacade) {
              this.activityFacade = activityFacade;
         * getter method for activityMatrixFacade.
         * @return Returns the activityMatrixFacade.
         public ActivityMatrixService getActivityMatrixFacade() {
              return activityMatrixFacade;
         * setter method for activityMatrixFacade.
         * @param activityMatrixFacade The activityMatrixFacade to set.
         public void setActivityMatrixFacade(ActivityMatrixService activityMatrixFacade) {
              this.activityMatrixFacade = activityMatrixFacade;
         * getter method for bookingDetailsFacade.
         * @return Returns the bookingDetailsFacade.
         public BookingDetailsService getBookingDetailsFacade() {
              return bookingDetailsFacade;
         * setter method for bookingDetailsFacade.
         * @param bookingDetailsFacade The bookingDetailsFacade to set.
         public void setBookingDetailsFacade(BookingDetailsService bookingDetailsFacade) {
              this.bookingDetailsFacade = bookingDetailsFacade;
         class SqlDateEditor extends PropertyEditorSupport {
              private boolean isRequired = false;
              SqlDateEditor(boolean isRequired) {
                   this.isRequired = isRequired;
              public void setAsText(String text) throws IllegalArgumentException {
                   java.util.Date d = null;
                   if (!this.isRequired && !StringUtils.hasText(text)) {
                        setValue(null);
                   else
                        try {
                             d = dateFormat.parse(text);
                             setValue(new java.sql.Date(d.getTime()));
                        } catch (ParseException ex) {
                             throw new IllegalArgumentException("Could not parse date: " + ex.getMessage());
              public String getAsText() {
                   Date value = (java.sql.Date)getValue();
                   if (value != null) {
                        java.util.Date d = new java.util.Date(value.getTime());
                        return dateFormat.fo

    This topic is hopeless. Too much unnecessary code. Unformatted code. No question. No requirements. No step-by-step explanation how to reproduce problem. No expectations. No unexpectations/errors.
    Please read this how to get better help.

  • How to call  New Page conditionally in Adobe Form

    Hi,
       Actually I want to develope a adobe form in which the employee training details will be come Page wise.
    Suppose there is 2 employee one has 90 and another has 60 training details.Suppose on  each page only 50 line items can be displayed.now for first employee in 1-st page 50 line item will come ,there afte in secon page 40 line item will be come.Now when second Employee details is coming it should not come in secon page .it should be come on third page.
         Can anybody help me regarding this matter

    Hi,
      I think there is no way to do this,  atleast for Adobe Designer v.7.0. But if you know XML or java scripting you can try that. I dont have much knowledge on it.
       However there is one way. Add dummy records in the table so that there  are mulitple of 50 records for each employee. I have also heard that adobe designer 7.1 has some extra options. Please try that if possible.
      Please let me know too if you find anything out. It will help me too..
    Regards,
    Susanta

  • SSI of HTML file using SpryAssets

    Hi,
    I've saved a navigation header for my website in a nav.html
    file. I'm trying to get another file, test.shtml, to use
    server-side includes to include nav.html into it.
    However, the nav.html file was built in DW using a Spry Menu
    Bar, which stores its files in a directory SpryAssets.
    I have the following statement located right after my
    <body> tag, so it appears at the top of the webpage:
    <!--#include file="nav.html" -->
    The design view in DW shows the nav.html file included, but
    menu-bar is expanded to look like normal text. The DW preview
    doesn't show the nav.html being there at all.
    Any ideas how to solve this? The nav.html file sits in the
    same directory as test.shtml, and looks great when I open nav.html
    alone.
    Thanks in advance. -Gary

    An Include is a code fragment, not an entire page.
    It should not contain <html> or <body> tags, just
    the snippet of code that
    you are replacing the Include directive with.
    As currently set up, your page code will look like this once
    the Include has
    been processed by the server and "included" in the main page
    code:
    This means duplicate doctypes, head tags etc etc which won't
    work.
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
    Transitional//EN"
    http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="
    http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html;
    charset=utf-8" />
    <title>Untitled Document</title>
    </head>
    <body>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
    Transitional//EN"
    http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="
    http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html;
    charset=utf-8" />
    <title>Untitled Document</title>
    <link href="StyleSheet.css" rel="stylesheet"
    type="text/css" />
    <style type="text/css">
    <!--
    -->
    </style>
    <script src="SpryAssets/SpryMenuBar.js"
    type="text/javascript"></script>
    <link href="SpryAssets/SpryMenuBarHorizontal.css"
    rel="stylesheet"
    type="text/css" />
    <style type="text/css">
    <!--
    .style2 {
    font-size: 16px;
    font-weight: bold;
    color: #336600;
    margin-top: 30px;
    margin-bottom: -12px;
    .style3 {
    color: #336600;
    font-weight: bold;
    .style6 {
    font-size: 14px;
    font-family: Arial, Helvetica, sans-serif;
    font-weight: bold;
    vertical-align: middle;
    color: #6633FF;
    .style7 {
    font-size: 14px;
    font-family: Arial, Helvetica, sans-serif;
    position: static;
    height: 0px;
    top: 10px;
    margin-bottom: -12px;
    font-weight: bold;
    color: #333333;
    .style8 {
    color: #CC0000;
    font-weight: bold;
    .style10 {
    font-family: Arial, Helvetica, sans-serif;
    position: static;
    height: 0px;
    top: 10px;
    margin-bottom: -12px;
    font-weight: bold;
    color: #333333;
    font-size: 13px;
    .ucscheader {
    font-family: Arial, Helvetica, sans-serif;
    font-size: 13px;
    font-weight: bold;
    margin-bottom: -10px;
    text-align: center;
    .spacer1 {
    font-family: Arial, Helvetica, sans-serif;
    font-size: 12px;
    margin-bottom: 10px;
    -->
    </style>
    </head>
    <body>
    <table width="750" border="0" align="center"
    cellpadding="0"
    cellspacing="0"
    bgcolor="#669900">
    <!--DWLayoutTable-->
    <tr>
    <td width="159" height="7"></td>
    <td width="104"></td>
    <td width="327"></td>
    <td width="10"></td>
    <td width="150"></td>
    </tr>
    <tr>
    <td height="60" colspan="2" valign="top"><img
    src="Images/jittertime_icon_logo.jpg" alt="JitterTime Logo"
    width="222"
    height="53" hspace="20" vspace="3" /></td>
    <td> </td>
    <td> </td>
    <td valign="top"><img
    src="Images/allabouttimingjitter.jpg" alt="Timing
    Jitter Logo" width="129" height="56" hspace="0" vspace="2"
    align="top"
    /></td>
    </tr>
    <tr>
    <td height="6"></td>
    <td></td>
    <td></td>
    <td></td>
    <td></td>
    </tr>
    <tr>
    <td height="24" valign="top" bgcolor="#336600"
    class="HomeText">Home</td>
    <td colspan="2" valign="top" bgcolor="#336600"><ul
    id="NavMenu2"
    class="MenuBarHorizontal">
    <a class="MenuBarItemSubmenu" href="#">Training</a>
    <a href="#">Training Details</a></li>
    <a href="#">Seminar Overview</a></li>
    </li>
    <a href="#"
    class="MenuBarItemSubmenu">Resources</a>
    <a href="#">Rates &amp;
    Frequencies</a></li>
    <a href="#">Phase Jitter Calculator</a></li>
    <a href="#">Links</a></li>
    </li>
    <a class="MenuBarItemSubmenu" href="#">Articles</a>
    <a href="#">Convert dBc/Hz to ps</a> </li>
    </li>
    <a href="#" class="MenuBarItemSubmenu">Company</a>
    <a href="#">Biography</a></li>
    <a href="#">Contact</a></li>
    <a href="#">Policies</a></li>
    </li>
    </td>
    <td colspan="2" valign="top" bgcolor="#336600"
    class="HomeText"><div
    align="right" class="SiteMap">Site
    Map</div></td>
    </tr>
    </table>
    <script type="text/javascript">
    <!--
    var MenuBar1 = new Spry.Widget.MenuBar("NavMenu2",
    {imgDown:"SpryAssets/SpryMenuBarDownHover.gif",
    imgRight:"SpryAssets/SpryMenuBarRightHover.gif"});
    //-->
    </script>
    </body>
    </html>
    <p>this is a test</p>
    </body>
    </html>
    Regards
    John Waller

  • Can any one tell me whats the problem with controller

    package com.uk.nhs.training.controller;
    import java.beans.PropertyEditorSupport;
    import java.text.ParseException;
    import java.text.SimpleDateFormat;
    import java.util.ArrayList;
    import java.util.Date;
    import java.util.List;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import javax.swing.text.html.HTMLDocument;
    import org.apache.commons.logging.Log;
    import org.apache.commons.logging.LogFactory;
    import org.springframework.util.StringUtils;
    import org.springframework.validation.BindException;
    import org.springframework.validation.Errors;
    import org.springframework.validation.ValidationUtils;
    import org.springframework.web.bind.ServletRequestDataBinder;
    import org.springframework.web.servlet.ModelAndView;
    import org.springframework.web.servlet.mvc.AbstractWizardFormController;
    import org.springframework.web.servlet.view.RedirectView;
    import com.uk.nhs.training.contractUtility.ContractHtmlReader;
    import com.uk.nhs.training.data.Booking;
    import com.uk.nhs.training.data.BookingDetails;
    import com.uk.nhs.training.data.Client;
    import com.uk.nhs.training.data.Course;
    import com.uk.nhs.training.data.Trainer;
    import com.uk.nhs.training.data.Venue;
    import com.uk.nhs.training.service.BookingService;
    import com.uk.nhs.training.service.ClientService;
    import com.uk.nhs.training.service.CourseService;
    import com.uk.nhs.training.service.TrainersService;
    import com.uk.nhs.training.service.VenueService;
    public class BookingController extends AbstractWizardFormController {
         protected final Log logger = LogFactory.getLog(getClass());
         private BookingService bookingFacade;
         private CourseService courseFacade;
         private VenueService venueFacade;
         private ClientService clientFacade;
         private TrainersService trainersFacade;
         public static final String STAFF = "Staff";
         public static final String CLIENT_BASED = "Client-Based";
         private SimpleDateFormat dateFormat = new SimpleDateFormat("dd MMMMMMMM yyyy");
         public BookingController() {
              setPages(new String[] { "booking", "book1", "book2", "book3", "book4",
                        "book5", "book6", "book7" });
              setCommandName("booking");
              setAllowDirtyForward(true);
         protected Object formBackingObject(HttpServletRequest request)
                   throws Exception {
              Booking booking = new Booking();
              return booking;
         protected ModelAndView processFinish(HttpServletRequest request,
                   HttpServletResponse response, Object command, BindException errors) {
              try {
                   Booking booking = (Booking) command;
                   setBookingFinalDetails(booking);
                   logger.info("Boooking Form data sent successfully");
              } catch (Exception e) {
                   e.getClass();
                   e.printStackTrace();
              return new ModelAndView("bookSuccess");
         @Override
         protected void initBinder(HttpServletRequest request, ServletRequestDataBinder binder) throws Exception {
              dateFormat.setLenient(false);
              binder.registerCustomEditor(java.sql.Date.class, null, new SqlDateEditor(true));
         private void setBookingFinalDetails(Booking booking) throws Exception {
              booking.setCreateDate(new java.sql.Date(System.currentTimeMillis()));
              booking.setStatus("In Progress");
              bookingFacade.saveBooking(booking);
         protected ModelAndView handleInvalidSubmit(HttpServletRequest request,
                   HttpServletResponse response) throws Exception {
              return new ModelAndView("bookInvalidSubmit");
         @Override
         protected ModelAndView processCancel(HttpServletRequest request,
                   HttpServletResponse response, Object command, BindException errors)
                   throws Exception {
              return new ModelAndView(new RedirectView("welcome.htm"));
         @Override
         protected void onBindAndValidate(HttpServletRequest request,
                   Object command, BindException errors, int page) throws Exception {
              Booking booking = (Booking) command;
              System.out.println(" PAGE : " + page);
              try {
                   switch (page) {
                   case 0:
                        if (request.getParameter("_target1") != null) {
                             ValidationUtils.rejectIfEmptyOrWhitespace(errors,
                                       "bookingType", "required.bookingType",
                                       "Booking type is required");
                             String bookingType = request.getParameter("bookingType");
                             booking.setBookingType(bookingType);
                             setInitialBookingDetails(booking, errors);
                        break;
                   case 1:
                        if (request.getParameter("_target2") != null) {
                             if (booking.getBookingType().equals(STAFF)) {
                                  booking.setClient(null);
                             if (booking.getBookingType().equals(CLIENT_BASED)) {
                                  validateClient(booking, errors);
                                  if (errors.getErrorCount() == 0) {
                                       Client c = (Client) clientFacade
                                                 .loadClientById(booking.getClient()
                                                           .getClientId());
                                       booking.setClient(c);
                             int theBookingDetailsLength = Integer.parseInt(request
                                       .getParameter("qtyBox"));
                             String courseId = request.getParameter("bookingDetails");
                             if (courseId != null && courseId.trim().length() > 0) {
                                  List<BookingDetails> bookDetails = new ArrayList<BookingDetails>();
                                  for (int i = 0; i < theBookingDetailsLength; i++) {
                                       BookingDetails bk = new BookingDetails();
                                       bk.getCourse().setCourseId(courseId);
                                       Course c = (Course) courseFacade
                                                 .getCourseById(courseId);
                                       bk.setCourse(c);
                                       // Add empty trainer..
                                       bk.setTrainer(new Trainer());
                                       bookDetails.add(bk);
                                       booking.setBookingDetails(bookDetails);
                             } else {
                                  validateCourse(booking, errors);
                        break;
                   case 2:
                        if (request.getParameter("_target1") != null) {
                             setInitialBookingDetails(booking, errors);
                        if (request.getParameter("_target3") != null) {
                             int i=0;
                             for (BookingDetails bd : booking.getBookingDetails()) {
                                  if (bd != null && bd.getTrainer() != null) {
                                       String trainerId = bd.getTrainer().getTrainerId();
                                       Trainer trainer = trainersFacade
                                                 .loadTrainersById(trainerId);
                                       if (trainer != null ) {
                                            bd.setTrainer(trainer);
                                            // add empty venue;
                                            bd.setVenue(new Venue());
                                       } else {
                                            validateTrainer(booking, errors);
                                  i++;
                        break;
                   case 3:
                        if (request.getParameter("_target4") != null) {
                             for (BookingDetails bd : booking.getBookingDetails()) {
                                  if (bd != null && bd.getVenue() != null) {
                                       ValidationUtils.rejectIfEmptyOrWhitespace(errors,
                                                 "bookingDetails[0].venue.venueId",
                                                 "required.venue.venueId",
                                                 "Venue Details required.");
                                       String venueId = bd.getVenue().getVenueId();
                                       List<Venue> vList = venueFacade
                                                 .loadVenuesByKeyword(venueId);
                                       if (vList != null && vList.size() > 0) {
                                            bd.setVenue(vList.get(0));
                                  } else {
                                       errors.rejectValue(
                                                 "bookingDetails[0].venue.venueName",
                                                 "required.venue.venueName",
                                                 "Valid Venue Details required.");
                        break;
                   case 4:
                        break;
                   case 5:
                        if (request.getParameter("_target7") != null) {
                             setBookingFinalDetails(booking);
                             ContractHtmlReader reader = new ContractHtmlReader(booking);
                             HTMLDocument doc = reader.getHTMLDoc();
                             reader.writeHTMLCode(doc);
                        break;
                   default:
              } catch (Exception e) {
                   System.err.println("Exception :" + e.getMessage());
              super.onBindAndValidate(request, command, errors, page);
         * Create an empty Booking details for client and course...
         * @param booking
         private void setInitialBookingDetails(Booking booking, BindException errors) {
              if (booking.getBookingType().equals("Client-Based")) {
                   if (booking.getClient() == null
                             || booking.getClient().getClientId() == null) {
                        booking.setClient(new Client());
              } else if (booking.getBookingType().equals("Staff")) {
                   booking.setClient(null);
              if (booking.getBookingDetails() == null) {
                   List<BookingDetails> bkDetailsList = new ArrayList<BookingDetails>();
                   BookingDetails bkDetails = new BookingDetails();
                   bkDetails.setCourse(new Course());
                   bkDetailsList.add(bkDetails);
                   booking.setBookingDetails(bkDetailsList);
              } else {
                   List bkDetList = booking.getBookingDetails();
                   if (bkDetList.size() < 1
                             || (bkDetList.size() > 0 && !((bkDetList.get(0)) instanceof BookingDetails))) {
                        BookingDetails bkDetails = new BookingDetails();
                        bkDetails.setCourse(new Course());
                        bkDetList.add(0, bkDetails);
                        booking.setBookingDetails(bkDetList);
                   } else if (((BookingDetails) bkDetList.get(0)).getCourse() == null
                             || ((BookingDetails) bkDetList.get(0)).getCourse()
                                       .getCourseId() == null) {
                        ((BookingDetails) bkDetList.get(0)).setCourse(new Course());
         @Override
         protected void validatePage(Object command, Errors errors, int page,
                   boolean finish) {
              Booking booking = (Booking) command;
              if (finish) {
                   for (BookingDetails bd : booking.getBookingDetails()) {
                        if (bd != null && bd.getRate() != null) {
                             try {
                                  float rate = bd.getRate();
                             } catch (NumberFormatException e) {
                                  errors.reject("invalid.bookingDetails.rate",
                                            "(try \"250.00\")!");
                             } catch (Exception e) {
                                  errors.rejectValue("bookingDetails.rate",
                                            "error.bookingDetails.rate",
                                            "Enter valid Rate.");
                   booking
                             .setCreateDate(new java.sql.Date(System.currentTimeMillis()));
              super.validatePage(command, errors, page);
         * Validate client
         * @param booking
         * @param err
         private void validateClient(final Booking booking, Errors err) {
              ValidationUtils.rejectIfEmptyOrWhitespace(err, "client.clientId",
                        "required.client.clientId", "Valid client details required.");
         * Validate Course
         * @param booking
         * @param err
         private void validateCourse(final Booking booking, Errors err) {
              if (booking.getBookingDetails() == null
                        || booking.getBookingDetails().size() < 1) {
                   err.rejectValue("bookingDetails", "error.bookingDetails",
                             "Course Booking Details required.");
              } else {
                   List bdList = booking.getBookingDetails();
                   for (int i = 0; i < bdList.size(); i++) {
                        if (!(bdList.get(i) instanceof BookingDetails)) {
                             err.rejectValue("bookingDetails", "error.bookingDetails",
                                       "Valid Course Booking Details required.");
                        } else {
                             BookingDetails bd = (BookingDetails) (bdList.get(i));
                             if (bd.getCourse() == null
                                       || bd.getCourse().getCourseId() == null)
                                  err.rejectValue("bookingDetails",
                                            "error.bookingDetails.course.courseId",
                                            "Valid Course Details required.");
         * Validate Trainer
         * @param booking
         * @param e
         private void validateTrainer(final Booking booking, Errors e) {
              ValidationUtils.rejectIfEmptyOrWhitespace(e,
                        "bookingDetails[0].startDate",
                        "required.bookingDetails[0].startDate",
                        "Valid Booking Details startDate required.");
              ValidationUtils.rejectIfEmptyOrWhitespace(e,
                        "bookingDetails[0].trainer.trainerId",
                        "required.bookingDetails[0].trainer.trainerId",
                        "Valid Booking Details Trainer required.");
              if (e.getErrorCount() < 1)
                   for (BookingDetails bd : booking.getBookingDetails()) {
                        if (bd.getStartDate() == null) {
                             e.rejectValue("startDate", "required.bbb0",
                                       "Valid Booking details Start Date is required");
                        try {
                             if (bd.getStartDate() != null && bd.getEndDate() != null
                                       && (bd.getEndDate().before(bd.getStartDate())))
                                  e.rejectValue("endDate", "required.bbb0",
                                            "End Date Should be after starting date.");
                        } catch (Exception ex) {
                             e.rejectValue("bookingDetails[0].startDate",
                                       "before.bookingDetails[0].startDate",
                                       "Improper dates, please provide valid dates.");
                        if (bd.getTrainer() != null) {
                             e.rejectValue("trianerId", "required.trianerId",
                                       "Valid Trainer details required.");
         public BookingService getBookingFacade() {
              return bookingFacade;
         public void setBookingFacade(BookingService bookingFacade) {
              this.bookingFacade = bookingFacade;
         public CourseService getCourseFacade() {
              return courseFacade;
         public void setCourseFacade(CourseService courseFacade) {
              this.courseFacade = courseFacade;
         public VenueService getVenueFacade() {
              return venueFacade;
         public void setVenueFacade(VenueService venueFacade) {
              this.venueFacade = venueFacade;
         public ClientService getClientFacade() {
              return clientFacade;
         public void setClientFacade(ClientService clientFacade) {
              this.clientFacade = clientFacade;
         public TrainersService getTrainersFacade() {
              return trainersFacade;
         public void setTrainersFacade(TrainersService trainersFacade) {
              this.trainersFacade = trainersFacade;
         class SqlDateEditor extends PropertyEditorSupport
              private boolean isRequired = false;
              SqlDateEditor(boolean isRequired) {
                   this.isRequired = isRequired;
              public void setAsText(String text) throws IllegalArgumentException {
                   java.util.Date d = null;
                   if (!this.isRequired && !StringUtils.hasText(text)) {
                        setValue(null);
                   else
                        try {
                             d = dateFormat.parse(text);
                             setValue(new java.sql.Date(d.getTime()));
                        } catch (ParseException ex) {
                             throw new IllegalArgumentException("Could not parse date: " + ex.getMessage());
              public String getAsText() {
                   Date value = (java.sql.Date)getValue();
                   if (value != null) {
                        java.util.Date d = new java.util.Date(value.getTime());
                        return dateFormat.format(d);
                   else {
                        return "";
    }

    <!-- Content -->
    <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core"%>
    <%@ taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt"%>
    <%@ taglib uri="http://www.springframework.org/tags" prefix="spring"%>
    <%@ page isELIgnored="false"%>
    <SCRIPT language="JavaScript" type="text/javascript">
         function checkClientKeycode(kCode){
              if (kCode==27){
                   hideSelectClient();
              else if (kCode==13){
                   setClient();
         function changeClientFocus(){
              if (document.getElementById("clientSelect").style.visibility=="visible"){
                   document.getElementById("clientSelect").style.height=100;
                   document.getElementById("clientSelect").focus();
         function hideSelectClient(){ 
              var clSelect = document.getElementById("clientSelect");
              clSelect.options.length=0;
         clSelect.style.visibility="hidden";
         clSelect.style.height=10;
    function setClient(){
              var clSelect = document.getElementById("clientSelect");
         document.getElementById("clientId").value=clSelect.value;
         document.getElementById("clientname").value=clSelect.options[clSelect.selectedIndex].text;
              clSelect.options.length=0;
         clSelect.style.visibility="hidden";
         clSelect.style.height=10;
    function checkCourseKeycode(kCode){
              if (kCode==27){
                   hideSelectCourse();
              else if (kCode==13){
                   setCourse();
         function changeCourseFocus(){
              if (document.getElementById("courseSelect").style.visibility=="visible"){     
                   document.getElementById("courseSelect").style.height=100;
                   document.getElementById("courseSelect").focus();
         function hideSelectCourse(){ 
              var coSelect=document.getElementById("courseSelect")
              coSelect.options.length=0;
         coSelect.style.visibility="hidden";
         coSelect.style.height=10;
    function setCourse(){
         var coSelect=document.getElementById("courseSelect")
         document.getElementById("bookingDetails").value=coSelect.value;
         document.getElementById("coursename").value=coSelect.options[coSelect.selectedIndex].text;
         coSelect.options.length=0;
         coSelect.style.visibility="hidden";
              coSelect.style.height=10;
         function addClient()
              window.open("<%=request.getContextPath()%>/secure/clientpopup.htm","clientwindow","location=0,status=1,scrollbars=1,resizable=1 left=200 width=700,height=600");
         function addCourse()
              window.open("<%=request.getContextPath()%>/secure/coursepopup.htm","coursewindow","location=0,status=1,scrollbars=1,resizable=1 left=200 width=450,height=400");
         function addTrainer()
              window.open("<%=request.getContextPath()%>/secure/trainerpopup.htm","trainerwindow","location=0,status=1,scrollbars=1,resizable=1 left=400 width=600,height=400");
         //------------------------------------------Course AJAX List Start-----------------------------------------------------//
         function getCourses()
              flag="wait";
         var theKeyword=document.getElementById("coursename").value;
         url="ajaxList.htm?actionType=courses&keyword="+theKeyword;
         what = "setCourses(req.responseXML)";
         //row_id=rowid;
         doCallback(null);
         function setCourses(theXmlResponse)
              //start filling the Venues Select boxes now
              if(theXmlResponse != null)
                   var coursesBox=document.getElementById("courseSelect");
                   coursesBox.options.length=0;
                   var coursesElementsLength=theXmlResponse.getElementsByTagName('course').length;
                   var y;
                   if (coursesElementsLength<20) {
                        y=coursesElementsLength;
                   else {
                        y=20;
                   coursesBox.size=y;
                   if (y==1) {
                        coursesBox.size=2;
                   var coursesElementsArray=theXmlResponse.getElementsByTagName('course');
                   for(x = 0; x < y; x++) {
                        coursesBox.options[coursesBox.options.length] = new Option(coursesElementsArray[x].firstChild.text, coursesElementsArray[x].lastChild.text);
                   if (y>0) {
                        coursesBox.style.visibility="visible";
                        coursesBox.style.height=100;
              flag="release";
    //------------------------------------------ Course AJAX List End-----------------------------------------------------//
    //------------------------------------------ Client AJAX List Start-----------------------------------------------------//
         function getClients()
              flag="wait";
              var theKeyword=document.getElementById("clientname").value;
         url="ajaxList.htm?actionType=clients&keyword="+theKeyword;
         what = "setClients(req.responseXML)";
         //row_id=rowid;
         doCallback(null);
         function setClients(theXmlResponse)
              if(theXmlResponse != null) {
                   var clientsBox=document.getElementById("clientSelect");
                   clientsBox.options.length=0;
                   var clientsElementsLength=theXmlResponse.getElementsByTagName('client').length;
                   var y;
                   if (clientsElementsLength<20) {
                        y=clientsElementsLength;
                   else {
                        y=20;
                   clientsBox.size=y;
                   if (y==1) {
                        clientsBox.size=2;
                   var clientsElementsArray=theXmlResponse.getElementsByTagName('client');
                   for(x = 0; x < y; x++) {
                        clientsBox.options[clientsBox.options.length] = new Option();
                   if (y>0) {
                        clientsBox.style.visibility="visible";
                        clientsBox.style.height=100;                    
              flag="release";
    //------------------------------------------Client AJAX List End-----------------------------------------------------//
    </script>
    <div id="content"><!-- Top story -->
    <div id="topstory" class="box">
    <div id="topstory-img"></div>
    <!-- /topstory-img -->
    <div id="topstory-desc">
    <div id="topstory-title"><strong>BOOK COURSE (CONT.)</strong></div>
    <!-- /topstory-title -->
    <div id="topstory-desc-in"></div>
    <!-- /topstory-desc-in --></div>
    <!-- /topstory-desc --></div>
    <!-- /topstory -->
    <div id="bodycontent"><c:choose>
         <c:when test='${booking.bookingType eq "Staff"}'>
              <table align="left" width="50%" border=0>
                   <tr>
                        <td colspan="4" align="center"><strong>Choose Course</strong>
                        <form name="BookType1"
                             action="<c:url value="/secure/bookCourse.htm"/>" method="post">
                        </td>
                   </tr>
                   </c:when>
                   <c:when test='${booking.bookingType eq "Client-Based"}'>
                        <table align="left" width="50%" border=0>
                             <tr>
                                  <td colspan="4" align="center"><strong>Choose Client and Course</strong>
                                  </p>
                                  </td>
                             </tr>
                             <form name="BookType1"
                                  action="<c:url value="/secure/bookCourse.htm"/>" method="post">
                             <tr>
                                  <td colspan="4" align="left">Please pick client from the list:</td>
                             </tr>
                             <tr>
                                  <td colspan="4" align="left">
                                  <c:if test='${empty booking.client || empty booking.client.clientId}'>
                                  <spring:bind path="booking.client.clientId">
                                       <input name="<c:out value='${status.expression}'/>" type="hidden" id="clientId" value=""/>
                                  </spring:bind>
                                  <input size="20" type="text" id="clientname" value=""
                                  onkeyup="javascript:getClients();changeClientFocus();"
                                  ondblclick="javascript:getClients();changeClientFocus();" />
                                  </c:if>
                                  <c:if test='${not empty booking.client.clientId}'>
                                  <spring:bind path="booking.client.clientId">
                                       <input name="<c:out value='${status.expression}'/>" type="hidden" id="clientId" value="<c:out value='${status.value}'/>"/>
                                  </spring:bind>
                                  <input size="20" type="text" id="clientname" name="clientname"
                                  value="<c:out value='${booking.client.orgName}'/> - <c:out value='${booking.client.type}'/>"
                                  onkeyup="javascript:getClients();changeClientFocus();"
                                  ondblclick="javascript:getClients();changeClientFocus();" />
                                  </c:if>
                                  <div><select id="clientSelect"
                                       style="width:266px;visibility:hidden"
                                       onclick="javascript:setClient();"
                                       onkeyup="javascript:checkClientKeycode(event.keyCode);">
                                  </select></div>
                                  </td>
                             </tr>
                             </c:when>
                             <c:otherwise>
                                  <table align="left" width="50%" border=0>
                                       <tr>
                                            <td colspan="4" align="center"><strong>Choose Course</strong>
                                            <form name="BookType1"
                                                 action="<c:url value="/secure/bookCourse.htm"/>" method="post">
                                            </td>
                                       </tr>
                                       </c:otherwise>
                                       </c:choose>
                                       <tr>
                                            <td colspan="4" align="left">Pick Course from list:</td>
                                       </tr>
                                       <tr>
                                            <td colspan="4" align="left">
                                            <input type="hidden" name="clientAndCourse" value="yes" />
                                            <input name="bookingDetails" type="hidden"
                                                 <c:if test="${(not empty booking.bookingDetails[0])}"> value="<c:out
                                                 value="${booking.bookingDetails[0].course.courseId}"/>"</c:if> />
                                            <spring:bind path="booking.bookingDetails[0].course.courseId">
                                            <input size="20" type="text" id="coursename" name="coursename"
                                            <c:if test="${(not empty booking.bookingDetails[0])}"> value="<c:out
                                                 value="${booking.bookingDetails[0].course.courseTitle}"/>"</c:if>
                                                 onkeyup="javascript:getCourses();changeCourseFocus();"
                                                 ondblclick="javascript:getCourses();changeCourseFocus();" />
                                            </spring:bind>
                                            <div><select id="courseSelect"
                                                 style="width:266px;visibility:hidden"
                                                 onclick="javascript:setCourse();"
                                                 onkeyup="javascript:checkCourseKeycode(event.keyCode);"></select></div>
                                            </td>
                                       </tr>
                                       <tr>
                                            <td colspan="4" align="left">Quantity:   <select
                                                 name="qtyBox" size="1">
                                                 <c:forEach var="x" begin="1" end="10">
                                                      <option value='<c:out value="${x}"/>'><c:out value="${x}" /></option>
                                                 </c:forEach>
                                            </select></td>
                                       </tr>
                                       <tr>
                                            <td colspan="4" align="left"></td>
                                       </tr>
                                       <tr>
                                            <td>
                                            <p><!-- input type="submit" name="_finish" value="Save"/ -->  
                                            <input type="submit" name="_target0" value="Previous" />  
                                            <input type="submit" name="_target2" value="Next" />  
                                            <input type="submit" name="_cancel" value="Cancel" />
                                            </td>
                                            <td><input type="button" value="Add Client"
                                                 onclick="javascript:addClient();" /></td>
                                            <td><input type="button" value="Add Course"
                                                 onclick="javascript:addCourse();" /></td>
                                            <td><input type="button" value="Add Trainer"
                                                 onclick="javascript:addTrainer();" /></td>
                                       </tr>
                                  </table>
                                  </form>
                                  </div>
                                  <hr class="noscreen" />
                                  <div class="content-padding"></div>
                                  <!-- /content-padding -->
                                  </div>
                                  <!-- /content -->

  • ALV using Reuse_Alv_grid_display

    Hi Abapers,
    I have designed one ALV for displaying training details. There can be max 4 trainers for every course..
    1. Trainer1
    2. Trainer2
    3. Trainer3
    4. Trainer4
    My requirement is that Trainer2 should be displayed only if there is a second trainer for any of the courses being displayed. I have written logic for this by setting no_out = 'X' when there is no value for trainer2 by looping my internal table..
    It's working fine when there are no default layouts being set up.
    But it's not working when a default layout is existing with 4 trainers.
    Please help me to achieve this functionality even when there is layout..
    My code: Set no_out = 'X' based on flags being used for trainers.
      LOOP AT tb_data INTO wa_data.
        l_count = l_count + 1.
    *--Trainer 1 Details
        IF l_count EQ 1.
          alv_itab-reftyp    = wa_data-reftyp.
          alv_itab-refid     = wa_data-refid.
          alv_itab-refshort  = wa_data-refshort.
          alv_itab-refname   = wa_data-refname.
    *--Trainer 2 Details
        ELSEIF l_count EQ 2.
          alv_itab-reftyp2    = wa_data-reftyp.
          alv_itab-refid2     = wa_data-refid.
          alv_itab-refshort2  = wa_data-refshort.
          alv_itab-refname2   = wa_data-refname.
          g_flag2 = c_x.
    *--Trainer 3 Details
        ELSEIF l_count EQ 3.
          alv_itab-reftyp3    = wa_data-reftyp.
          alv_itab-refid3     = wa_data-refid.
          alv_itab-refshort3  = wa_data-refshort.
          alv_itab-refname3   = wa_data-refname.
          g_flag3 = c_x.
    *--Trainer 4 Details
        ELSEIF l_count EQ 4.
          alv_itab-reftyp4    = wa_data-reftyp.
          alv_itab-refid4     = wa_data-refid.
          alv_itab-refshort4  = wa_data-refshort.
          alv_itab-refname4   = wa_data-refname.
          g_flag4 = c_x.
        ELSE.
          EXIT.
        ENDIF.
        CLEAR wa_data.
      ENDLOOP.
    Many Thanks in Advance!!

    Saving the Layout can work only in the program level. so i will tell you how to do that.
    First Save a Variant using TECH = ' '.
    and second time save a variant using TECH = 'X'  both will be availbe for you , which ever you want you can use in the output.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
          i_callback_program = sy-repid
          it_fieldcat        = it_fieldcat
          it_sort            = it_sort
          is_layout          = layout   "<--pass this too
          i_save             = 'X'          "<----pass this, this enable Save option
        TABLES
          t_outtab           = it_data
        EXCEPTIONS
          program_error      = 1.
    Now you can see the Save layout option in the ALV output.

  • Need Information on Optio software

    Hello everybody,
    Can you please provide me information on Optio Software if you are aware of it.
    Following are the key points that i am interested in,
    1. What is the use of Optio.
    2. Is there any training available for the same?
    3. If so i would like to know the training details and the course fees.
    Any document or a URL that provides all information would be really helpful.
    Thanks in advance.
    Regards,
    Raj Papdeja

    Hi,
    Thanks for the information. Do you have any idea whether we can get the training on Optio Software? Does any organization provide training on Optio??
    Thanks in advance !!
    Regards,
    Raj Papdeja

Maybe you are looking for

  • Creating a service item

    I'm in the middle of creating a new service and am having a problem with service items. I have designed the service item, created the dictionary added some fields, created an active form and finally created a service. In the plan for the service my f

  • Can't Drag and Drop from Bridge/Folders anymore. Trashing Preferences didn't work

    My Indesign CS4 is acting up. I can no longer drag and drop from Bridge into my layouts, nor does it work from my PC folders to the layout. I tried accessing the two  preferences folder on my Vista as suggested here: http://indesignsecrets.com/rebuil

  • Airplay: I don't have the airplay option at all.

    Why don't I have the airplay option. As per the user manual, I need to start the video or music and tap and choose the AirPlay device. But I don't get that button. Is there any application that I need to install? I even tried searching for airplay in

  • Can I adjust size of the photos on front page of the photo album template?

    When I am working on a Photo Album page, how can I make the "front page" photos larger? I am talking about the photos arranged in rows, not the photos that show in the slide show carousel. Is it a set size in the Photo Album template or is it a conse

  • Finder search opening in new window and sidebar gone

    Hi, just wondering if anyone could shed some light on this cause I'm quite lost. First of when hitting Command-F in the Finder it opens up in a new window, I'm pretty sure it didn't do this before. Opening folders does not open in new windows. Using