Does the date entered fall on a Saturday or Sunday?

Has anyone had to verify the date, entered by the caller, doesn't fall on a Saturday or Sunday? If so how did you do it? We are running UCCX 5.0(2) premium edition. Thanks.

Jump into the Expression Editor and create a GregorianCalendar class. It will tell you all these things, and more. It will deal with leap years and other tricky little things.
Now if you don't know how to use the Expression Editor, please read the manual. It's a bit tricky to describe, but you can actually double-click on where you see the class and type your own class there, and it will make one for you, and then you can use the methods on that class that the editor can see through reflection.
GregorianCalendar is a standard Java class in java.util.* so you will be able to use it.
You basically take their date entry, make a GregorianCalendar, and then check to see if it's the weekend.
NOTE: Month is 0-11, so subtract 1 from what they entered!!! Tricks people up.
GregorianCalendar gc = new GregorianCalendar(int year, int month, int dayOfMonth)
if (gc.get(Calendar.DAY_OF_WEEK) == Calendar.SATURDAY ||
    gc.get(Calendar.DAY_OF_WEEK) == Calendar.SUNDAY)
// off you go
Regards,
Geoff

Similar Messages

  • "The Data entered is wrong, so it will revert to the previos value" error in Smartview

    A user is receiving the error "the data entered is wrong, so it will revert to the previous value" when working in excel and having a smart-view adhoc open. it doesn't happen all the time (it is not predictable) but it does happen regularly (3-5 times per week). If the user disconnects all connections in smartview or restarts excel, it temporarily fixes the issue.
    I have seen this error references in two other threads, not no answer. Can someone pelase help?

    Hello sher,
    You must be using certain formulas in other sheets which will connect back to your retrieval sheet and get the refreshed data from there.
    Try and use "Paste Values" to the formula columns to which you have once retrieved values from adhoc retrieval sheets. Hopefully this error should not occur then.
    Also check this thread : Excel Error "Data entered is wrong" when using multiple tabs
    Cheers!

  • I cannot print or send a fileI downloaded Adobe yesterday and have spend 7 hours putting together a document I cannot print or send. If I print it out it only prints the template and not the data entered. I am very frustrated.

    I cannot print or send a file I spend 7 hours putting together and am becoming very frustrated. I downloaded this software yesterday and can only print out the template and the data entered does not appear. Please help.

    This forum is about the Cloud as a delivery process, not about using individual programs
    If you start at the Forums Index https://forums.adobe.com/welcome
    You will be able to select a forum for the specific Adobe product(s) you use
    Click the "down arrow" symbol on the right (where it says All communities) to open the drop down list and scroll

  • Unable to send the data entered in sap portal

    Hi
    All
    i am trying to configure and test  Leave Request  from portal. When, we create the leave request and submit for the first time, it is giving the error/message Unable to send the data entered However, if do a submit for the second time, the same leave request, it sends the leave request.
    Please share your valuable thoughts or solutions.Thanks in advance.
    Tanks
    Rafi Shaik

    Hi Rafi,
    We are also facing similar kind of issue.
    When i select type of leave as annual it is giving an error message as
    " Parameter  missing in call of method BUILD_ACTOR_SELECT_CLAUSE in class CA_PT_REQ_ACTOR "
    But when i select some other leave type and click review it is working fine, again if i click on previous step and change the leave type to annual it is working fine without giving any error message.
    Please let us know how you have solved your issue?
    Thanks.
    -Suresh

  • How to capture the data entered in a textfield in a JTable

    How to capture the data entered in a textfield present in a cell of a textfield or how to add listener to this textfield

    A sample of my code is:
              model = new GridDisplayTableModel(gridDisp,columnName,getRows(),getCols());
              final ComboRenderer cRenderer = new ComboRenderer();
              final TextFieldRenderer tRenderer = new TextFieldRenderer();
              combo.addItem("one");
              combo.addItem("two");
              combo.addItem("three");
              final JTextField textfield = new JTextField();
              final DefaultCellEditor cmbEditor = new DefaultCellEditor(combo);
         //     final JEnterDataCellEditor textEditor = new JEnterDataCellEditor(12);
              final DefaultCellEditor textEditor = new DefaultCellEditor(textfield);
              rm = new RowEditorModel();
              table = new JTable(model){
         public TableCellRenderer getCellRenderer(int row, int column) {
              int posx = 0;
                   int posy = 0;
                   TableCellRenderer renderer = null;
         for(int l=0;l<getDataVec().size();l++)
                   beanObj =(Helperbean)dataVec.elementAt(l);
                   posx = beanObj.getPosx();
                   posy = beanObj.getPosy();
                   if(row==posx && column==posy)
                             if(beanObj.getModeofDisplay() != null && beanObj.getModeofDisplay().equalsIgnoreCase("textfield"))
                                  rm.addEditorForRow(row,textEditor);
                                  renderer = tRenderer;
                             else if(beanObj.getModeofDisplay() != null && beanObj.getModeofDisplay().equalsIgnoreCase("combo"))
                                  rm.addEditorForRow(row,cmbEditor);
                                  renderer = cRenderer;
                             break;
                        renderer = super.getCellRenderer(row, column);
              //     System.out.println("getEditor"+rm.getEditor(1));
         return renderer;
    public TableCellEditor getCellEditor(int row, int col) {   
         int posx = 0;
         int posy = 0;
         TableCellEditor tmpEditor = null;
    for(int l=0;l<getDataVec().size();l++)
         beanObj =(Helperbean)dataVec.elementAt(l);
         posx = beanObj.getPosx();
         posy = beanObj.getPosy();
         if(row==posx && col==posy)
                   if(beanObj.getModeofDisplay() != null && beanObj.getModeofDisplay().equalsIgnoreCase("textfield"))
                        System.out.println("celleditorval "+textEditor.getCellEditorValue());
                        tmpEditor = textEditor;
                   else if(beanObj.getModeofDisplay() != null && beanObj.getModeofDisplay().equalsIgnoreCase("combo"))
                        tmpEditor = cmbEditor;
                   break;
              tmpEditor = super.getCellEditor(row, col);
    return tmpEditor;
    public boolean isCellEditable(int row,int col){
         boolean isEditable = false;
         int posx = 0;
         int posy = 0;
    for(int l=0;l<getDataVec().size();l++)
         beanObj =(Helperbean)dataVec.elementAt(l);
         posx = beanObj.getPosx();
         posy = beanObj.getPosy();
         if(row==posx && col==posy)
              if(beanObj.getModeofDisplay() != null )     
                        isEditable = true;     
                   else
                        isEditable = false;     
                   break;
         isEditable = false;
         return isEditable;
    public void changeSelection(final int row, final int column, boolean toggle, boolean extend) {
         super.changeSelection(row, column, toggle, extend);
         //my attempt to avoid editCellAt from being called twice in a row
         if (getModel().isCellEditable(row, column) && !(isEditing() && getEditingRow() == row && getEditingColumn() == column))
              if (editCellAt(row, column)) {
                   getEditorComponent().requestFocus();
         // Select the text when the cell starts editing
    public boolean editCellAt(int row, int column) {       
         boolean result = super.editCellAt(row, column);
         final Component editor = getEditorComponent();
         if (editor != null && editor instanceof JTextField) {           
              SwingUtilities.invokeLater(new Runnable() {               
                   public void run() {                   
                        ((JTextField)editor).selectAll();
              return result;
         public boolean hasFocus()
              Component editorComponent = getEditorComponent();
              // Try to install the editor
              int anchorRow = getSelectionModel().getAnchorSelectionIndex();
              int anchorColumn = getColumnModel().getSelectionModel().
              getAnchorSelectionIndex();
              if (anchorRow != -1 && anchorColumn != -1 && !isEditing())
              if ((this.getSelectedRow() == anchorRow) && (this.getSelectedColumn() == anchorColumn))
              if (!editCellAt(anchorRow, anchorColumn)) {}
              return super.hasFocus();
         public void valueChanged(ListSelectionEvent e)
              super.valueChanged(e);
              if ((this.getSelectedRow() == 2) && (this.getSelectedColumn() == 3))
                   DefaultFocusManager focusManager = new DefaultFocusManager();
                   focusManager.focusNextComponent(this);
                   model.fireTableStructureChanged();
         

  • Creating a module pool screen and upload the data entered,

    Dear Experts,
    As i am new to this area, can any one suggest me how can i design a module screen and also the data entered in the screen should be saved in Ztable.
    It would be of great help if any one provides material sort of thing.
    Thanks in advance..

    Hi
    Goto SE51 and design your screen.
    For each control specify the name. For a few controls you need to specify the function codes as well. Until you specify all the mandatory details the controls will remain pink.
    When you are done, Save and Activate.
    Click on Flow Logic button.
    Specify the modules you want to use in PBO and PAI.
    In the program declare data objects having same name as your screen fields.
    When you enter data in the screen fields, the values are automatically stored in the data objects you declared having the same name.
    If you want to insert the details into a ztbl, simply use insert queries and pass data using the data objects you have defined.
    If you are going for BDC:
    First ensure that your screens and code work correctly. Then do the BDC recording for one value. Modify the recorded program according to your requirement.
    Hope this helps
    Regards,
    Jayanthi.K

  • How to keep the data entered on a page apex

    how to keep the data entered on a page apex
    so, I've got a registration page then wish go to another page P2 and I return to this P1 without losing data

    Hi,
    As long as the registration page is within the same session, the values will remain in the session until they are specifically cleared out. This can be done by a process on a page - so check if you have a "reset page" process on P1 and, if you do, delete it. This can also be done on a branch - so check the branch that takes you to P2 and see if there is anything entered in the Clear Cache setting and, if it shows *1*, remove that. There are other ways as well, but these are most typical.
    Andy

  • How to enable/disable the input fields based on the data entered/user action in the web dynpro abap?

    How to enable/disable the input fields based on the data entered in the web dynpro application abap?  If the user enters data in one input field then only the next input field should be enabled else it should be in disabled state. Please guide.

    Hi,
    Try this code.
    First create a attribute with the name readonly of type wdy_boolean and bind it read_only property of input field of which is you want to enable or disable.
    Next go to Init method.
    Set the readonly value as 'X'.
    DATA lo_el_context TYPE REF TO if_wd_context_element.
         DATA ls_context TYPE wd_this->element_context.
         DATA lv_visible TYPE wd_this->element_context-visible.
    *   get element via lead selection
         lo_el_context = wd_context->get_element( ).
    *   @TODO handle not set lead selection
         IF lo_el_context IS INITIAL.
         ENDIF.
    *   @TODO fill attribute
    *   lv_visible = 1.
    *   set single attribute
         lo_el_context->set_attribute(
           name =  `READONLY`
           value = 'X').
    After that Go to the Action  ENTER.
    First read the input field ( first input field, which is value entered field) , next give a condition
    if input value is not initial  then set the readonly value is '  '.
    DATA lo_nd_input TYPE REF TO if_wd_context_node.
         DATA lo_el_input TYPE REF TO if_wd_context_element.
         DATA ls_input TYPE wd_this->element_input.
         DATA lv_vbeln TYPE wd_this->element_input-vbeln.
    *   navigate from <CONTEXT> to <INPUT> via lead selection
         lo_nd_input = wd_context->get_child_node( name = wd_this->wdctx_input ).
    *   @TODO handle non existant child
    *   IF lo_nd_input IS INITIAL.
    *   ENDIF.
    *   get element via lead selection
         lo_el_input = lo_nd_input->get_element( ).
    *   @TODO handle not set lead selection
         IF lo_el_input IS INITIAL.
         ENDIF.
    *   get single attribute
         lo_el_input->get_attribute(
           EXPORTING
             name =  `VBELN`
           IMPORTING
             value = lv_vbeln ).
    if lv_vbeln IS not INITIAL.
        DATA lo_el_context TYPE REF TO if_wd_context_element.
        DATA ls_context TYPE wd_this->element_context.
        DATA lv_visible TYPE wd_this->element_context-visible.
    *  get element via lead selection
        lo_el_context = wd_context->get_element( ).
    *  @TODO handle not set lead selection
        IF lo_el_context IS INITIAL.
        ENDIF.
    *  @TODO fill attribute
    *  lv_visible = 1.
    *  set single attribute
        lo_el_context->set_attribute(
          name =  `READONLY`
          value = ' ' ).

  • When I migrate from my old mac to a new mac does the data remain on the old mac

    when I migrate from my old mac to a new mac does the data remain on my old mac

    Yes. You are only Copying the Data not moving it.

  • SmartView Error - "The data entered is wrong"

    There is an alert in Smart View Ad Hoc that appears intermittently that says "The data entered is wrong, so it will revert back to the previous value". What causes this and what is the resolution?
    I realize this question was already asked but I didn't see an answer.
    Thanks

    There are many many forums on OTN, so new users really need to take a look around, use the Search or some other method of finding the right forum or category of forums. This forum is Community related and "for feedback about OTN ...", not the right place for having a discussion on how to resolve Smartview errors, which I think was the point of previous response.
    Have a look through the [BI Foundation|http://forums.oracle.com/forums/category.jspa?categoryID=145] category.

  • Exactly what does the Data Drop-down List do?

    What does the Data Drop-down List do? Is it used to make a drop-down list from certain records in a column in a table of a data base?

    Yes, this is exactly what it does. However, it's a custom control, not a built-in control. JavaScript is used to set it up. In order to use it you have to have a data connection in the document and modify the "Initialize" script, which is were the list is populated from the DB. The "Initialize" code is a good example of how to use XFA JavaScript to access a DB. However, the code is also written in a very general manor and takes the long way around to hooking up to the DB. Much shorter code can be written for a specific DB.
    Thom Parker
    WindJack Solutions
    www.windjack.com

  • Where does the data get saved from (notepad) or Notes on Windows Mobile 5?

    Where does the data get saved from (notepad) or Notes on Windows Mobile 5?
    (ON the Phone)  Sticky note like program WM5
    I ask because I synced my Blackjack 1 to my pc after about a year and MANY notes later, All the notes from the PC remained but ALL new notes on phone (a years worth) were deleted from the phone.
    I would like to attempt a data recovery on my mobile device- that was an insane endeavor but i got it to work now i just need to know what to look for (what type of files to recover) and or where to recover from?
    I did make the phone a drive already and have data recovery software that can pull deleted files from the phone in fat or raw data format.
    Thanks.

    Hi,
    I think this is not the best forum for your question. This forum is for Microsoft Exchange Server's mobile connectivity issues.
    Regards,
    Zoltán
    http://www.clamagent.org - Free Antivirus for Exchange
    http://www.it-pro.hu
    http://emaildetektiv.hu

  • How to fix the limit of the date entering in a parameters

    How to fix the limit of the date entering in a parameters,
    I.e i want to make parameters doesnot exceed 31.12.9999 in date and another parameter which is used to add no of days to this so it should not allow to add the no of days to given date as 31.12.9999

    parameter : p_date like sy-datum 
    at selection-screen on date1.
    if date1 GT 31.12.9999.
    message(e01).
    end if.
    reward with points if helpful.

  • Why does the Date Created metadata change when images are exported?How do I stop it from changing?

    why does the Date Created metadata change when images are exported?  How do I stop it from changing? I must have a prefernce set up wrong.

    I don't know what OS you are using, or what application you are using to view the data about your exported files, but on Windows and using Windows Explorer the "Date Created" field relates only to the date that the exported file was created, i.e. if viewed immediately after export it will show the date created as being the same date. In order to view "Capture Date" in something like Explorer, you first have to ensure you have included the Metadata as Conrad outlined above, then you have to adjust the display properties of Explorer to show the "Date Taken" field. Here is an example, part of a folder I exported back on March 3rd, note the difference between that last two dates:

  • Will the data entered under "Add a description" in iPhoto migrate with the images into Photos?

    Will the data entered under "Add a description" in iPhoto migrate with the images into Photos?

    Thanks for the reply. My particular use of iPhoto is for documents that I have photographed from archives, libraries, and other repositories across the US and Europe. For each one I have added a complete citation and notes. I am so relieved to hear that all my years of work on this will migrate with the new app!

Maybe you are looking for

  • New HP wireless printer install gives me Error Code 43

    I just bought the HP wireless and networking capable all-in-one printer, the C309 series (no indication of exact model number anywhere on the machine, but the maybe it's the C334, since that's near the serial number on the back. I connected it to my

  • My ibooks keeps crashing and using up all my battery since I installed ios 8.  how do I fix this

    I have an Iphone 5 and I did the update to ios 8 and now my i books keeps crashing and using up all my battery.  I have rebooted and shut down the phone and sync with itunes but still have problem  Any help out there?

  • Ads taking up too much CPU

    I have a lot of problems with ads in chat software, but this one's new. You have recently started serving a new ad for the Hungarian Vodafone, made in Flash.  Sadly after a few loops it will use up a lot of CPU and render Skype itself (in particular!

  • Website asking for database login

    </p Hi, I need your help and please help me. I have a report that have been working all this time until IT dept told me to change the database to something else.  I changed the datasource and it is running just fine on my computer.  When I loaded my

  • Blank Files appearing in Hard Drive??

    I have been noticing These blank files apearing recently. Plain Text,  Zero KB files In my main harddrive. I narrowed it down to my Pro Tools program. They generate each time I open Protools. Can anyone explain why and what this is? just worried it c