Click here to Skip to main content
15,893,487 members
Articles / Mobile Apps / Windows Phone 7

Localizing Your Windows Phone 7 Application (Enums and Finished Project)

Rate me:
Please Sign up or sign in to vote.
4.82/5 (3 votes)
27 Aug 2011CPOL4 min read 28.3K   354   16  
Give language support to your Windows Phone 7 applications
//Common.cs

/*
 * XamlQuery Silverlight Library v1.2
 * http://XamlQueryLib.codeplex.com/
 * 
 * Author: cincoutprabu (cincoutprabu@gmail.com)
 * Copyright 2010 cincoutprabu. All rights reserved.
 * 
 * Released under Microsoft Public License.
 * http://www.microsoft.com/opensource/licenses.mspx#Ms-PL
 *
 * Date: 2010-Sep-10 06:00 IST
 * Revision: 1
 */

using System;
using System.Collections.Generic;
using System.Windows;

namespace XamlQueryLib
{
    internal class Common
    {
        #region Fields

        internal static List<string> Log = new List<string>();
        internal static bool TraceLog = false;

        #endregion

        #region Methods

        internal static void ClearLog()
        {
            Log.Clear();
        }

        internal static void AddToLog(string entry)
        {
            if (TraceLog)
            {
                Log.Add(entry);
            }
        }

        internal static void Show(string entry)
        {
            MessageBox.Show(entry);
        }

        internal static void Error(string message)
        {
            MessageBox.Show(message, "XamlQuery", MessageBoxButton.OK);
        }

        #endregion
    }
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer (Senior) Emitsor Group
Mexico Mexico
Focused on creating MS Windows 8, Silverlight, Windows Phone 7 & 8 and the Web applications.

More than 20 years of experience creating software solutions.

Comments and Discussions