Click here to Skip to main content
15,880,956 members
Articles / Programming Languages / C#

Satellite Assembly and Implementation Details

Rate me:
Please Sign up or sign in to vote.
2.62/5 (15 votes)
27 Sep 2007CPOL3 min read 61.8K   791   24  
Through this article, we will explain the use and implementation details of satellite assembly.
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Resources;
using System.Globalization;
using System.Threading;
using System.Reflection;

namespace SatelliteAssembly
{
    public partial class SatelliteDemo : Form
    {
        public SatelliteDemo()
        {
            InitializeComponent();
        }

        private void comboBox1_SelectedValueChanged(object sender, EventArgs e)
        {
            try
            {
                ResourceManager rm = null;
                CultureInfo ci = Thread.CurrentThread.CurrentCulture;
                if (comboBox1.Text == "German - Germany")
                {
                    rm = new ResourceManager("SatelliteAssembly.de-DE", Assembly.GetExecutingAssembly());
                    lblOne.Text = rm.GetString("StrMsgOne");
                    lblTwo.Text = rm.GetString("StrMsgTwo");
                }
                else if (comboBox1.Text == "English - Great Briton")
                {
                    rm = new ResourceManager("SatelliteAssembly.en-GB", Assembly.GetExecutingAssembly());
                    lblOne.Text = rm.GetString("StrMsgOne");
                    lblTwo.Text = rm.GetString("StrMsgTwo");
                }
                else if (comboBox1.Text == "French - France")
                {
                    rm = new ResourceManager("SatelliteAssembly.fr-FR", Assembly.GetExecutingAssembly());
                    lblOne.Text = rm.GetString("StrMsgOne");
                    lblTwo.Text = rm.GetString("StrMsgTwo");
                }
                else
                {
                    rm = new ResourceManager("SatelliteAssembly.en-US", Assembly.GetExecutingAssembly());
                    lblOne.Text = rm.GetString("StrMsgOne");
                    lblTwo.Text = rm.GetString("StrMsgTwo");
                }
            }
            catch (Exception Ex)
            {
                MessageBox.Show(Ex.Message);
            }

                  

        }
    }
}

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) Freelance
India India
He is a certified professional in both MCPD and MCTS. He is a mathematics graduate with masters in computer science.He was born and bred in India and happen to spend some time in Europe.

Comments and Discussions