hi,
In my project there is a situation that i have two textbox .if i enter 1st textbox english then dynamically in second text box it has to come in arabic
language.i already use google translator api but the translation is happening in a single textbox.i want translated text will appear in 2nd textbox.
Thanks in Advance

Shubham KumarRank #621 · 3.8K reputationPosted Jan 31, 2016, 10:48 PM EST
Hi,
You may want to have a look at following links:
nirjharini pradhan94 reputationPosted Jan 31, 2016, 10:56 PM EST
Shubham KumarRank #621 · 3.8K reputationPosted Jan 31, 2016, 11:18 PM EST
{
System.Text.UTF8Encoding utf8Encoder = new UTF8Encoding();
System.Text.Decoder utf8Decoder = utf8Encoder.GetDecoder();
System.Text.StringBuilder convertedChars = new System.Text.StringBuilder();
char[] convertedChar = new char[1];
byte[] bytes = new byte[] { 217, 160 };
char[] inputCharArray = input.ToCharArray();
foreach (char c in inputCharArray)
{
if (char.IsDigit(c))
{
bytes[1] = Convert.ToByte(160 + char.GetNumericValue(c));
utf8Decoder.GetChars(bytes, 0, 2, convertedChar, 0);
convertedChars.Append(convertedChar[0]);
}
else
{
convertedChars.Append(c);
}
}
return convertedChars.ToString();
}
nirjharini pradhan94 reputationPosted Feb 1, 2016, 4:07 AM EST
Thanks in Advance
nirjharini pradhan94 reputationPosted Feb 2, 2016, 8:52 PM EST