473,497 Members | 2,041 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Merging data packets

Giu
Hi ,sorry i'm a beginner and i need help.
I have to merge a lot of binary packets into a file on hard drive.
I get every packet from a network card with socket class in mydata variable
in a separate thread.

byte[] mydata=new Byte[512];

Please could anyone give me an example how to merge the packets and
retrieve them in a file?

TIA.



Nov 16 '05 #1
1 1712
Giu,

What you will want to do is create an instance of the FileStream class
and make calls to the Write method, passing the byte array along. It's that
easy.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Giu" <Gi*@spam.net> wrote in message
news:Fb*********************@news3.tin.it...
Hi ,sorry i'm a beginner and i need help.
I have to merge a lot of binary packets into a file on hard drive.
I get every packet from a network card with socket class in mydata
variable
in a separate thread.

byte[] mydata=new Byte[512];

Please could anyone give me an example how to merge the packets and
retrieve them in a file?

TIA.


Nov 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
3303
by: Ryan | last post by:
Hi, I am confused with how NetworkStream works. My application needs to handle heavy requests sent through TCP socket connection. I use NetworkStream.Read method to get the stream...
4
1462
by: Winger | last post by:
Hi, I'm having a weird problem... Part of code first: Dim bytes(tcpClient.ReceiveBufferSize) As Byte Dim DataChunk as String Dim FullData as String Do While EOF = False If...
7
2671
by: D. Patrick | last post by:
I need to duplicate the functionality of a java applet, and how it connects to a remote server. But, I don't have the protocol information or the java source code which was written years ago. ...
1
1274
by: naidupm | last post by:
HI i have a file with data -------------------------------------------------------- DESC: Baseline-Forwarding 2_PIMS_2_ONBOARD_PIC 1518B DATE: 2007-07-18 03:48:54...
0
6993
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7162
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
6881
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7375
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5456
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4899
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4584
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
1411
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
287
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.