using.net skills to build mobile applications in compact framework punit shah technical lead |...

22
Using .NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft [email protected] | http://blogs.msdn.com/punit

Upload: tabitha-alaina-manning

Post on 24-Dec-2015

218 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

Using .NET Skills To Build Mobile

Applications In Compact Framework

Punit ShahTechnical Lead | Microsoft [email protected] |

http://blogs.msdn.com/punit

Page 3: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

What is .NET Compact Framework?

.NET Framework

.NET Compact Framework

Page 4: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

What is .NET Compact Framework? Lightweight version of .NET Framework

Designed for resource-constrained devices

Compatible with VS.NET, C#, VB.NET

Runs applications securely on-device

High performance JIT compiler

Page 5: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

What is .NET Compact Framework? Guarantees robustness and security

Highly interactive, offline, and networked

experiences

Makes it easy to consume web services

Tunable size and performance

Page 6: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

Calculator Application Sample using .NET CF

DEMO

Page 7: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

.NET CF – Design Goals

Small CLR for Devices

Leverage VS to design, develop & debug

Web Service Access on Devices

Run seamlessly with the OS on the devices

Single binary deployment for all Pocket PC

and Windows CE .NET CPUs

Enhanced developer productivity using .NET

Compact Framework and Visual Studio .NET

Page 8: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

.NET Framework

System

System.Data System.Xml

System.Web

Globalization

Text

Security

Collections

Resources

Reflection

Net

IO

Threading

Diagnostics

ServiceProcess

Configuration

Design

ADO.NET

SqlServerCe

SqlClient

Xslt/XPath

XmlDocument

RuntimeInteropServices

Remoting

Serialization

Serialization

Configuration SessionState

Caching Security

ServicesDescription

Discovery

Protocols

UIHtmlControls

WebControlsSystem.Drawing

Imaging

Drawing2D

Text

Printing

System.WinForms

Design ComponentModel

Reader/Writers

Page 9: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

.NET Compact Framework

System

System.Data System.Xml

System.Web

Globalization

Text

Security

Collections

Resources

Reflection

Net

IO

Threading

Diagnostics

ServiceProcess

Configuration

Design

ADO.NET

SqlServerCe

SqlClient

Xslt/XPath

XmlDocument

RuntimeInteropServices

Remoting

Serialization

Serialization

Configuration SessionState

Caching Security

ServicesDescription

Discovery

Protocols

UIHtmlControls

WebControlsSystem.Drawing

Imaging

Drawing2D

Text

Printing

System.WinForms

Design ComponentModel

Reader/Writers

Page 10: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

.NET CLR Common Features

Verifiable type safe execution No uninitialized variables, unsafe casts, bad array

indexing, bad pointer math

Garbage Collection No ref-counting, no leaks

JIT compilation

Error handling with exceptions

Common type system Call, inherit, and source-level debug across different

languages

Page 11: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

Compact CLR Differences

COM Interop Good support for calling native DLLs

Support for calling a COM object through DLL

wrappers

No support for writing a COM / ActiveX object

No Install-time JIT (nGen) / No Reflection Emit

No Remoting / Client web services is fully

supported

No Generic Serialization

Datasets can be serialized to XML

Subsets of other areas of functionality

Page 12: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

Developing Games for Smart Device App using .NET CF

DEMO

Page 13: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

.NET Framework CLR Size

Framework size (RAM or ROM)

~1.5 MB

Running RAM needs

1 MB+ (depends on app)

Typical application sizes

5 - 100 KB

Apps often smaller due to use of platform

features in the framework

Page 14: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

.NET Compact Framework - Features Base Classes

Data/XML

XML Web Service Client

Threading

Native Code Interop

Globalization

Windows Forms Support

Page 15: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

Mobile Controls for ASP.NET

Write-once mobile web pages From a single code base target multiple devices

Support for a variety of devices Web enabled Cell Phones, PDAs and Pagers

Support multiple mark-up languages WML1.1 (WAP); cHTML 1.0, HTML, XHTML

Customizable and extensible framework Add new controls and support for new devices

Integrates with Visual Studio.NET World-class development tool

Page 16: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

Power Toys for .NET CF

Remote Performance Monitor and GC Heap

Viewer

.NET CF CLR Profiler

App Configuration Tool (NetCFcfg.exe)

.NET CF ServiceModel Metadata Tool

Remote Logging Configuration Tool

.NET CF Network Log Viewer

Page 17: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

Walkthrough: Automated SMS Reply using .NET CF

DEMO

Page 18: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

Summary

Leverage your knowledge and build device

apps!

Desktop framework & tools

.NET languages (C#, VB .NET)

Choose the appropriate project template

Compile, Debug, and Deploy in Visual

Studio .NET

Page 19: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

References

Windows Mobile Dev Centre:

http://msdn.microsoft.com/mobility

.NET CF Dev Guide:

http://msdn.microsoft.com/en-us/library/f44bbwa

1.aspx

Samples:

http://msdn.microsoft.com/en-us/library/bb3978

51.aspx

Page 20: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

Feedback/Q&A

Your Feedback is important to us.

Please take a few moments to fill out our

online feedback form

Use the Question Manager on LiveMeeting to

ask your questions now!

Page 21: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

Contact

Email: [email protected]

Blog: http://blogs.msdn.com/punit

Page 22: Using.NET Skills To Build Mobile Applications In Compact Framework Punit Shah Technical Lead | Microsoft punits@microsoft.com |

© 2007 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.

The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after

the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.