learner learner

learner learner

  • NA
  • 29
  • 155.5k

input chinese character using text box

Nov 3 2010 11:23 AM

I have a c# form application with a text box and a button.  I type Chinese character in the text box and press the button to assign the input to a string using the following code

String  chineseChar = Textbox1.Text ;

   // TextBox font property:  Arial Unicode MS or SimSun

But it assigns empty string to chineseChar variable.

 When I copy a chinese text from a MS word and paste it to the textbox, it works.

Where the problem?

Environment:

VS 2008, C# .net framework 3.5

Windows XP or upper

Ms PinYin IME 3.0


Answers (1)