This week's book giveaway is in the Other Languages forum.
We're giving away four copies of Functional Reactive Programming and have Stephen Blackheath and Anthony Jones on-line!
See this thread for details.
Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Calender problem

 
Shiva Shankar
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi friends,

i want to have two calendar in the same problem,i want to perform different action on both the calendar,and it should't affect each other.
i am trying to use folllowing code
Calendar calendar = new GregorianCalendar();
Calendar calendar1 = new GregorianCalendar();

to create two calendar,and i am performing different action but its effecting
each other,how to avoid it

please reply
 
Divya Shastry
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Could you please paste the code, where the references are exactly affecting each other, so that it gets easy to find a solution ?
 
Luciano Mantuaneli
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I made this test and the instances seems to work independently...
 
Neerav Narielwala
Ranch Hand
Posts: 106
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Let it be :
Calendar calendar = new GregorianCalendar();
Calendar calendar1 = new GregorianCalendar1();

with GregorianCalendar1() same as GregorianCalendar() try it...
 
Shaan Shar
Ranch Hand
Posts: 1249
Java Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Neerav Narielwala:
Let it be :
Calendar calendar = new GregorianCalendar();
Calendar calendar1 = new GregorianCalendar1();

with GregorianCalendar1() same as GregorianCalendar() try it...


And what is GregorianCalendar1 ??? from where do you get it... or you tryin to make another class as GregorianCalendar1.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic