Inside and Out…

An attempt to understand technology better…

Archive for April, 2005

Screen Shot: Date Picker for SmartPhone 2003…

Posted by Gaurav Khanna on April 2, 2005

This is how the managed Date Picker, CalendarSP, looks like:

Advertisements

Posted in .NET Compact Framework, Development, Downloads, Windows CE/Windows Mobile | Leave a Comment »

CERapi – Determine connected device type…

Posted by Gaurav Khanna on April 2, 2005

I have added support in CERapi to determine the type of device (PocketPC, SmartPhone, etc) connected to via ActiveSync. The CESystemInformation class has a DeviceType property that will return a CEDeviceType enumeration value which indicates the type of device. The snippet below exemplifies this:

CESystemInformation si = rapi.SystemInformation;

// Device Type
Console.WriteLine(“You are connected with a {0}”,si.DeviceType.ToString());

And below is the output for my Typhoon:

Download the updated CERapi from http://www.wintoolzone.com/showpage.aspx?url=dotnet.aspx

Posted in .NET Framework, Development, Windows CE/Windows Mobile | Leave a Comment »

Managed Date Picker control for SmartPhone 2003 Platform

Posted by Gaurav Khanna on April 2, 2005

The .NET Compact Framework lacks a Date Picker control for the SmartPhone development platform. I have written CalendarSP that overcomes this limitation of the .NET CF and is targetted for the SmartPhone 2003 platform.

Its free to use and comes with complete documentation.

Download it from http://www.wintoolzone.com/showpage.aspx?url=dotnet.aspx

Posted in .NET Compact Framework, Development, Downloads, Windows CE/Windows Mobile | 1 Comment »

CERapi – Using CEFolder and CEFile

Posted by Gaurav Khanna on April 1, 2005

CERapi allows you to work with the file system of the Windows CE device and the snippet below shows how easy it is to do the same:

// Working with device folders

CEFolder rootFolder = newCEFolder(\\storage\\My Documents);
Console.WriteLine(“Path: {0}”,rootFolder.Path);
Console.WriteLine(“Total Files: {0}”,rootFolder.TotalFileCount);
Console.WriteLine(“Total SubFolders: {0}”,rootFolder.TotalSubFolderCount);

// Copy File from desktop
Console.WriteLine(“Move C:\\CASDEMO.TXT to device: {0}”,rootFolder.MoveFileFromDesktop(“c:\\CASDEMO.TXT”).ToString());
string
[] arrFolders = rootFolder.SubFolders;
foreach(stringstrFolder in
arrFolders)
Console.WriteLine(“SubFolder: {0} “,strFolder);

Console.WriteLine(“”);

string[] arrFiles = rootFolder.Files;
foreach(stringstrFile in
arrFiles)
Console.WriteLine(“File: {0} “,strFile);

Console.WriteLine(“”);

Console.WriteLine(“Parent Folder: {0}”, rootFolder.ParentFolder);
Console.WriteLine(“Archive: {0}”,rootFolder.IsArchive.ToString());
Console.WriteLine(“Created on: {0}”,rootFolder.CreationTime.ToString());
Console.WriteLine(“LastAccessed on: {0}”,rootFolder.LastAccessTime.ToString());
Console.WriteLine(“LastWritten on: {0}”,rootFolder.LastWriteTime.ToString());
Console.WriteLine(“Size: {0}”,rootFolder.Size.ToString());
Console.WriteLine(“OID on: {0}”,rootFolder.OID.ToString());
Console.WriteLine(“CreateFolder: {0}”,rootFolder.CreateFolder(“SubFolder”).ToString());
Console.WriteLine(“DeleteFolder: {0}”,rootFolder.DeleteFolder(“SubFolder”).ToString());

Download CERapi from http://www.wintoolzone.com/showpage.aspx?url=dotnet.aspx

Posted in .NET Compact Framework, .NET Framework, Windows API, Windows CE/Windows Mobile | Leave a Comment »

TIP: Whom are you connected with via ActiveSync?

Posted by Gaurav Khanna on April 1, 2005

There’s no programmatic way to determine if the Windows CE device connected via ActiveSync to the desktop is a PocketPC or a SmartPhone. If you wish to determine the same, open HKEY_CURRENT_USER\Software\Microsoft\Windows CE Services registry key and lookup the value of DeviceType value. Its a REG_SZ and contains the type of device you are connected with.

Posted in Tips, Windows CE/Windows Mobile | Leave a Comment »

CEFolder and CEFile – Working with the Windows CE device file system using CERapi

Posted by Gaurav Khanna on April 1, 2005

CERapi, the managed implementation for Windows CE Remote API (RAPI) has been updated to work with the file system of the Windows CE device. The CEFile and CEFolder classes have been introduced that make navigating the device easy. You can:

  • Get list of files in specified folder
  • Create/Delete folders
  • Create/Delete/Move files
  • Get folder/file attributes
  • File’s folder and its name – property
  • Create shortcut to files
  • Find files as per custom search filter
  • Set file attributes
  • Set filetime
  • Launch files from the device
  • Copy/Move files from desktop to device
  • Copy/Move files from device to desktop
  • Copy/Move files within device

Download the latest CERapi assembly with complete documentation from http://www.wintoolzone.com/showpage.aspx?url=dotnet.aspx

Posted in .NET Framework, Development, Downloads, Windows API, Windows CE/Windows Mobile | 1 Comment »