kalls
kalls

Reputation: 2865

How to translate from English to french using C#

I have the following code

 private void button1_Click(object sender, EventArgs e)
    {
        ResXResourceReader resourceReader = new ResXResourceReader("EN-US.resx");

        foreach (DictionaryEntry dictonary in resourceReader)
        {
            //call google API to translate the entry
            MessageBox.Show(dictonary.Key.ToString() + ":\t" + dictonary.Value.ToString());
        }

        resourceReader.Close();
    }

In the above example I am reading a resource file and display it on the messagebox. I need to know how can I call google webservice or something and translate the entire resource file to a new language (french in my case) Please do let me know. I appreciate your support.

Upvotes: 0

Views: 7459

Answers (2)

juFo
juFo

Reputation: 18597

Download MAT (Multilingual App Toolkit) for Visual Studio. https://marketplace.visualstudio.com/items?itemName=MultilingualAppToolkit.MultilingualAppToolkit-18308

This is the way to go to translate your projects in Visual Studio ;-)

Upvotes: 0

Pieter van Ginkel
Pieter van Ginkel

Reputation: 29640

You can use a .NET API for this. Check http://code.google.com/p/google-language-api-for-dotnet/ for a specific one. Using Google Translate in C# has a list of available options.

Upvotes: 2

Related Questions