.NetCompactFrameworkAMostlyStraightPath,butwithSomeInterestingCurvesRichardKuciaKuciaAssociates440-892-3838rjkucia@att.net2003.09.09汽车防盗器:MobileDevicesTheSameFramework–but“optimized”IntegratedintoVS.Net2003Formerly:“SmartDeviceExtensions”.NETCFDesignGoalsPortableandsmall.NETCLRfordevices–EnableVisualBasic®andC#LeverageVisualStudio®.NET–Runmanaged.EXEsand.DLLsdirectly–DebugwithVisualStudio.NETEnablerichclientWebServicesandlineofbusinessapplicationsondevices–Classlibsforforms,drawing,storage,net,dataaccess,XMLPeacefullyco-existwithhostOS–Runonnativethreads,P/InvoketocallnativecodeTarget:MobileDevicesCompaq,HP,Dell,Toshiba,…PocketPC2000,2002WindowsMobile(akaPPC2003)–.NetCFinROM!WindowsCESmartPhoneNoPalm/HandspringTheFramework–“Optimized”20mb1.5mbTruesubset–nobreakingchangesSamelanguages,samecode,sameMSILMultipletargetCPUsHowRichistheWorkingEnvironment?CLRJITGarbageCollectionTypesafety;exceptionsThreadingWindowsOS(PInvoke)SQLServerCEincludingreplicationActiveSyncRemoteViewerWebServicesSockets/StreamsADO.NetGraphics.NETFrameworkSystemSystem.DataSystem.XmlSystem.WebGlobalizationTextSecurityCollectionsResourcesReflectionNetIOThreadingDiagnosticsServiceProcessConfigurationDesignADO.NETSqlClientXslt/XPathXmlDocumentRuntimeInteropServicesRemotingSerializationSerializationConfigurationSessionStateCachingSecurityServicesDescriptionDiscoveryProtocolsUIHtmlControlsWebControlsSystem.DrawingImagingDrawing2DTextPrintingSystem.WinFormsDesignComponentModelReader/Writers.NETCompactFrameworkSystemSystem.DataSystem.XmlSystem.WebGlobalizationTextSecurityCollectionsResourcesReflectionNetIOThreadingDiagnosticsServiceProcessConfigurationDesignADO.NETSqlServerCeSqlClientXslt/XPathXmlDocumentRuntimeInteropServicesRemotingSerializationSerializationConfigurationSessionStateCachingSecurityServicesDescriptionDiscoveryProtocolsUIHtmlControlsWebControlsSystem.DrawingImagingDrawing2DTextPrintingSystem.WinFormsDesignComponentModelReader/WritersAgendaWhatisthe.NetCompactFramework?DevelopinginaCompactWorldInclusionsandExclusionsExamplesDevelopinginaCompactWorldVS.Net2003installationoptionC#,VB.NetTrueon-devicedebugging–Ifyoucangetitconnected…EmulatorDeploymentDevelopinginaCompactWorldVS.NETIntegrationTemplatesfordevicesinNewProjectdialog–TemplatesetsdeviceandprojecttypeTemplatetypes–PocketPCApplication–PocketPCClassLibrary–PocketPCControlLibrary–WindowsCE.NETApplication–MobilePhoneApplicationDefaultsetofreferencesthatareappropriateforyourplatformDevelopinginaCompactWorldOverviewofControlsUseWindowsFormsDesignerDrag-and-drop,property-basedRichsubsetofdesktopcontrols–UserInterfacecontrolsDataEntryDisplay–Formatting&RADcontrolsOrganizationalcontrolsHelpercontrolsDataEntryCheckBoxComboBoxCommandButtonDomainUp/DownListBoxNumericUp/DownRadioButtonTextBoxTrackBarDisplayLabelPictureBoxProgressBarStatusBarHelperContextMenuScrollBarsImageListMainMenuOpen&SaveFileDialogsTimerToolBarOrganizationalListViewPanelTabControlTreeViewDevelopinginaCompactWorldSubsetofDesktopControlsControlsNotSupportedCheckedListBoxDataGridDateTimePickerGroupBoxMonthCalendarSplitterDevelopinginaCompactWorldCustomizingEmulatorSettingsFullyFunctionalPocketPC2002OSEmulatorOptionstochangedeviceconfigurationsandconnectivity–Resolution&ColorDepth–Memory–COM&LPTports!DevelopinginaCompactWorldDeploymentSameuserexperienceasdesktopCompilesapplicationfordeviceOutputWindowusedfordeploymentmessagesVisualStudiodeploystheframeworktodeviceifneededAgendaWhatisthe.NetCompactFramework?DevelopinginaCompactWorldInclusionsandExclusionsExamples.NETCompactFrameworkWhat’sDifferent?Specificperformanceissues–XML–Formloading–SQLServerCEEmphasisonFileSizeEmphasisonMemoryFootprint.NETCompactFrameworkWhat’sDifferent?ControlsunimplementedControlpropertiesremovedControlpropertiesunimplementedMethodoverloadsremovedNoConsoleorDebugobjectsNoSerialPortsupport.NETCompactFrameworkWhat’sDifferent?Form-factorandGUIguidelineissuesNoMDIapplicationsNoActiveXcontrolsinformsApplicationsthatdon’treallycloseOpen/Savedialogfor“\MyDocuments”Nofilesystem(C:/?).resxfileformat.NETCompactFrameworkWhat’sDifferent?Can’tdeploytosubdirectoriesNoMergemodules“MyCompany”.cabfilesNopre-compiling(NGen).NETCompactFrameworkWhat’sDifferent?NodesignerforcustomcontrolsNosupportforPocketAccessNosupportforPocketOfficeExpensivelicensingforSQLServerCE.NETCompactFrameworkWhat’sDifferent?Debugging:remarkableyetfrustratingSingle-in,step-thruCommandWatchBreakpointNoConsoleorDebugobjectsNo“setnextinstructiontoexecute”.NETCompactFrameworkWhat’sDifferent?ReflectionEmitRemotingSerializationCodeDomPrintingCOMInteroperabilityServersidefunctionalityXPath/XSLTAgendaWhatisthe.NetCompactFramework?DevelopinginaCompactWorldInclusionsandExclusionsExamplesForMoreInformation…MSDNWebsiteat–msdn.microsoft.comHow-ToResourcesSimple,Step-By-StepProceduresEmbeddedDevelopmentHow-ToResourcesGeneralHow-ToResourcesintegrationHow-ToResourcesJScr