0

I'm trying to add custom property on the ppt file. But Received value("güsiöçÇÖISÜG") is not equal sent value("ğüşiöçÇÖİŞÜĞ").

enter image description here

I faced a strange situation like that:

  • Open the sample.ppt by LibreOffice.
  • Save (CTRL+S) and Close, any change is not necessarily.
  • Run the code again.
  • And two values are equal

Sample ppt files is here: https://drive.google.com/drive/folders/1qTlREuLAAM-I0JIn-htPwLEUwRjQ9IiJ?usp=sharing

Is there anyone to help me, thanks.

1 Answers1

0

You need to check encodings of your Excel files. Most probably a software (DSO) generates a UTF-8 based document instead of UTF-16. For example, you may try using the following code:

Dim strEncodingName As String = String.Empty
Dim myStreamRdr As System.IO.StreamReader = New System.IO.StreamReader(myFileName, True)
Dim myString As String = myStreamRdr.ReadToEnd()
strEncodingName = mmFileIA.CurrentEncoding.EncodingName
Eugene Astafiev
  • 47,483
  • 3
  • 24
  • 45