I am in the US and need to use Monday as the first day of the week. I do not want to use "Locale.setDefault(XXX)" as this would have other side effects to the rest of the app. Previous posts made it appear that you could set the Locale on the DateAreaBeans to achieve this.
I've tried this approach with the BeanDemo. Changing the Locale on the beans had no affect. The only way I've gotten a change is by passing a Locale in the DateRange creations. This only works for the initial settings. Once I click on the calendar on the left I'm back to Sun-Sat.
How can I achieve this without changing my default Locale?
Thu Oct 14, 2010 11:02 pm
Joined: Mon Dec 06, 2004 4:24 pm Posts: 2485 Location: Sweden
Re: Change Locale / first day of week
Java isn't really made to work with a different first day of week than the one in the Locale.
What you need to do is set the Locale that you want with the correct first day of week on everything MiG Calendar related. If different Locales was set for different parts in MiG Calendar it is hard to overview the consequences. Basically this means that you should set the Locale on any component that has a .setLocale() and on every DateRange created.
The simple way is to set a default locale as you mention. Maybe GB or Australian?
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum