Thanks to all who attended last night’s (Wednesday, April 19th) meeting of Club Pocket PC – Boston. The PowerPoint slides for my presentation, entitled “Programming Outlook Mobile with the .NET Compact Framework and Windows Mobile 5.0” , are now available for download from the BostonPocketPC.com web site.
For this presentation, I used the same sample application I used for the previous week’s Boston .NET User Group presentation (which includes Outlook Mobile sample code and a whole lot more). That Visual Studio 2005 C# project can also be found at the BostonPocketPC.com web site.
After a far-too-long hiatus, Thom Robbins and I have finally gotten back on track with the Mobile Devcasters Show. Episode 5 is now available for download at the Mobile Devcasters web site –
“In this episode, Thom and Don play a little “catch-up”, discussing upcoming major Windows Mobile developer events and some changes to the Mobile Devcasters Show. The main topic of the episode is Mobile Connected Application development, with Thom and Don talking ASP.NET 2.0, mobile web considerations, best practices and tips.”
The “changes” we discuss are something that should have you subscribing to our RSS feed (if you have not already done so). Be sure to check it out!
Thanks to everyone that attended my presentation (Leveraging the New Windows Mobile APIs) to the Boston .NET User Group earlier this evening. As promised, the PowerPoint slides and C# sample application demonstrating the new Windows Mobile 5.0-specific managed APIs are both available at the BostonPocketPC.com web site.
On April 6th, 2006, Microsoft (via a SQL Server 2005 Update from Paul Flesner) announced a “new” product in the Microsoft SQL Server family – SQL Server Everywhere Edition (or “SQL Everywhere” for short, or “SQL/e” for shorter). At the time, I chose not to post about it until more official word came out. I did this for two reasons –
- My unofficial word would be just that – unofficial. Better to hear more information direct from the source;
- I would have to type a lot less if I simply pointed people in the right direction 😉
Microsoft’s own Steve Lasker has put together a good FAQ regarding SQL/e on his MSDN blog. In short, SQL/e is essentially SQL Mobile without the desktop limitations. As you may or may not be aware, SQL Mobile was authorized for use in developing Tablet PC applications as well as Windows Mobile applications. That was the extent of “desktop” deployment, however. This new structure allows for SQL Mobil… er, SQL/e to be used as an embedded database in any Microsoft OS environment.
Personally, I applaud this decision. I know that when the decision to allow Tablet PC deployments but not others first came out, a lot of folks in the .NET CF and Embedded MVP communities thought an broader expansion would be a good thing. Obviously, Microsoft listened (to MVPs and others) and responded. This change opens a number of possibilities for occasionally-connected application developers.
BTW – Steve Lasker has also posted about leveraging SQL/e in Visual Studio 2005 development. Really great article with useful information.
Thanks to everyone for attending today’s .NET Speech Server Day at the Microsoft offices in Waltham. As promised, my PowerPoint slides from the presentation can now be downloaded from the BostonPocketPC.com web site.
Talk about a nice deal! AP is reporting that the U.S. Census Bureau has signed a 5-year, $600 million contract with Harris Corporation for data collection for the 2010 census that includes the deployment of Windows Mobile devices in the field by census takers –
The portable devices are being designed to allow census workers to immediately record information they gather when going door-to-door to American households, said Monty Wood, a spokesman for the Census Bureau.
While the devices (which will be manufactured by Taiwan’s HTC) are critical for the collection of census data, they will not be used for other functionality (PIM, e-mail, etc). This will remain with the Census Bureau’s RIM Blackberry devices –
Wood said the devices will not be used as cell phones or for other functions such as sending e-mail, and will not replace bureau employees’ BlackBerry communicators.
“It’s not like a BlackBerry,” he said. “It’s specified designed for the census 2010 application.”
And here I was, getting worried that there weren’t enough large-scale enterprise deployments of Windows Mobile devices for custom application usage… 😉
Source: Yahoo! News
UPDATE: According to a Bloomberg article (spotted at Smartphone Thoughts – thanks, Mike!) , the deal equates to 500,000 devices (and an equal amount of Windows Mobile 5.0 licenses for Microsoft).
Some of you may or may not already know that the upcoming Motorola Q and Samsung i320 Windows Mobile 5.0 Smartphones have a couple of unique properties. First, they provide 320×240 screens. Second, they can function in landscape mode. Both of these capabilities pose new challenges to .NET Compact Framework developers.
Microsoft is now providing a new emulator image for developers. This new download adds a Smartphone emulator with both 320×240 dimensions and landscape support. In order to use this image, you must have Visual Studio 2005 and the Windows Mobile 5.0 SDK for Smartphone already installed. It is recommended that all Smartphone application developers download and install this image in order to test your existing applications.
What better way to follow up to my post on the Compact Framework / Windows Mobile 5.0 MessageInterception API than with a simple working sample? You can download this zip file from BostonPocketPC.com that contains a working Visual Studio 2005 project. The sample is targeted at a Windows Mobile 5.0 Smartphone, so you will also want to have the Windows Mobile 5.0 Smartphone SDK installed.
Simply compile the code and run! The application uses the right softkey to send an SMS to the “magic phone number” (+14250010001). Once sent, if the SMS is not modified (you have a chance to edit it before sending), the SMS will “boomerang back” to the emulator and (because it meets MessageCondition criteria) display an alert. The source code is also heavily commented for your reading pleasure 😉
I don’t normally post on this kind of stuff, but this is just too good to let slide by…
Amazon.com has the new T-Mobile USA SDA Smartphone (for those who follow this, the SDA is code-named by HTC as “Tornado”) with Windows Mobile 5.0, EDGE, WiFi and a nice QVGA screen for only $29.99 with service activation and a $200 rebate. I know, I know – You have to wait for the rebate and you have to sign a contract with T-Mobile USA. At $29.99 (did I mention free shipping, too?), this might just be worth the “pain points” 🙂
It’s times like this that I regret reading the RSS feed from Techbargains.com (thanks to them for pointing this deal out).
Following up on my “why” post to using the new managed SMS Interception namespace with Windows Mobile 5.0 devices, I thought it might be a good idea to demonstrate the ease of implementing this type of functionality. In other words, show “how” in addition to “why” 😉
To use the SMS message interception, perform the following steps –
- In your Smart Device project, add references to to Microsoft.WindowsMobile, Microsoft.WindowsMobile.PocketOutlook and Microsoft.WindowsMobile.PocketOutlook.MessageInterception. It would also be a good idea to add these to your code with using statements.
There are two major objects you will be working with here. The MessageInterceptor (responsible for actual interception) and the MessageCondition (and object that sets up the criteria for messages to intercept). You will need to create instances of these two objects in the containing class.
// For SMS Message Interception…
private MessageInterceptor _SMSCatcher = new MessageInterceptor(InterceptionAction.NotifyAndDelete, true);
// For setting up the message filter…
private MessageCondition _SMSFilter = new MessageCondition();
The constructor for MessageInterceptor has two significant arguments. The first allows you to define an interception action (what to do when a message is intercepted). Typically, these messages do not need to been directly seen or stored, so the NotifiyAndDelete enumeration of the InterceptionAction enumerator works well. The second argument sets whether or not to use the current form’s thread. Usually, this is set to true, but if your application does not have a form, it would be set to false.
You will want to set up an event handler and event method for taking action when the event occurs. To do this, you will set up an event handler for the MessageReceived event of the MessageInterceptor. The standard Visual Studio functionality (using TABs to create the event handler and associated method) work here.
//SMS Message Interception event handler…
_SMSCatcher.MessageReceived += new MessageInterceptorEventHandler(_SMSCatcher_MessageReceived);
You will need to set up the MessageCondition object with the necessary filters/criteria and assign it to the MessageInterceptor.
//SMS Message Filter setup…
_SMSFilter.Property = MessageProperty.Body;
_SMSFilter.ComparisonType = MessagePropertyComparisonType.StartsWith;
_SMSFilter.CaseSensitive = true;
_SMSFilter.ComparisonValue = “OutlookMobileDemo”;
//Assign the filter to the Interceptor…
_SMSCatcher.MessageCondition = _SMSFilter;
The Property property (redudant redundacy intended) is set to one of several values that represent what part of the message will be queried for the filter; the body of the message, the message class (technically, you can use transports other than SMS), the sender or the subject. For SMS, the Body or Sender enumerations are most commonly used. The ComparisonType property is used to describe what kind of comparison should be made (StartsWith, EndsWidth, Contains, Equal or NotEqual) to the Property selected. This is really up to you and your application needs. The CaseSensitive property can be used to further refine the selection criteria, and the ComparisonValue property is the actual text to use for comparison.
Now, all you have left to do is to write your event code! I think it’s important to note that the MessageInterceptorEventArgs object passed to the event handler contains the entire SMS message in it’s Message property. By casting this property to an SmsMessage object, you can query all of the SMS message’s information. As an example, I commonly demo the process in action by displaying a notification message (using the Notification control) to the user –
void _SMSCatcher_MessageReceived(object sender, MessageInterceptorEventArgs e)
//Event args pass the SMS message…
SmsMessage mySMS = (SmsMessage)e.Message;
//Show a notification popup…
this.notifyCustomIncoming.Caption = “New SMS”;
this.notifyCustomIncoming.InitialDuration = 60;
this.notifyCustomIncoming.Text = “Got the special SMS! – “ + mySMS.Body.ToString();
this.notifyCustomIncoming.Visible = true;