How to get SLA using Calendar rules?

How can I add 24hrs to the time using the calendar rules? For Example, If the Monday's date is given I need to get Tuesday's date as SLA. If I give Friday's date I need to get Monday's date as SLA. I have tried using
CalendarRule.computeDate(time,interval).
CalendarRule.add(time,interval).It works fine for the first senario.but not for the second senario. Could please help me how to achive this. The above senario should also count the user defined holidays.
Please help me with regards.
Thanks in advance
- Narasimha

Hi,
Plz write the following logic it will help you
sla = 1;
Time start;
start = 'now';
Int count;
count = 0;
if(sla > 0) {
while (count < sla) {
if(calendarRule.isHoliday(time : start) == false &&
calendarRule.isWorkDate(time : start) == true) {
count = count + 1;
start = start + '1d';
start = start - '1d';
logMessage("inal Due Date for SLA (" + sla + " Day/s) is " + start.format("dd/MM/yyyy"));
I have hard coded the start time as well as sla. Please make the necessary changes.
Bibhu
Edited by: Bibhuti Bhusan on Sep 22, 2010 3:35 AM

Similar Messages

  • In ABAP HR how to get job using position

    In ABAP HR how to get job using position (Using Infotype 1001)

    Hi anilkumar,
    1. u have the position
       u want the Job
    2. In hrp1001 table
       OTYPE = 'S' (for position)
       OBJID  = POSITION (AS ABOVE)
       SCLAS = 'C' (for finding job)
    <b>   SOBID = XXXXXX (here u will get the JOB)</b>
    regards,
    amit m.

  • How to get image using Http and how to save in Smulator

    Hi guys,
    Am working in black berry bold. i dont know how to get image using htp connection and one more thing i need to save this image in side simulator directory............. what are the specific API i should...
    Guide me.........

    If you want the input image size you need to pass it in as parameters.
    A discussion thread on this topic is:
    http://forums.adobe.com/thread/29948
    -- Daniel R. <[email protected]> http://danielr.neophi.com/

  • Hi out there. To capture a screen shot one uses: Command-Shift-3 or 4. I have done this for a long time. Now suddenly neither screen shot works anymore. Suggestions how to get this useful function back? Thanks, Georgx

    Hi out there. To capture a screen shot one uses: Command-Shift-3 or 4. I have done this for a long time. Now suddenly neither screen shot command works anymore. Suggestions how to get this useful function back? Thanks, Georgx

    Command-Shift-3 and 4 works just fine on several Macs that I have here.
    Try restarting your Mac....or post in the specific support area for your Mac model....for more advice.
    https://discussions.apple.com/index.jspa

  • How do you start using calendar?

    How do you start using calendar? Adding dates,etc?

    One concept that is not described well is that your Calendar display is the Union of all the available Calendars selected. You can have lots of calendars open, and the events from each and every one will be shown in the summary Calendar display -- sort of like they were on transparencies overlaid on each other.
    Where you put your Master Calendar depends if you want to share your Master Calendar across multiple devices or other Users.
    The default calendar you "just create" is strictly private -- not available on any other device or any other User.
    To create a shareable Master Calendar, you need to set up an account on a calendar sharing site that is visible on the Internet -- not likely to be your home Mac. You can use Google calendar, Yahoo Calendar, iCloud calendar, any Server that uses CalDav, Microsoft Exchange, and others. Once established that Master Calendar can be accessed from anywhere on the Internet through another computer, an iPhone, or other "smart" devices.

  • How to get contacts and calendar info from my old palm files

    I used to use a Palm Tungsten T3. I no longer have it but until recently I still used the Palm Desktop. My computer "died" and I was able to copy all the Palm files of of it but now I have no idea how to get the contact and calendar(less important than contacts) info in some form I can use. I do not currently have any Palm software installed on my computer. I have Microsoft Windows XP on my computer now and use Outlook or Outlook Express. Does anyone have any advice for me. Thanks in advance.
    Post relates to: Tungsten T3

    I'm having the same problem.  Desktop 4.1.4 on old PC.  New PC with Win 7.   Loaded 6.2 and when I went to Import 6.2 is looking for .aba files.  Old PC has all .dat files.  How do I import or transfer addresses and other contact info to new PC??  Thanks.

  • How to get rid of Business Rule in JhsModel: JHS-00128 Allowable Values req

    JHeadstart 10.1.3.2
    We are using FlexItems in our application.
    The JhsModel implementation, shipped in Jar file jhsadfrt-10.1.3.jar, contains the underlying ADF BC objects for the FlexItem functionality.
    When we try to create (or remove) a FlexItemDefinition of type Dropdown List, we are stopped by the error: JHS-00128: Allowable Values are required for this Item Display Type.
    We do not want that - we have a UID that does not allow editing of master and details on the same page. Therefore, we will never be able to successfully create a dropdown list item since we cannot in the same transaction create the allowable values as well.
    How could we disable this business rule - or remove it altogether? I suppose it is implemented somewhere in the jar file that contains the JhsModel project. What is the recommended way of disabling this constraint?
    thanks for your help
    Lucas

    Hi Lucas,
    This error is raised if the number of allowable values is zero and the allowable values query of the flexitemdefinitions entity is 'empty'. You could write a (temporary) dummy allowable values query in the flexitemdefinitions entity in order to save the master, and then once you've input the allowable values in the details page, remove or reset the value in the allowable values query attribute of the flexitemdefinitions entity.
    Hope this helps,
    Regards,
    Ibrahim

  • How to get data using JDOM

    Hi,
    I have this xml file stored in operator.xml
    <Operator>
         <Customer>
              <Name>sam</Name>
              <Street>albert str.</Street>
              <ZipCode>45454</ZipCode>
              <City>NY</City>
              <Country>USA</Country>
              <EMailAddress>[email protected]</EMailAddress>
              <MeterNumber>1000</MeterNumber>
              <MeasuringUnit>kWh</MeasuringUnit>
              <Reading>
              <Month>1</Month>
              <Value>900</Value>
              </Reading>
              <Reading>
              <Month>2</Month>
              <Value>725</Value>
              </Reading>
              <Reading>
              <Month>3</Month>
              <Value>950</Value>
              </Reading>
         </Customer>
    </Operator>I have the following getter statements in my code:
    String name=req.getName();
    int month=req.getMonth();Now, I want to get value for particular customer (by checking name for equality with getter) and for particular month( by checking for equality with getter).
    I have written the following statements:
    final String filename="operator.xml";
    SAXBuilder builder=new SAXBuilder(true);
    Document doc=builder.build(filename);
    Element root=doc.getRootElement();How to proceed further using JDOM. I am confused with getChild(), getChildText() etc.,
    thanks,

    Obtain values with the JDom XPath class selectSingleNode and selectNodes methods.
    SAXBuilder saxBuilder=new SAXBuilder("org.apache.xerces.parsers.SAXParser");
    org.jdom.Document jdomDocument=saxBuilder.build(new File("c:/input.xml"));
    org.jdom.Element zipcodeNode= (org.jdom.Element)(XPath.selectSingleNode(jdomDocument,"/Operator//Customer/zipCode"));

  • How to get InitialContextFactory using RMI/IIOP without using weblogic.jar

    Hi Robert
    I know this is an old post. but I am interested in knowing how to get the
    initial context using RMI/IIOP without the use weblogic specific classes
    like weblogic.jndi.WLInitialContextFactory . If you have a code snippet that
    you can provide as an example, it would be just great.
    thanx in advance
    Daya Sharma
    See comments inline...
    Stewart Wachs wrote:
    I would like to get an initial context to Weblogic JNDI from a client.
    code snippet:
    Hashtable ht = new Hashtable();
    ht.put(Context.INITIAL_CONTEXT_FACTORY,
    "weblogic.jndi.WLInitialContextFacorty");
    ht.put(Context.PROVIDER_URL, "t3://localhost:7001");
    try {
    Context ctx = new InitialContext(ht);
    catch(...) {
    This works fine when I include weblogic.jar (and other dependend weblogic
    jar's) in the classpath.
    Is there a way to access WL JNDI from a client without the weblogicclasses
    in the classpath?If you are using WLS 6.1, you could use RMI/IIOP to do this but in general,
    the
    answer is no, you will need at least some of the weblogic classes on the
    client.
    If not, is there a lightweight jar available for distribution for client
    JNDI connectivity?This is something in the works. In addition, a colleague and I are working
    on
    a white paper that describes the "Thin Client Options with WebLogic Server"
    that we hope to make available in the not too distant future...
    Are there any licencing issues with distributing the weblogic classes to
    clients that need to access WL JNDI?No. WLS is licensed by the server so you are free to distribute
    weblogic.jar
    to your clients.
    Hope this helps,
    Robert

    Take a look at the RMI/IIOP section of our whitepaper "Small Footprint
    Client options for BEA WebLogic Server" at:
    http://dev2dev.bea.com/resourcelibrary/whitepapers.jsp?highlight=whitepapers
    Daya Sharma wrote:
    Hi Robert
    I know this is an old post. but I am interested in knowing how to get the
    initial context using RMI/IIOP without the use weblogic specific classes
    like weblogic.jndi.WLInitialContextFactory . If you have a code snippet that
    you can provide as an example, it would be just great.
    thanx in advance
    Daya Sharma
    See comments inline...
    Stewart Wachs wrote:
    I would like to get an initial context to Weblogic JNDI from a client.
    code snippet:
    Hashtable ht = new Hashtable();
    ht.put(Context.INITIAL_CONTEXT_FACTORY,
    "weblogic.jndi.WLInitialContextFacorty");
    ht.put(Context.PROVIDER_URL, "t3://localhost:7001");
    try {
    Context ctx = new InitialContext(ht);
    catch(...) {
    This works fine when I include weblogic.jar (and other dependend weblogic
    jar's) in the classpath.
    Is there a way to access WL JNDI from a client without the weblogic
    classes
    in the classpath?
    If you are using WLS 6.1, you could use RMI/IIOP to do this but in general,
    the
    answer is no, you will need at least some of the weblogic classes on the
    client.
    If not, is there a lightweight jar available for distribution for client
    JNDI connectivity?
    This is something in the works. In addition, a colleague and I are working
    on
    a white paper that describes the "Thin Client Options with WebLogic Server"
    that we hope to make available in the not too distant future...
    Are there any licencing issues with distributing the weblogic classes to
    clients that need to access WL JNDI?
    No. WLS is licensed by the server so you are free to distribute
    weblogic.jar
    to your clients.
    Hope this helps,
    Robert

  • How to get or use "kTextFrameOversetChangeMsg" as serviceid?

    Hi all
    I've developed a small plugin for handling textframe overflow. I've used service ids "kBeforeSaveDocSignalResponderService", "kBeforeSaveAsDocSignalResponderService". But actually I've to run it, only when overflow occurs.
    Steven suggested to use "kTextFrameOversetChangeMsg". I tried, but I dont know exactly how to use it as service id. Could anyone suggest on this?
    thanks in advance
    A.Hakkim

    Thank u both. Pls suggest me how to get serviceid from "kTextFrameOversetChangedMsg".

  • How to get and use mouse information?

    I want to write a simple program for getting mouse location, and if the location of the mouse is within an area, then a red dot show on the screen.
    Could anyone please teach me how to get mouse location?
    Thanks

    http://java.sun.com/docs/books/tutorial/uiswing/events/mouselistener.html
    http://java.sun.com/docs/books/tutorial/uiswing/events/mousemotionlistener.html
    http://java.sun.com/docs/books/tutorial/uiswing/events/mousewheellistener.html
    Doh! Too slow!
    Message was edited by:
    DrLaszloJamf

  • 2 iphones 1 comuter - how to get 2 different calendars and contacts on each

    I have been using my iphone 3G for a few months and syncing to outlook for contacts, calendar and notes. My wife has just got her own phone (3G). She logs in to the computer with her own account and has her own itunes library so there is no problem with us syncing different music libraries. Problem is we want to set-up an outlook file for her with her calendar, contacts and notes.
    When she is logged in though and opens outlook instead of being able to create her own outlook calendar, contacts list and notes she seems to be opening mine (even though she is logged in as her). How can she set up her own outlook without altering mine or having to see all my information?
    Anyone managed to get two iphones syncing on the same computer but different user accounts to different Microsoft Outlook 2003's. This may be more an outlook question than an iphone one!

    This is an Outlook problem, and a bit tricky to fix via long distance through a forum. So if you have a local Windows expert ask them to look at it. If you want to try yourself I'll see if I can help.
    Does your Outlook sync to an Exchange server, or do you just use it as an email client for POP3 or IMAP?
    Has your wife ever used Outlook with here own email account? It sounds like the answer is no, so how does she now access her email?
    What you need to do is log on as your wife, then create a new Outlook account using Outlook under her Windows ID. In Outlook go to Menu/Options/Email Accounts and choose to set up a new account.

  • How to get 10.6 calendar out of Time Machine after a clean install of 10.8

    I recently did a clean install of Mountain Lion on my 2007 2.2GHz Intel, 4GB RAM with 120GB SATA Disk.  First, I backed up all of my files in a 1 terabyte WD external harddrive using Time Machine on Oct. 26; as I used my MacBook Pro during the week Time Machine continued to back up my files as I kept it connected to my laptop.
    On November 1st I disconnected the WDHD and initiated the clean install.  Using a Jonathan Morrison video on YouTube I erased all of my files on Snow Leopard and installed Mountain Lion.  (I only want to import certain data back into my laptop at to keep it free from choking on files and programs that I never or rarely use; I only use it for writing and the calendar and misc: no pictures or movies: I am trying to be gentle with it because of its age.) For the next 9 days I backed up all of my Word docs and files in various cloud storage.
    On November 10th I connected the WDHD again and Time Machine did its backups; as I worked I assumed that iCloud and iTunes was taking care of the internal syncing, of my calendar and notebook, contacts et. al, as I merely connected my phone, signed in to iCloud and opened iTunes and clicked SYNC. After the syncs, I opened Calendar and found none of my events; Notes, likewise, had only 7 notes: on my phone are over 40.
    I began research online and found that the majority of post and responses to the question of retrieving this type of data (Calendar, Notes) was best accomplished by using Time Machine.
    http://chasingaftermoonbeams.blogspot.co.uk/2012/05/restoring-lost-ical-events-a nd.html
    This blog informed me that if I turn off my wifi and erase certain files, I can then restore my calendar from my Time Machine back up.  The only problem is that my Time Machine, while it is in the "Star Wars" mode will not let me access anything beyond November 10th.  I went into my Time Machine user files to access my calender files - and they are there -  and discovered that my old 10.6 drive is separate from my new 10.8 drive.  I did a bit of research and found an article on that subject:
    http://creativetechs.com/tipsblog/access-files-from-other-time-machine-backups/
    This article informed me that one can browse other disks in Time Machine.
    The only problem with this solution, for me, was that my new 10.8 drive was the only drive available to choose in the Time Machine "Choose Time Machine Disk To Browse" dialog box.
    My question is this: How do I retrieve the 10.6 Snow Leopard OS X Calendar files (pre-November 10th) from Time Machine and install them on the 10.8 Mountain Lion OS X Calendar?

    I recently used Migration Assistant to migrate the calendar folders but that only created another user; after I deleted that user I attempted to drag the folders to my desktop but recieved a prompt that I did not have permission to do this.  If anyone has any ideas on this problem I would very much appriciate any advice that might assist me in understanding the concatenating process of what I am attempting to do.  It has been quite curious and vexing.

  • How to get photos in calendar Source section

    I'm putting a calendar together and didn't choose all photos before starting the layouts. Now that I'm in the middle of the project, how do I get additional photos into the unplaced photo section allocated for them. If I open the library, the calendar layout goes away. If I drag photos or albums to the Source calendar designation, it doesn't work.
    I think I actually did this the other day, but I'll be darned if I know how.
    Jane
    2.0Ghz   Mac OS X (10.4.7)  

    Jane:
    Just drag the photos from the main library onto the calendar icon in the Source pane. That will add the photos to the photo bin in the calendar.
    Do you Twango?
    TIP: For insurance against the iPhoto database corruption that many users have experienced I recommend making a backup copy of the Library6.iPhoto database file and keep it current. If problems crop up where iPhoto suddenly can't see any photos or thinks there are no photos in the library, replacing the working Library6.iPhoto file with the backup will often get the library back. By keeping it current I mean backup after each import and/or any serious editing or work on books, slideshows, calendars, cards, etc. That insures that if a problem pops up and you do need to replace the database file, you'll retain all those efforts. It doesn't take long to make the backup and it's good insurance.

  • How to get iterator used on jsff from button clicked on jspx

    Hi All,
    I am using jdeveloper 11.1.1.5.
    I have a bounded task flow and inside that I have a jsff and I have added one iterator in its bindings. Now I have dragged that jsff on my jspx page as a region.
    I have a button on my jspx page I want to find the iterator of the jsff on button click.
    How to find it.
    Please help.
    -- NavinK

    Thanks Timo for your reply.
    Does that mean We have to add the same iterator in the bindings of jspx as well ?
    In my case I have added the iterator to my jspx page but I am getting the error described in InputText value is not getting updated in Iterator
    Please help.
    --NavinK                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

Maybe you are looking for

  • Windows 8.1 something happened and windows 8.1 Pro couldn't be installed.

    After the release of windows 8.1 preview I attempted the installation of 8.1 preview which failed. I decided it wasn't worth the bother until it was officially released so I left it uninstalled. After the official release of 8.1 yesterday I opened th

  • Vi session strategy with LV 7 in Test Stand

    Hi all, Im a producing a set of vi's(LV7.1) which will be strung together in a Open Visa, Write visa ..., Read visa , Close visa, over several instruments. I wish later to use Test Stand(3.1) to slice these routines, but I am not sure how test stand

  • R7950-2PMD3GD5/OC bsod at stock settings.

    My pc running a msi R7950-2PMD3GD5/OC  keeps getting bsods and crashes on programs/ games that are very graphically intensive, namely the ones i found that had the problem where Sleeping Dogs, Planetside 2, and Heaven Benchmark. Though I fear it will

  • Airport Express Hardware Problem?

    My Airport Express Modem is about a year old. Recently it began losing connection to my G4. The signal appears to fade and return, repeatedly....the bars on the airport icon go from 0 to 4 and back again. The green light remains on. This begins after

  • Movie in wrong library on same computer

    I bought a movie from Itunes.  I didn't realize that I was on my daughter's log in.  The movie went into that library.  I want to move it to my main Itunes library on my sign in but I can't figure out how to do it.  It is all on the same computer.