Culture information: DisplayName, NativeName and LCID : Culture Format « I18N Internationalization « C# / CSharp Tutorial

C# / CSharp Tutorial
1. Language Basics
2. Data Type
3. Operator
4. Statement
5. String
6. struct
7. Class
8. Operator Overload
9. delegate
10. Attribute
11. Data Structure
12. Assembly
13. Date Time
14. Development
15. File Directory Stream
16. Preprocessing Directives
17. Regular Expression
18. Generic
19. Reflection
20. Thread
21. I18N Internationalization
22. GUI Windows Forms
23. 2D
24. Design Patterns
25. Windows
26. XML
27. ADO.Net
28. Network
29. Directory Services
30. Security
31. unsafe
Java
Java Tutorial
Java Source Code / Java Documentation
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
C# / C Sharp
ASP.Net
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
PHP
Python
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
C# / CSharp Tutorial » I18N Internationalization » Culture Format 
21. 4. 10. Culture information: DisplayName, NativeName and LCID
using System;
using System.Collections;
using System.Collections.Generic;
using System.IO;
using System.Reflection;
using System.Resources;
using System.Text;
using System.Threading;
using System.Globalization;

public class MainClass
{
    public static void Main()
    {
       string[] cultures = new string[] { "en-US""en-GB""es-MX""de-DE""ja-JP" };

        using (TextWriter sw = Console.Out)
        {
            foreach (string c in cultures)
            {
                CultureInfo ci = new CultureInfo(c);
                sw.WriteLine("{0}: {1}", ci.Name, ci.DisplayName);

                sw.WriteLine("    English Name: {0}", ci.EnglishName);
                sw.WriteLine("    Native Name: {0}", ci.NativeName);
                sw.WriteLine("    LCID: {0}", ci.LCID);

            }
        }
    }
}
en-US: English (United States)
    English Name: English (United States)
    Native Name: English (United States)
    LCID: 1033
en-GB: English (United Kingdom)
    English Name: English (United Kingdom)
    Native Name: English (United Kingdom)
    LCID: 2057
es-MX: Spanish (Mexico)
    English Name: Spanish (Mexico)
    Native Name: Espa?ol (M?co)
    LCID: 2058
de-DE: German (Germany)
    English Name: German (Germany)
    Native Name: Deutsch (Deutschland)
    LCID: 1031
ja-JP: Japanese (Japan)
    English Name: Japanese (Japan)
    Native Name: ??? (??)
    LCID: 1041
21. 4. Culture Format
21. 4. 1. Use current culture to format currency
21. 4. 2. Implement Format for different Culture Information
21. 4. 3. Get datetime formatting info from a CultureInfo
21. 4. 4. Get numeric formatting info from a CultureInfo
21. 4. 5. Save CultureInfo, its DateTimeFormatInfo and NumberFormatInfo to a text file
21. 4. 6. Culture formatting: en-US
21. 4. 7. Culture formatting: en-GB
21. 4. 8. An culture-friendly money matching expression
21. 4. 9. Culture-specific formatting: en-US, en-GB, ja, ar
21. 4. 10. Culture information: DisplayName, NativeName and LCID
21. 4. 11. Culture information: primary Calendar and optional Calendar
21. 4. 12. Culture information: Days
21. 4. 13. Culture information: Months
21. 4. 14. Culture information: Long Date Format and Short Date Format
21. 4. 15. Culture information: Currency Format
21. 4. 16. Culture information: Number Format
21. 4. 17. Culture information: Number Group Separator
w__w_w.___jav__a___2_s.___c___o___m___ | Contact Us
Copyright 2003 - 08 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.