Windows Phone Thoughts - Daily News, Views, Rants and Raves

Check out the hottest Windows Mobile devices at our Expansys store!


Digital Home Thoughts

Loading feed...

Laptop Thoughts

Loading feed...

Android Thoughts

Loading feed...




Go Back   Thoughts Media Forums > WINDOWS PHONE THOUGHTS > Windows Phone Developer

Reply
 
Thread Tools Display Modes
  #1  
Old 11-21-2003, 10:40 AM
Andy Sjostrom
Pontificator
Join Date: Aug 2006
Posts: 1,177
Default More .NET Compact Framework Sample Code

Microsoft has recently published a number of additional code sample downloads built using .NET Compact Framework. Download and store away to your own "tool box" of good-to-have utilities!

Performance Counter - This sample demonstrates how to P/Invoke the QueryPerformanceFrequency and QueryPerformanceCounter functions to create a high resolution timing solution.

Splash Screen - This sample demonstrates how to create a splash screen form on a separate thread from the main form. The splash screen will periodically update a "busy" animation and shut down when either the form has finished loading or a specified amount of time has elapsed, whichever comes last.

Stopping Threads - The code in this sample resides in a single Form and demonstrates how to safely shut down a Form with multiple threads running. The Form contains a single button which launches a new thread. Each thread subsequently sits in an infinite loop invoking a counter updating function and waiting for a close request. When the application is closed, the main form waits until all threads are removed before shutting down.

Save Bitmap - This example demonstrates how to load a bitmap from a file, draw it to a surface, allow the user to modify it, and then save it to a file. In the .NET Compact Framework, there is no simple method for saving Bitmap objects or getting a bitmap handle from a Bitmap object so it is necessary to use a bit of trickery to access a bitmap's pixel data. This example will access a bitmap's pixel data through a device context created from an editor control.

Performance Measurement - Learn how to measure and tune the performance of your Microsoft� .NET Compact Framework-based applications.

Bitmap Copy - This sample demonstrates two Copy functions for copying Bitmap objects. The first function returns a Bitmap object containing a specified region of a source Bitmap object. The second returns a Bitmap object which is a copy of the original source Bitmap object.

Power Status - This sample demonstrates how to P/Invoke the GetSystemPowerStatusEx and GetSystemPowerStatusEx2 functions, each of which fill a SYSTEM_POWER_STATUS_EX and SYSTEM_POWER_STATUS_EX2 class respectively. These classes contain information about the batteries and power status of the device.

MSI that Detects Framework Version - This sample describes how one might create an MSI package which can detect the presence of the Microsoft .NET Compact Framework on a device, determine if the device needs to be upgraded with a newer version, and install or upgrade the Framework along with an application.
 
Reply With Quote
  #2  
Old 11-22-2003, 12:04 AM
Flynn Arrowstarr
Pupil
Join Date: Apr 2003
Posts: 30

Hi, Andy

Could you post links to the articles as well? Thanks

Flynn
__________________
If you can't corrupt the youth of today, the adults of tomorrow won't be any fun...
 
Reply With Quote
  #3  
Old 11-22-2003, 06:00 AM
William Yeung
Intellectual
Join Date: Dec 2002
Posts: 135

I got a bit complaint to MS... when they will finally realize everytime when they release a patch they should do an XIP instead of a in memory one?
 
Reply With Quote
  #4  
Old 11-26-2003, 05:39 AM
cesarfong
Ponderer
Join Date: Nov 2006
Posts: 105

andy thanks for the links!!! 0X 0X 0X
 
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 09:21 PM.