0

I have a VB.NET project.

I am trying to connect to a server through TcpClient. I am suppose to get data in hebrew - but all the Hebrew returns as symbols...

I am using UTF-8 coding but it doesnt help... When I tried to change to Unicode - the service got stuck.

Any Ideas?

The code:

 client.Connect(Settings.ServerIP, Settings.ServerPort)
client.GetStream().BeginRead(receiveData, 0, receiveData.Length, AddressOf ReceiveDataCallback, client)
Dim bytesReceived As Int32 = (client.GetStream().EndRead(iar))
Dim NewData As String = Encoding.UTF8.GetString(receiveData, 0, bytesReceived)

thanks!

Sarah Sh
  • 451
  • 5
  • 15

0 Answers0