20
Developing International Applications for Mobile Devices with .NET Achim Ruopp International Program Manager Microsoft Corporation

Developing International Applications for Mobile Devices with.NET Achim Ruopp International Program Manager Microsoft Corporation

Embed Size (px)

Citation preview

  • Slide 1
  • Developing International Applications for Mobile Devices with.NET Achim Ruopp International Program Manager Microsoft Corporation
  • Slide 2
  • Definitions globalization The process of designing and implementing a product and/or content (including text and non-text elements) so that it can accommodate any local market (locale). localizability The ability of a product and/or content (including text and non-text elements) to be adapted for any local market (locale). localization The process of adapting a product and/or content (including text and non-text elements) to meet the language, cultural, and political expectations and/or requirements of a specific local market (locale).
  • Slide 3
  • Agenda focus on differences to desktop application development with.NET and how to deal with them ASP.NET Mobile Controls introduction globalization localizability and localization.NET Compact Framework introduction globalization localizability and localization Windows CE.NET 4.1 customizing globalization support multi-lingual user interface support References
  • Slide 4
  • .NET Application Models for Devices code web pages Visual Studio.NET.NET Framework Mobile Web Browser.NET Compact Framework client-side applications web applications
  • Slide 5
  • ASP.NET Mobile Controls - Overview set of ASP.NET controls in Visual Studio.NET 2003 to create mobile web applications for Visual Studio.NET 2002 known as Mobile Internet Toolkit broad support for connected devices with browsers for: HTML xHTML (Basic and Mobile Profile) WML (Wireless Markup Language) cHTML (compact HTML) adaptive rendering
  • Slide 6
  • ASP.NET Mobile Controls Overview extensible and customizable controls and adapters state management: application and session state security through mobile forms authentication a runtime and a designer emulator support
  • Slide 7
  • ASP.NET Mobile Controls Object Model MobileControl StyleSheet TextControl TextView ValidationSummary AdRotator Calendar PagedControl SelectionList Panel Image Link Label Command PhoneCall BaseValidator Form ObjectList List TextBox RequiredFieldValidator RegularExpressionValidator RangeValidator CustomValidator CompareValidator Form Panel Containers Text TextView Label TextBox Lists SelectionList List ObjectList Transfer PhoneCall Command Link Image AdRotator Image Calendar Calendar
  • Slide 8
  • ASP.NET Mobile Controls - Globalization internal character encoding is Unicode support for character set conversion to and from device character sets all controls are globalized display of localized control strings and exceptions requires: installation of a language pack (available in 21 languages) and/or Windows Server 2003 in the desired language
  • Slide 9
  • ASP.NET Mobile Controls - Globalization how to make your application culture-aware: CultureInfo ci = CultureInfo.CreateSpecificCulture(Request.UserLanguages[0]); System.Threading.Thread.CurrentThread.CurrentCulture = ci; System.Threading.Thread.CurrentThread.CurrentUICulture = ci; handling device character sets: configure in web.config section Content-Type:;charset=XXX overrides setting in configuration for request encoding how to use Accept-Charset: Response.ContentEncoding = Encoding.GetEncoding(Request.Headers["Accept- Charset"].ToString());
  • Slide 10
  • ASP.NET Mobile Controls - Localization how to localize applications add resource files (.RESX) to your project create a resource manager in Application_Start: ResourceManager LocRM = new ResourceManager("LocProject.strings", typeof(MobileWebForm1).Assembly); Application["rm"] = LocRM; use the resource manager to load string resources in a form: ResourceManager LocRM = (ResourceManager)Application["rm"]; this.Label1.Text = LocRM.GetString("txtLabel1"); alternatively persist your resource manager in the session state
  • Slide 11
  • ASP.NET Mobile Controls - Demo system requirements: Visual Studio.NET 2003 ASP.NET Mobile Controls Device Updates Openwave SDK 6.1
  • Slide 12
  • .NET Compact Framework - Overview lightweight version of the.NET Framework designed for resource-constrained devices online and offline supported by Visual Studio.NET 2003 two available programming languages: Visual C#.NET Visual Basic.NET major areas of.NET Compact Framework: base classes drawing/Windows Forms data/XML XML Web Service Client supported devices: Pocket PC 2000/Pocket PC 2002/Pocket PC Phone Edition any device based on Windows CE.NET 4.1 soon: Smartphone
  • Slide 13
  • .NET Compact Framework Class Subset System System.DataSystem.Xml System.Web Globalization Text Security Collections Resources Reflection Net IO Threading Diagnostics ServiceProcess Configuration Design ADO.NET SqlServerCe SqlClient Xslt/XPath XmlDocument Runtime InteropServices Remoting Serialization Serialization ConfigurationSessionState CachingSecurity Services Description Discovery Protocols UI HtmlControls WebControls System.Drawing Imaging Drawing2D Text Printing System.WinForms DesignComponentModel Reader/Writers
  • Slide 14
  • .NET Compact Framework- Globalization globalization support in System.Globalization culture support is factorized Pocket PC: world-wide English+CJK Windows CE.NET: WWE+CJK+Rest of World uses some data from underlying operating system (Windows CE): sort tables character property tables code page conversion tables CurrentCulture/CurrentUICulture are device-wide settings supports calendars based on the Gregorian calendar
  • Slide 15
  • .NET Compact Framework- Globalization character encoding internal character encoding is Unicode System.Text.Encoding supports all codepages provided by operating system mlang.dll character rendering fonts can be installed by application no complex script support (including bidirectional languages) conclusion: for connected applications convert data to culture-invariant form before it reaches the device
  • Slide 16
  • .NET Compact Framework - Localization full support for localization like in.NET Framework: class System.Resources support for managing multiple language resources in Visual Studio.NET no localized properties contained in the runtime managed exception strings are available in 10 languages reduce memory requirements for distribution using custom.CAB files emulator images in different languages can be installed for testing
  • Slide 17
  • .NET Compact Framework - Demo system requirements: Visual Studio.NET 2003 additional localized emulator images
  • Slide 18
  • Windows CE.NET 4.1.NET Compact Framework 1.0 add-on downloadable from the web customizing globalization support locale support codepages fonts input methods (IME, handwriting recognition, keyboard layouts) multi-lingual user interface operating system resources available in 12 languages
  • Slide 19
  • References ASP.NET mobile controls: Visual Studio.NET documentation Microsoft websites: http://msdn.microsoft.com/nhp/Default.asp?contentid=2800 1370&frame=true http://www.asp.net/http://www.asp.net/ (click on Mobile) W3C: XHTML: http://www.w3.org/TR/xhtml-basic/http://www.w3.org/TR/xhtml-basic/ cHTML: http://www.w3.org/TR/1998/NOTE-compactHTML- 19980209/http://www.w3.org/TR/1998/NOTE-compactHTML- 19980209/ Open Mobile Alliance: http://www.openmobilealliance.org/ http://www.openmobilealliance.org/ B4: Building a Multi-lingual, Multi-cultural Web Site with the Microsoft.NET Framework (Franois Liger)
  • Slide 20
  • References.NET Compact Framework Visual Studio.NET 2003 documentation GotDotNet: http://www.gotdotnet.com/team/netcf/ http://www.gotdotnet.com/team/netcf/ TA1: Internationalization Features of Microsoft.NET (Bill Hall) B3: Globalization with Microsoft.NET Framework (Franois Liger) Windows CE.NET 4.1 Windows CE.NET 4.1 documentation .NET Compact Framework 1.0 RTM download: http://microsoft.com/downloads/details.aspx?Famil yId=033AFC0E-B968-42F3-9A19- B2E71040F0F0&displaylang=en http://microsoft.com/downloads/details.aspx?Famil yId=033AFC0E-B968-42F3-9A19- B2E71040F0F0&displaylang=en