Unicode strings into a SQLite database

前端 未结 2 1272
时光说笑
时光说笑 2021-01-06 19:06

I would like some help with my Visual Studio C# code with inserting unicode strings into a SQLite database.

Below is my test code to write a test string to the datab

2条回答
  •  暖寄归人
    2021-01-06 19:26

    You can try with this code

    byte[] encod = Encoding.Default.GetBytes(testStr );
    string result = Encoding.UTF8.GetString(encod);
    myParameters.AddWithValue("@name", result);
    

提交回复
热议问题