How convert Date to Calendar

i nedd convert a type Date to Calendar or how can increment a Date value in relation with the int value?
Help me please

Calendar has a setTime(Date) method, I think. You could look it up, I'm just going from memory. So create a new Calendar object and call setTime on it.

Similar Messages

  • Need to convert  Date from calendar to String in the format dd-mom-yyyy

    Need to convert Date from calendar to String in the format dd-mom-yyyy+..
    This is absolutely necessary... any help plz..
    Rgds
    Arwinder

    Look up the SimpleDateFormat class: http://java.sun.com/j2se/1.4.2/docs/api/java/text/SimpleDateFormat.html
    Arwinder wrote:
    This is absolutely necessary... any help plz..For you maybe, not others. Please refrain from trying to urge others to answer your queries. They'll do it at their own pace ( if at all ).
    People on the forum help others voluntarily, it's not their job.
    Help them help you.
    Learn how to ask questions first: http://faq.javaranch.com/java/HowToAskQuestionsOnJavaRanch
    (Yes I know it's on JavaRanch but I think it applies everywhere)
    ----------------------------------------------------------------

  • Create a function that convert date Gregorian calendar to Hijri calendar

    hey guys, i had an assesment i need to finish as my test for flash developer vacancy...
    i need to create a function that convert date Gregorian calendar to Hijri calendar in flash
    is that possible??
    i've search through google, but still doesnt find anything useful yet..
    kinda need ur help plz.....

    http://www.codeproject.com/KB/datetime/hijrigregorianclass.aspx

  • How convert date/time from xml in xdp(Designer)?

    Hi, i want to convert date/time format from xml in Designer, date/time value in xml is NOT in common format YYYY-MM-DD (if is in a common format i can do this with pattern)
    I have a "DateTime" Field in Xdp can get from Xml date and time:
    In XML <DateTime>DD-MM-YYYY</DateTime> i want to convert in XDP in DateTime Field in "DD-April-YYYY"
    Can i do this?

    You can do this way..
    Bind the date field to your XML tag.
    Set the display pattern for the date field.
    In the initialize event of the date field place the following code.
    Set JavaScript as language.
    var dtStr = this.rawValue;
    var pos1=dtStr.indexOf("-");
    var pos2=dtStr.indexOf("-",pos1+1);
    var strMonth=dtStr.substring(0,pos1);
    var strDay=dtStr.substring(pos1+1,pos2);
    var strYear=dtStr.substring(pos2+1);
    //Assign the formatted value to the Date field.
    this.rawValue = strYear + "-" + strMonth + "-" + strDay;
    Thanks
    Srini

  • Convert Date to Calendar week in Query Designer

    Hi experts,
    Is it possible to convert date to week in the query designer?
    Thanks in advance for your help.
    Best Regards,
    Rose

    Hi,
    Can you please explain more about virtual char you mentioned?
    What i am actually doing is i am using a formula variable (getting the value from customer exit) and i based the calculation of other keyfigures basing on this value.  The input value.. (data type date ) does not filter my query output.. it is only purely used for calculating other keyfigure values.  The data types (Dimension Settings ) available in formula variable are only quantity, amount, pice and number, date and time..  there is no week there.  So currently I am using the date.  If I can convert date to week then.. I can make my query a lot simpler.
    Thanks for your reply...
    Regards,
    Rose

  • How convert date with different timezone?

    HI,
    My problem is pretty simple. I have one Date and given another time zone (as a string), I want to have another date object with a different time zone. I used jodaTime. The code is as follows:
    DateTimeZone zone = DateTimeZone.forID("US/Eastern");
    DateTime parsedDateTime = DateTimeFormat.forPattern("mm/dd/yyyy").withZone(zone).parseDateTime(dstr);
    System.out.println(parsedDateTime.toString());
    System.out.println(parsedDateTime.toDate().toString());The output is:
    2008-02-14T00:00:00.000-05:00
    Thu Feb 14 11:00:00 GMT+06:00 2008
    This is quite weird. As is obvious from the output, datetime stores date in the correct timezone. but when converted it to date it applies the jvm's timezone. Why is it so? And why is this time conversion mad e so difficult by providing zillions of classes and methods such as Date, Calendar etc.

    amishera2006 wrote:
    HI,
    My problem is pretty simple. I have one Date and given another time zone (as a string), I want to have another date object with a different time zone. I used jodaTime. The code is as follows:
    DateTimeZone zone = DateTimeZone.forID("US/Eastern");
    DateTime parsedDateTime = DateTimeFormat.forPattern("mm/dd/yyyy").withZone(zone).parseDateTime(dstr);
    System.out.println(parsedDateTime.toString());
    System.out.println(parsedDateTime.toDate().toString());The output is:
    2008-02-14T00:00:00.000-05:00
    Thu Feb 14 11:00:00 GMT+06:00 2008
    This is quite weird. As is obvious from the output, datetime stores date in the correct timezone. but when converted it to date it applies the jvm's timezone. Why is it so? And why is this time conversion mad e so difficult by providing zillions of classes and methods such as Date, Calendar etc.for the first question, i can't help you
    but for the second one, i guess it's for historic reasons (no defined standard at the beginning lead to a big mess, the same way as with encoding issues)

  • How convert data LIS to LO

    hai suresh i am reward points is 30

    Hello Suresh,
    This topic is discussed a lot of times in SDN and you can search for it. Whenever you post some questions make it meaningful as lots of question that was posted yesterday are few examples.
    Thanks
    Chandran

  • Date to Calendar

    can anyone suggest a way to convert Date to Calendar?

    TNX! but this method returns void, I need something
    to return a Calendar objectEm.. hmm... The method is not supposed to return you the Calendar object. You have to do it in this manner:
    Calendar cal - Calendar.getInstance();
    cal.setTime(date); // The date will be set in Calendar ;)

  • How to convert julian Date into Calendar Date

    Hi,
    I want convert julian Date to calendar Date (mm/dd/yyyy or mm/dd/yy format) in java.
    Can any one help me how to convert julian date to calendar Date.
    Thanks,
    Krishore.

    import java.util.*;
    import java.text.*;
    public class jdate {
    Calendar date;
    public jdate(int j)
    date = Calendar.getInstance();
    date.set(Calendar.DAY_OF_YEAR, j);
    public String toString()
    SimpleDateFormat formatter = new SimpleDateFormat("MM/dd/yyyy");
    return (formatter.format( date.getTime() ));
    public static void main(String args[])
    if(args.length == 1)
    int j = Integer.parseInt(args[0]);
    jdate julian = new jdate(j);
    System.out.println("Julian date(" + j + ") = " + julian.toString());
    }

  • How to convert date (dd/mm/yyyy) to week no. calendar?

    hi all,
    I have a question about if user enters 12/12/2004(dd/mm/yyyy), which week is that? I just know week no. should from 01 to no more than 53. How to convert date to week no.?
    Thanks

    select to_char(sysdate,'IW'),to_char(sysdate,'wW') from dual;
    for IW, the week 2 starts on the first monday after 1.Jan, for WW, the week 2 starts on 8. Jan.
    HTH
    Laurent Schneider
    OCM DBA

  • How to import or sync Exchange server data like Calendar, Contacts with a web application or web service

    How to import or sync Exchange data like Calendar, Contacts with a web application or web service.
    1. Is there any API to import contacts and calendar (tasks and events) from exchange server to my calendar in web application using web services or http request. the user would have provided the username and password for his exchange account.
    2. Is there any licensing involved to communicate with exchange server for its data.
    thanks in advance 

    I am bit lost here; i have my exchange credentials, how (or) can i use the above mentioned solution for windows application or web services. can you please point in the right direction. my requirement is this: how to sync exchange data with a third party
    app or webapp(my development) using EWS. how to start with, starting point and steps to do[just overview ;)].

  • Ipad - how to push Exchange calendar events to iCloud account? MobileIron is used to get Exchange data -- is there an app to push the ipad version of the events to iCloud?

    ipad - how to push Exchange calendar events to iCloud account? MobileIron is used to get Exchange data -- is there an app to push the ipad version of the events to iCloud?
    There are two separate calendars on ipad (ios 7.1) one for icloud, one fo exchange. I have tried a couple of calendar apps and while they do a good job of showing the events in the app - they don't push (synch) back to iCloud. Any thoughts on an app that will take my ipad calendars and synch them to a single icloud calendar/account?
    Thanks

    Hi
    You asked about a recommendation for an app to paste a group of addresses into the To, Cc or Bcc fields of an email?
    Our "MailShot Pro" app is the only one we know of on the App Store that creates special "group contacts" in your address book which contain all your groups email addresses, but can be used just like regular contacts from most of your favourite apps. We now have nearly 50000 people using it, and growing steadily every day.
    Here is a link if you would like to know more “MailShot Pro” (itunes link).
    A free version is also available if you'd like to try it out with a small nmber of contacts.
    If you need any customer support just contact us at the website, we're always happy to help.
    Peter
    www.solubleapps.com
    Disclosure: I am the developer of this app and may benefit from its sale- (but so might you)

  • How can I convert date in FOX (from DEC to date[DEC])

    Hi everyone!
    In my planning layout I have a field called "MYDATE" of the date-type "DEC: Calculation or amount field with comma and +/- sign" (-> BPS does not allow using DATS as date-type).
    Since I import that date from a different system, I have to use a temporary workaround field "WADATE" (WorkaroundDate) of type DEC (alternatively integer or float) which contains the date in a format YYYYMMDD (e.g. 20070604).
    How can I transfer the date from WADATE to MYDATE? I tried using FOX, but for some reason it does not work. When I use the following function, MYDATE remains empty:
    DATA TMPDATE TYPE F.
    DATA MYPROJECTS TYPE B906_PROJ.
    FOREACH MYPROJECTS.
    "MYDATE" is the field I want my date in
    "WADATE" is my workaround field that contains the date
    TMPDATE = {WADATE,000,0000000001,0000000001,001}.
    BREAK-POINT.
    {MYDATE,000,0000000001,0000000001,001} = TMPDATE.
    ENDFOR.
    Is it possible to solve my problem with FOX? Or do I have to work with an EXIT function?
    Best regards, Daniel

    Daniel,
    The better approach is the one Marc said but if you have tomake a work around work, I think you might need to try and define your temporary date variable as String and another for the converted date as of type of the final date.  I would not define any date type as float unless you can have part days and it is very important to have part days, integer might work by I would try String first myself.
    It has been a while but on a BW 3.5 project I had to do some manipulation to read the attribute value of material master data to get the launch date and use it to derive the start period (definited as type 0FISCPER) and proportion of month based on number of days remaining after launch date vs the # of days for the month.  I think I used string type function in FOX to derive some of the component...
    Hope this helps,
    mary

  • I have a 4s...today, for no apparent reason, I am missing data including, calendar appts, notes, contacts and maybe other things that I am not aware of right now.  I did nothing to cause this.  Any ideas on how to restore?

    I seem to have lost a significant amount of data from calendars (ll appts are gone), notes (a good percentage are gone) and contacts (more than 50% are gone).  I have done nothing to cause this.  Any ideas how I might restore everything?

    try turning the phone off and then back on it worked for me.

  • How to make users to select the date from calendar control my making the date field read only in date time control in external list in sharepoint 2010

    How to make users to select the date from calendar control only, by my making the date text field read only (don't want to let users type the date) in date time control in external list in sharepoint 2010. I am looking for a solution which can
    be done through sharepoint desginer / out of the box.
    thanks.

    Congratulate you got the solution by yourself. I am new to a
    WinForms calendar component, I feel so helpless on many problems even I'd read many tutorials. This question on the
    calendar date selection did me a great favor. Cheers.

Maybe you are looking for

  • Help-Want to lock Time Machine back-up from being deleted

    Hello there, I used to have a macbook pro from november of 2006 that was loaded up with data from graduate school. As it was getting quite old, I wanted to get a newer laptop and chose the macbook air for many reasons. However, it doesn't have nearly

  • Replacing OEm hdd, how to restore from TM backup

    Hello All, This is my first time posting, though I have seen many threads from here while searching google. My question is this, I am about to upgrade my macbook pro 13's hdd from the OEM hitachi 160gb 5400 rpm drive to a Seagate 500gb 7200rpm. I hav

  • Password for nokia x2-01

    i've updated my firmware to 8.71 through ovi suite but afterwards i can't set up the password for the phone itself. tried for the default code - 12345 or 123456 , nt working !!! plzz help !! Solved! Go to Solution.

  • Asha 501: How to setup voip account for nimbuzz..

    Hi, Is nimbuzz voip activated services for asha 501. If so, please let me know how to activate it. Also, do I need to pay it.

  • F110 void check print problem

    Hi, While trying to print check through f110 a voided check comes along with the actual check, thereby printout with two pages come. But while checking the same print through fbz5 tcode it shows only one page with the actual check details and no void