我有代码:
StorageFile sf = await storageFolder.GetFileAsync("1.png");
IBuffer buffer = await FileIO.ReadBufferAsync(sf);
byte[] fileData = buffer.ToArray();
Encoding encoding = Encoding.GetEncoding("Windows-1252");
string text = encoding.GetString(fileData, 0, fileData.Length);
string content = @"file1=" + text + "";
txt.Text = content;
Item_Text.Text = txt.Text;
当我尝试在文本框中显示时,它不会显示全文,但在文本块中字符串已满。有图: