dotnetspider.com
Login Login    Register      

TutorialsForumCareer DevelopmentResourcesReviewsJobsInterviewCommunitiesProjectsTraining

Subscribe to Subscribers
Talk to Webmaster
Tony John

Facebook
Google+
Twitter
LinkedIn
Online Membersbaskar
profit22
srirama
Programmer
Padma
Matt M
More...
Join our online Google+ community for Bloggers, Content Writers and Webmasters




Resources » .NET programming » .NET Framework

Introduction to .NET Compact Framework


Posted Date:     Category: .NET Framework    
Author: Member Level: Bronze    Points: 5


This article gives an introduction to .Net Compact Framework



 


Introduction

.NET Compact Framework is a new computing platform from Microsoft for Mobile devices like Pocket PC. .Net Compact Framework is a proper subset of .Net Full Framework ie all programs coded in .Net Compact Framework works in Full framework.

.NET Compact Frameowrk supports Networking(sockets),Database Access(Sql CE), Graphics (GDI) ,Threadsand also allow you to call the native DLLs through DLL wrappers using P/Invoke. We cannot add the Com and Activex as in .Net Full Framework ie even to add a Date Time Picker Component we will have to call it through DLL wrappers.
.Net Compact Framework provides the same environment as Full Framework which helps the Desktop developers to code easily for Mobile Devices. We can code in C# or
VB.Net..Net Compact Framework is shipped with Visual Studio 2003. Also there is a builtin emulator for testing the apps coded in .Net Compact Framework. Emulator runs Windows Mobile 2002 Operating System. We can call the Windows CE(Comapct Edition) API calls from .Net Compact Framework. Instead of “kernal32.dll” in win32,
we need to use “core.dll” in Windows CE. We can call API functions vusing P/Invoke.

To begin with, take new project from the file menu of Visual Studio and select “Smart Device Application”. You’ll be asked the target, select “Pocket PC “and project type “Windows Application”. If you have a Pocket PC device, connect the device to the USB Port and set the target as Pocket Device. So when u run the app, it will be downloaded to the Device and will get executed. Now you will get a form as you get in Full Framwork Windows Application. There are a number of Device Controls like buttons, tab page, imers etc which can be dragged and dropped. Now when you press ctrl F5, the app runs in the Pocket PC Emulator.

To configure the emulator, go to Tools->Options->Device Tools->devices->Pocket Pc Emulator->configure. Here you can adjust the display, ram, serial/parallel ports. For port communication, it’s better to use the actual device because emulators usually don’t work. I tried serial port communication but the emulator hangs. Also you need minimum 256 MB Ram for the emulator to work well.The device controls have limited option like Device Button Properties has limited options like it has a fixed style etc. We can access files and images in .Net Compact Framework by adding the files and images in the project. So when the App is deployed, these files will be downloaded in to the emulator or device. Another way to copy into the emulator is by sharing the files.We can access the shared files in the system from the emulator just like accessing a files from a remote system. We can see the shared folders. The detail of accessing the shared resources is explained in my next article about “Windows Mobile Operating System”.

Device Controls

  • Button
  • MainMenu
  • NumericUpDown
  • ComboBox
  • Panel
  • ContextMenu
  • PictureBox
  • DataGrid*
  • ProgressBar
  • DomainUpDown
  • RadioButton
  • FileOpenDialog
  • StatusBar
  • HScrollBar
  • TabControl
  • ImageList
  • TextBox
  • Label
  • Timer
  • ToolBar
  • TreeView
  • VScrollBar
  • ListBox
  • ListView
  • FileSaveDialog
  • CheckBox

    Unsupported Controls

  • GroupBox
  • RichTextBox
  • Notification Bubble
  • Print Controls

    Unsupported Control (Not available in Windows CE)

  • CheckedListBox
  • ColorDialog
  • ErrorProvider
  • HelpProvider
  • LinkLabel
  • NotifyIcon
  • ToolTip
  • Splitter
  • FontDialog

    Emulators can save their state. So after the first deployment of application, if the state is saved, the .Net Compact Framework components will not be downloaded again.

    Summary

    If you want to create applications for your mobile devices, .NET Compact Framework is the best one available.





  • Did you like this resource? Share it with your friends and show your love!


    Responses to "Introduction to .NET Compact Framework"
    Author: Brainstorming Guy    19 Nov 2004Member Level: Gold   Points : 0
    Hai,
    Nice article about the Smart Device Applications. It gave us a bried introduction about .NET Compact Framework.
    Note for Developers :
    One more thing, since the Compact Framework doesn't have as flexible as Windows Application, please hold on developing Smart Device Applications. Major enhancements are under developement, and in the next version of .NET u can expect a lot.

    Regards,
    Brainstorming Guys



    Feedbacks      

    Post Comment:




  • Do not include your name, "with regards" etc in the comment. Write detailed comment, relevant to the topic.
  • No HTML formatting and links to other web sites are allowed.
  • This is a strictly moderated site. Absolutely no spam allowed.
  • Name:   Sign In to fill automatically.
    Email: (Will not be published, but required to validate comment)



    Type the numbers and letters shown on the left.


    Next Resource: Thread Communication Using Wait(), Pulse() and PulseAll()
    Previous Resource: Introduction to reflection in C#
    Return to Resources
    Post New Resource
    Category: .NET Framework


    Post resources and earn money!
     
    More Resources
    Popular Tags   Tag posting guidelines   Search Tags  
    (No tags found.)



    Follow us on Twitter: https://twitter.com/dotnetspider

    Active Members
    TodayLast 7 Daysmore...

    Awards & Gifts
    Email subscription
  • .NET Jobs
  • .NET Articles
  • .NET Forums
  • Articles Rss Feeds
    Forum Rss Feeds


    About Us    Contact Us    Copyright    Privacy Policy    Terms Of Use    Revenue Sharing sites   Advertise   Talk to Tony John
    Copyright © SpiderWorks Technologies Pvt Ltd., Kochi, India
    2005 - 2012 All Rights Reserved.
    .NET and other trademarks mentioned in this site belong to Microsoft and other respective trademark owners.
    Articles, tutorials and all other content offered here is for educational purpose only.
    We are not associated with Microsoft or its partners.