I'm just gonna go off the limits and ask you a really specific question. There's a card reader device in my office that's connected to the Ethernet card. Below is a screenshot of the configuration window of this card reader's program(distributed with the program).
There is an IP Address, a port, and it says COM3 and there is Baud rate. Distributed program is working fine. It fetches data from the device.
My question is, how can i get the data from this device? Do i have to make a socket connection?
Note : In the distributed programs' folder there is no DLL associated. Only VB6 program DLL's. (By the way the distributed program has been developed in VB6).
Thanks for your ideas.
UPDATE :
Here is my final code.
byte[] b = null;
TcpClient client = new TcpClient("10.1.2.100", 5005);
client.SendBufferSize = 6550000;
NetworkStream stream = client.GetStream();
MemoryStream ms = new MemoryStream();
int count = 0;
do
{
byte[] buffer = new byte[1024];
count = stream.Read(buffer, 0, 1024);
ms.Write(buffer, 0, count);
} while (stream.CanRead && count > 0);
b = ms.ToArray();
But NetworkStream 's DataAvailable property is false..