Get Updates VIA E-mail

Enter your email address:

Thursday, August 14, 2008

Best Windows Mobile Programming Tips and Techniques

The survey is divided into three parts covering Pocket PCs, Pocket PC Phone Editions, and Smartphones, though the questions are the same in each section. Comments have been edited for brevity and clarity.

Here's what the developers said:

Windows Mobile Pocket PC

What are the most useful software/programming tools you use when developing Pocket PC applications?

Hands down, Visual Studio has to be the best tool for developing Pocket PC applications. I use it exclusively and would not want to create apps any other way. The emulator goes a long way toward giving you instant feedback on how the application is going to look and behave on the device. While the emulator can not replace running the application in the actual environment, it does save a lot of time and headaches, and speeds up development because you don't have to transfer your application to the device for testing each time.


I use two sets of tools: Visual Studio .NET 2003 is great for developing applications quickly, for UI design, and for most general purpose development. I use Embedded Visual C++ 4.0 (SP3) for system extensions in C++, but it comes with a really useful set of tools for remote working on a device, like Remote Registry Editor and Remote Spy++ etc.

In addition to these I use SOTI remote Control software and a couple of freeware tools like on-device registry editing.

Visual Studio .NET is the best programming tool for the mobile enterprise solutions we develop in our company. Its advanced environment supporting a powerful form designer allows us to do the customization of our projects in a very simple way. Moreover it provides many new technologies, such as Web services, that were not allowed in the old eVB which we used to use before.

Visual Studio.NET 2003 enables a wide variety of applications to be built, all from within the one integrated environment. It has great features that let me debug while I'm testing my app on the actual device. Also, grab the latest PocketPC SDK 2003 from Microsoft Downloads, as this gives you emulators for the latest devices and supports VGA displays.

What are your favorite techniques/approaches/tricks that make developing Pocket PC applications easier/faster/better?

One of the things I have come to rely on is testing code on a real device. Yes, the emulator running on my PC is a very close match to the device (and its even better in Whidbey!), but I still prefer to have a physical device with a separate processor and its own memory to run my code. This allows me to use my PC separately, at full speed, for compile and debug.

I also tend to use two displays attached to my PC when coding. I have Visual Studio open on one display and the other is for help / web pages/ command prompt etc. I find this makes me significantly more productive.

Samples! Samples! Samples! You can never have enough of them. I keep all the code snippets I write, as well as Pocket PC / Smartphone SDK samples, and catalogue them for easy access. These are always useful.

Finally, it's not always what you know that counts—it's often more important to know who to ask. I keep a long list of web sites and maintain a list of active community contacts so that I can ask an expert ?'how to solve a particular problem.

I use static forms, threading, and also re-write Visual Studio Designer-generated code to improve performance. OpenCF has also been a big help with their code library and user forum. They have contributed beautifully to the Pocket PC community through the support and expansion of the Compact Framework.

Try and re-use as much of your previous work as possible. Also, keep each stage of the solution simple. I use classes to solve the smaller problems. This gives me greater flexibility to choose when and where I use those classes (and in which projects).


Friday, July 25, 2008

Depression

First Things First: This Is Not Your Fault and It Can Be Treated

The first step to overcoming the devastating effects of depression is to see it as a disease, not a personal failing. Like other chronic diseases, depression wreaks havoc on the person who suffers as well as on her or his friends and family. The social costs are also huge: Depression is a leading cause of disability worldwide. However, there is a lot of positive news about depression treatment.

How Exercise May Boost Your Mood

Exercise seems to be particularly important for some people. In a 2007 study in the journal Psychosomatic Medicine, depressed people who were engaged in an exercise program recovered about as well as people who took medication. Both groups did better than a third group that got only a placebo.

What kind of exercise will lift your mood?
While regular exercise may be as effective for mild or moderate depression as antidepressants, there is a big catch, one that triathlete Peatick has figured out: It has to be intense, for at least 30 minutes, according to Madhukar Trivedi, MD, professor of psychiatry and head of the Mood Disorders Research Program and Clinic at University of Texas Southwestern Medical Center in Dallas. He has authored several studies that show regular exercise can reduce depressive symptoms—in one case by up to 47%.

Exercise is good, but is it an antidepressant?
No one doubts that exercise is beneficial to general health and well-being, but Ken Robbins, MD, clinical professor of psychiatry at the University of Wisconsin–Madison, isn't convinced that it can help anyone with moderate or severe depression.

He recently reviewed all of the exercise and depression studies, and concluded that while working out regularly is a great idea, it is hard for most people to comply with it. "Also, there are a ridiculous number of variables here. We don't know if it was the socialization, the light, or just getting these people out of the house that helped.

"Nonetheless, of the few things that someone with depression can do besides antidepressants and therapy, this is something we can tell them to try."