Click here to Skip to main content
15,886,110 members
Please Sign up or sign in to vote.
3.00/5 (2 votes)
string text = "hello";

     TranslateClient client = new TranslateClient("");

     Language la1=Language.English;
     Language la2=Language.English;
     string translated= client.Translate("hello", la1, la2);

     textBox1.Text = translated;
------------------------------------------------------------------
help me

this code is error

created with google translate api 4 alpha
Posted
Updated 14-Jan-12 2:57am
v2

1 solution

It is hard to help you when you're not saying anything about the error message.

However, according to the TranslateClient[^] class definition, there is no constructor taking a string.
So, I assume
C#
TranslateClient client = new TranslateClient();

will solve your problem.
 
Share this answer
 

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



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900