Code Newbie
News     Forums     Search     Members     Sign Up    

My Code Newbie
Username

Password

Articles/Snippets
ASP Classic
ASP.NET
C
C#
C++
HTML / CSS
Java
Javascript
Linux / BSD
Perl
PHP
Python
Ruby
SQL
VB 6
VB.NET

C.N. Friends
  Planet Rome

Link to Us!
Code Newbie
  Code Newbie
    forums
Old 07-01-2004, 11:48 PM   #1 (permalink)
IAmWeasel
Registered User
 
IAmWeasel's Avatar
 
Join Date: Jul 2004
Posts: 1
IAmWeasel is on a distinguished road
Send a message via Yahoo to IAmWeasel
Implementing C++ file structure in C#

Hi! I have been going over this problem for a week already and i was not successful with it. I have this data files implemented and defined by C++'s file structure in this format;

typedef struct {
unsigned int var1[128];
unsigned int var2;
char var3;
long time;
} firstStruct;


typedef {
unsigned int var4;
unsigned int var5[128];
unsigned int var6[128][2];
firstStruct var7[3];
long time;
} secondStruct;

I am going to convert this to C# and read/write a file by using this structure. It would be helpful if you can give me a sample on how to read and write to a file using this structure.

Since a file has already been created via C++ i tried reading the file using the idea of pe666o on the forum topic C# and advanced binary files but unfortunately i was unsuccessful with it.

Thank you very much in advance!

Best Regards,
IAmWeasel
IAmWeasel is offline   Reply With Quote
Old 07-08-2004, 07:38 AM   #2 (permalink)
sde
Moderator
 
sde's Avatar
 
Join Date: May 2002
Location: us.ca
Posts: 4,446
sde is on a distinguished road
<bump> moved from submitted tutorials
__________________
Mike
sde is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
text file recursive string reading C toblerone Standard C, C++ 4 08-04-2004 10:05 PM
Implementing Run Length Encoding on Bitmaps in C Programming kodonovan_cork Standard C, C++ 0 04-21-2004 10:23 AM


All times are GMT -8. The time now is 04:27 AM.


Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.0.0 RC8





Copyright © 2000-2008, Milano Interactive
Web Hosting provided by Portal 360 Web Hosting