Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / Internationalization / March 2007

Tip: Looking for answers? Try searching our database.

App not recognizing regional settings

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
ard - 27 Feb 2007 16:21 GMT
I hope this is the right group for this posting.

Our app has been ported from VC++ 6.0 (MFC) to DevStudio 2005 as unmanaged
code.  Since then we've been experiencing an odd problem.  When we open a
dialog that displays floating point numbers, the numbers are not displayed in
the proper regional format (e.g., using',' instead of '.').  However, if we
click on one of the edit boxes and then click off, it then displays the
number in the proper format.  Dates and time, however, always appear in the
proper format.  I've tracked one instance of the problem down to a call to
CString.Format() and then to a call to _cfltcvt_l() where the floating point
conversion is done.  Any ideas what could be going wrong?  Could it be some
preprocessor definition that needs to be added or removed?  Some
initialization call that has to be made on the app?  Is it some eccentricity
with MFC unmanaged code?

Thanks for any insights.
Signature

ard

Michael S. Kaplan [MSFT] - 01 Mar 2007 10:13 GMT
Not all of the CRT control uses Regional and Language Options settings. If
you want to get the settings, you have to call functions from the NLS API
such as GetNumberFormat and GetDateFormat in some cases.

Signature

MichKa [Microsoft]
NLS Collation/Locale/Keyboard Technical Lead
Globalization Infrastructure, Fonts, and Tools
Blog: http://blogs.msdn.com/michkap

This posting is provided "AS IS" with
no warranties, and confers no rights.

>I hope this is the right group for this posting.
>
[quoted text clipped - 18 lines]
>
> Thanks for any insights.

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.