DateTimePicker : request for CulturInfo

M

Mark Johnson

Since there seems to be a general interest for non-US support for the
DateTimePicker.cs/.vb
I have created a site for this on

http://www.mj10777.de/NETFramework/Compact/DateTimePicker/index.htm

An Archive is offerd with the original Miscrosoft DateTimePicker.msi
(03.10.2003)
and the unpacked version with a changed version of
DateTimePicker.cs where a bug was fixed.
The Demp-Project will show bothe DateTimePickers.

There is also an Internationlized version called

mj10777.DateTimePicker.cs

which also supports FirstDayof Week logic.

The names for the Days and Months are retrieved according to the Language
set on the Maschine.

There is (as allways) an exception :

"Today" must be hard coded for each language supported.
The Method DateTimeFormatInfo.CurrentInfo.FirstDayOfWeek does not allways
return correct results (reported elseware).

I would be interest in learning :

- what is "Today" on non-english/German Mashines as shown in the PC-Version
of DateTimePicker.
- what is the First Day of the Week as shown in the PC-Version of
DateTimePicker.

UK : on Compact (Pocket PC 2002)
DateTimeFormatInfo.CurrentInfo.FirstDayOfWeek returns Monday.
- as far as I know this should be Sunday : is this assumtion correct?

See :

http://www.mj10777.de/NETFramework/Compact/DateTimePicker/Doku_DateTimePicker.htm

for the present results, which I will update after building in the results
to the source code.

I would welcome the results as an E-Mail to (e-mail address removed) (Subject :
DateTimePicker : LanguageX)
Language : SomethingInEnglish
Today : "xxxx"
FirstDayOfWeek : Day in English

and if possible 2 gif files from the original PC-Version of DateTimePicker
as shown in Doku_DateTimePicker.htm

Visual Basic support :

See

http://www.mj10777.de/NETFramework/Compact/DateTimePicker/VB_DateTimePicker.htm

Thank you.

Mark Johnson, Berlin Germany
(e-mail address removed)

PS: using "Subject : DateTimePicker : LanguageX" will avoid getting lost in
the Junk Box with the (allways promised, but never held) "Last critical
Update" and other unpleasent things.
mj10777
 
G

Guest

I posted a while ago a thread on the opennetcf with a datetimepicker(more datepicker) with internationalization support (99% code from the one posted on Microsoft :) ) on which you can impose any culture that you like. The only thing is that is hardcoded the first day of the week as Monday(if anyone is interested I can also expose a property for the first day of the week - just post a reply on the link below).

http://www.opennetcf.org/Forums/topic.asp?TOPIC_ID=101

Best regards
Da

P.S. Didn't looked to me that there is too much interest as for 3 month there were no reply to the thread.
 
M

Mark Johnson

I have downloaded your work and take a good look at the results.
Your use of CultureInfo as the main tool is a much better solution to what I
have been doing now (which is a leftover from my C/C++ pre Framework time).

Not only is the use of CultureInfo more Microsof like, it also give you the
posiblity of offering a solution that is more Maschine independent
(ie. Application running in US-English on a German Maschine) which is a
major goal in my Applications.

Therefore I will build in the support into my version exposing the
CultureInfo, TodayText and FirstDayofWeek
I hope you have no objection to the use of your ideas on this.

The FirstDayofWeek is still a problem since the results of
DateTimeFormatInfo.CurrentInfo.FirstDayOfWeek does not allways seem to be
correct (German is not, the others have not been tested on Compact yet.).

Yesterday I played around with the Desktop version and have a general idea
of who does what.

Monday as FirstDayofWeek is more widly supported than I expected.
It looks like all European, Russian, many Arab (Lebanon, Morroco,
Tuniesien), many Asian and most non-American-English Cultures use Monday.
Amost all American (Brazil, Mexico, US and Canada/English-French), some
Asian (Japan, China), Hebrew, Algeria and Saudia Arabia use Sunday.
The other Arabic cultures use Saturday (that was a big surprise).
Thai is the only Culture use their own year count (2004=2547), this was also
unexpected since I was expecting that for Hebrew and Muslim Cultures.

Since the logic I build into CalculateFirstDate() has been tested for all 7
days of the Week, I have no problem here.
I will have to check on setting CulureInfo for the correct results and
overide were need (as I do now with German).
Goal is getting this to work with all European Union languages (Today and
FirstDayofWeek) and then other (Latin) Languages inside Europe.

Mark Johnson, Berlin Germany
(e-mail address removed)

PS: Tomorrow I will start building a page showing the Desktop
DateTimePicker's that I tested yesterday. (http://www.mj10777.de)








Dan Ardelean said:
I posted a while ago a thread on the opennetcf with a datetimepicker(more
datepicker) with internationalization support (99% code from the one posted
on Microsoft :) ) on which you can impose any culture that you like. The
only thing is that is hardcoded the first day of the week as Monday(if
anyone is interested I can also expose a property for the first day of the
week - just post a reply on the link below).
http://www.opennetcf.org/Forums/topic.asp?TOPIC_ID=1014

Best regards,
Dan

P.S. Didn't looked to me that there is too much interest as for 3 month
there were no reply to the thread.
 
M

Mark Johnson

I have a problem registering on OpenNETCF.org Forums.
I noticed this before a few months ago and after I pressed "Agree" 10 times
I gave up.

Thus the answer here. (This may be a reson why you did not recieve any
replys.)

Mark Johnson, Berlin Germany
(e-mail address removed)

Dan Ardelean said:
I posted a while ago a thread on the opennetcf with a datetimepicker(more
datepicker) with internationalization support (99% code from the one posted
on Microsoft :) ) on which you can impose any culture that you like. The
only thing is that is hardcoded the first day of the week as Monday(if
anyone is interested I can also expose a property for the first day of the
week - just post a reply on the link below).
http://www.opennetcf.org/Forums/topic.asp?TOPIC_ID=1014

Best regards,
Dan

P.S. Didn't looked to me that there is too much interest as for 3 month
there were no reply to the thread.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top