B
BostonNole
Refer to MS article Q98999 for an explanation of Diacritical Marks.
When a line from a flat text file is imported from a file using the
StreamReader, any character that has a Diacritical Mark is dropped.
Sample Code:
Dim fs As FileStream
Dim sr As StreamReader
Try
fs = New FileStream("c:\temp\badrecords.txt",
FileMode.Open, FileAccess.Read)
sr = New StreamReader(fs)
Dim line As String = sr.ReadLine()
Do While Not line Is Nothing
Debug.WriteLine(line.ToCharArray())
line = sr.ReadLine()
Loop
MessageBox.Show("Done")
Catch ex As Exception
MessageBox.Show(ex.Message)
Err.Clear()
Finally
If Not sr Is Nothing Then
sr.Close()
sr = Nothing
End If
If Not fs Is Nothing Then
fs.Close()
fs = Nothing
End If
End Try
When a line from a flat text file is imported from a file using the
StreamReader, any character that has a Diacritical Mark is dropped.
Sample Code:
Dim fs As FileStream
Dim sr As StreamReader
Try
fs = New FileStream("c:\temp\badrecords.txt",
FileMode.Open, FileAccess.Read)
sr = New StreamReader(fs)
Dim line As String = sr.ReadLine()
Do While Not line Is Nothing
Debug.WriteLine(line.ToCharArray())
line = sr.ReadLine()
Loop
MessageBox.Show("Done")
Catch ex As Exception
MessageBox.Show(ex.Message)
Err.Clear()
Finally
If Not sr Is Nothing Then
sr.Close()
sr = Nothing
End If
If Not fs Is Nothing Then
fs.Close()
fs = Nothing
End If
End Try