윈도우 앱개발을 향하여

블로그 이미지
윈도우 10 스토어에 앱을 개발해 올리는 것을 목표로 하고 있습니다. 비전공자가 독학으로 시도하는 일이어서 얼마나 걸릴지 모르겠지만... 아무튼 목표는 그렇습니다!!
by 코딩하는 경제학도
  • Total hit
  • Today hit
  • Yesterday hit

Copyright

이 모든 내용은 Pluralsight에 Jeremy Clark가 올린 'Localization and Globalization in .NET'라는 강의의 마지막 챕터를 듣고 정리한 것입니다(https://app.pluralsight.com/library/courses/intro-to-localization-globalization-dotnet/table-of-contents).



Globalization
The process of engineering an application so that it does not have cultural preconceptions
(Dates, Calendar, Numbers, Currency, etc)


A Good Use of Flags
문화를 대표하면서도 언어를 다르게 설정하기에 좋은 이미지가 바로 국기이다.
e.g., 캐나다 국기와 함께 영어 또는 프랑스어를 사용


IFormatProvider
Use IFormatProvider to ensure the format based on the correct culture

IFormatProvider is an interface and used a lot as Optional parameter of ToString method
CultureInfo class implements IFormatProvider, so We can pass a CultureInfo object to ToString method
e.g., currentDate.ToString("d", new CultureInfo("en-US");
The same method exists in integer.ToString, decimal.ToString, and other classes

DateTime.Parse
We can parse a DateTime like DateTime.Parse("10/23/2015"); OR use DateTime.Parse(string s);
But we should USE DateTime.Parse(string s, IFormatProvider provider);
If we do not provide the IFormatProvider parameter, it uses the CurrentCulture (which may not be what we expect)


Currency Considerations
ToString with a currency format will use the CurrentCulture

The Solution
1. Use a single currency regardless of CurrentCulture (like US dollar)
e.g., 100M.ToString("C", new CultureInfo("en-US"));
2. Incorporate a currency conversion
We can get the conversion factor from a database or store it as a resource
although the resource would need to be updated frequently



Summary (생략)


Course Summary (생략)


Resource

Resgen.exe : Converts between different resource file types (.txt, .resx, .resources, .resw) (link)

LocBaml : Another way to localize WPF applications (link)

Globalization, Internationalization, and Localization in ASP.NET MVC 3, JavaScript and jQuery (link)



출처

이 모든 내용은 Pluralsight에 Jeremy Clark가 올린 'Localization and Globalization in .NET'라는 강의의 마지막 챕터를 듣고 정리한 것입니다(https://app.pluralsight.com/library/courses/intro-to-localization-globalization-dotnet/table-of-contents). 제가 정리한 것보다 더 많은 내용과 Demo를 포함하고 있으며 최종 Summary는 생략하겠습니다. Microsoft 지원을 통해 한달간 무료로 Pluralsight의 강의를 들으실 수도 있습니다.


AND

ARTICLE CATEGORY

분류 전체보기 (56)
Programming (45)
MSDN (4)
개발노트 (2)
reference (5)

RECENT ARTICLE

RECENT COMMENT

CALENDAR

«   2024/05   »
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31

ARCHIVE