| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | Structures and Binary |
Hello everyone, could some body please help me.. I'm trying to write a
structure to a file, but i can't get it to write it.. I've tried commands like
: WRITE, FWRITE, FPUTS, PUTC, PUTS etc etc.. I'm pretty sure my structure is
O.K.. here it is.. (well it works :-)
typedef unsigned char byte;
STRUCT names {
byte firstname;
byte lastname;
byte address;
};
STRUCT names writenames;
Now, it works with my C program (Quick C), it's probably not the best way
to do it any how....
And also.. How do i open a file in BINARY mode to write to?? (if the file
is in TRUE binary when you edit it with say, XTree Gold, it should say
something like : CANNOT EDIT NON-TEXT FILE .... I have tried:
writepoint = fopen("record.dat","wb");
but it just writes the file in text mode... Any help would be appreciated!
Thanks Cya!
Keith
--- GEcho 1.00
* Origin: DarkZone BBS, NODE1 V.34+ V.fc HST +61-63-726978 (3:623/683)SEEN-BY: 50/99 78/0 620/243 623/411 630 631 683 812 711/401 409 410 413 430 SEEN-BY: 711/808 809 932 934 712/515 713/888 714/906 800/1 7877/2809 @PATH: 623/683 630 711/808 809 934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.