Using Subversion as a Deployment Tool

by Mark Milec 5/7/2008 2:35:00 AM

From http://weblogs.asp.net/sjoseph/archive/2008/05/05/subversion-as-a-deployment-tool.aspx

  1. Create a production/live build folder in your source tree and add it to the repository.
  2. Modify our build system to create the live builds in this folder and commit to the repository.
  3. On the live server the site is deployed as a checkout of the live build folder.
  4. Once the build passes unit tests and QA all we need to deploy is to update the working copy on the live server. The big advantage here is that rollbacks etc. are automatically handled because we can always roll back to a previous version. Also you get a nice history of all the updates to the live server.

 

  

Currently rated 1.5 by 2914 people

  • Currently 1.49922/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags:

Day-to-day with Subversion

by Mark Milec 5/7/2008 2:28:00 AM

Here's an excellent post on Tagging and Branching in Subversion 

http://weblogs.asp.net/bsimser/archive/2008/05/06/day-to-day-with-subversion.aspx

Currently rated 1.0 by 5 people

  • Currently 1/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags:

SQL ConnectionString Application Name Property

by Mark Milec 4/24/2008 3:54:00 AM

When you have several .net applications or websites connecting to the same database, they all show up in SQL Profiler with the same Application Name ".Net SqlClient Data Provider". I just learned that you can add an Application Name property to the connection string so you can make a unique name for each application.

connectionString="Data Source=MyServer;Initial Catalog=MyDatabase;Persist Security Info=True;User ID=MyUserName;Password=MyPassword;Application Name=My Application"

Currently rated 1.5 by 453 people

  • Currently 1.490067/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags: ,

Configuration Settings in .net CF

by Mark Milec 4/7/2008 9:27:00 AM

The .NET Compact Framework does not offer the built in capability to access the App.Config settings file like the full framework does.  This post: http://www.eggheadcafe.com/articles/dotnetcompactframework_app_config.asp shows how to load the config file as an XmlDocument and get a NameValueCollection from it.

Currently rated 1.5 by 219 people

  • Currently 1.504587/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags:

Global Exception Handling in C#

by Mark Milec 4/7/2008 9:10:00 AM

I've been using the Application_Error event in ASP.NET as a global exception handler for a while.  While looking for a way to implement something similar for Windows Forms I found this post: http://blogs.msdn.com/tom_krueger/archive/2005/02/17/375602.aspx   explaining how to use Application.ThreadException to do just that.

I then found out that Application.ThreadException is not available in the .net Compact Framework but as explained here: http://www.danielmoth.com/Blog/2004/12/appdomainunhandledexception-part-1.html, AppDomain.CurrentDomain.UnhandledException can be used to accomplish the same thing.

There are some problems with using AppDomain.CurrentDomain.UnhandledException as explained here: http://www.codinghorror.com/blog/archives/000201.html

Currently rated 1.0 by 7 people

  • Currently 1/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags: ,

Checking if the backlight is active

by Mark Milec 4/7/2008 8:54:00 AM

When the backlight is inactive on a Symbol 9090G, a keypress activates the backlight, but it also acts as a regular keypress.  This was causing a problem for the users of my application so I needed to check if the backlight was active so I can ignore the keypress if it's inactive.  The solution was easy with the help of the Symbol SDK.

using Symbol.Display; 
public class ScreenHandler {
  public static bool IsBacklightOn {
    get {
      bool returnValue;
      StandardDisplay display = null;
      foreach (Device device in Device.AvailableDevices) {
        if (device.DisplayType == DisplayType.StandardDisplay) {
          display = new StandardDisplay(device);
        }
      }
      if (display == null) {
        returnValue = false;
      } else {
        returnValue = display.BacklightState == BacklightState.ON;
        display.Dispose();
      }
      return returnValue;
    }
  } 
}

 

Update: In the previous version of this code, I wasn't disposing the display object.  That caused me far too many hours of frustration, because after around 25 calls to this method, the barcode scanner would stop scanning.

Currently rated 1.4 by 5 people

  • Currently 1.4/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags: ,

Making a .net CF 2.0 app fullscreen

by Mark Milec 4/7/2008 8:50:00 AM
I came across this article when I was trying to make my CF 2.0 app fullscreen: 

http://www.codeproject.com/KB/mobile/netfullscreen.aspx
 

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags:

Setting up MSMQ on Windows CE 5.0

by Mark Milec 4/7/2008 8:39:00 AM

Most of my work lately has been writing .net CF apps to run on a Symbol 9090G device.  The 9090G is a Windows CE 5.0 device with a barcode scanner built in.  The applications I'm writing are built on .net CF 2.0 and use MSMQ extensively.  It took a while to figure out how to get MSMQ running so I'm documenting the process here.

When you deploy a .net CF app from Visual Studio, the framework is deployed to the device automatically. You can find the cab file to install the framework manually here: C:\Program Files\Microsoft Visual Studio 8\SmartDevices\SDK\CompactFramework\2.0\v2.0\WindowsCE\wce500\armv4i\NETCFv2.wce5.armv4i.cab

If you can't find it there, you can install the Windows Mobile 5.0 SDK for Pocket PC then you should be able to find it here: C:\Program Files\Microsoft.NET\SDK\CompactFramework\v2.0\WindowsCE\wce500\armv4i\NETCFv2.wce5.armv4i.cab

Visual Studio 2005 doesn't come with an emulator for CE 5.0, but it can be downloaded here: Microsoft Windows CE 5.0 Device Emulator

The Symbol 9090G has the MSMQ dlls already installed but it needs to be configured. The easiest way I've found is to use the visadm tool. Visadm.exe is not installed on the device, but it can be found in the MSMQ.arm.cab file in the Redistributable Server Components for Windows Mobile 5.0

Once visadm.exe is on the device, you can use it to configure MSMQ by performing the following steps:

1. Click Shortcuts-Install
2. Click Shortcuts-Register
3. Enter enable binary in the textbox and press the run button
4. Enter enable srmp in the textbox and press the run button

Reboot the device and it should be ready to go.

Currently rated 1.0 by 3 people

  • Currently 1/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags: ,

Getting Started with Subversion

by Mark Milec 4/7/2008 4:33:00 AM

Currently rated 1.0 by 3 people

  • Currently 1/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags:

Bananaquit, Green Turtle Cay, Bahamas

Powered by BlogEngine.NET 1.3.1.0
Theme by Mads Kristensen

About the author

Name of author Mark Milec
Senior Application Developer at Atlas Tube

View Mark Milec's profile on LinkedIn E-mail me Send mail

Calendar

<<  September 2016  >>
MoTuWeThFrSaSu
2930311234
567891011
12131415161718
19202122232425
262728293012
3456789

View posts in large calendar

Pages

    Recent comments

    Archive

    Authors

    Categories

    None


    Disclaimer

    The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

    © Copyright 2016

    Sign in