TIP: Click on subject to list as thread! ANSI
echo: aust_c_here
to: Jahmai Lay
from: Frank Adam
date: 1996-04-27 23:20:16
subject: Help with Ra

G'Day Jahmai,
 
-=> Quoting Jahmai Lay to All <=-

 JL> give me a CLEAN example of how to copy the strings from a 
 JL> file using the following structures ;
                              ^^^^^^^^^^^ ??? 
                              
 JL> struct LCrecord {
 JL> unsigned char Line;
 JL> unsigned char Name[36];
 JL> unsigned char Handle[36];
 JL> unsigned char City[26];
 JL> unsigned int  Baud;
 JL> long          Times;
 JL> unsigned char LogOn[6],
 JL> LogOff[6];
 JL> unsigned char Attribute;
 JL> };

This is a structure definition only, it contains struct members within.
You need to create an array to call it structure_s_.

It should be declared.. struct LCrecord MyRecord[HowMany];  

 JL> I then Open the file, declare some strings that i copy info
 JL> to etc etc and using a While loop with FREAD, I read 
 JL> sequential data and strncpy or strcpy the records, is this 
 JL> correct?  If so could someone please indicate any problems 
 JL> .. a proper example would be greatly appreciated.
I'm not sure what you mean here, are you getting data from a file and 
transferring it into the structures, or are you attempting to read a data 
file containing these structures ?

How about posting the relevant part of your code, and make it easier for 
us. ( well, me at least :-))

The etc,etc part and the bit after would be good :)

  L8r Frank (fadam{at}ozemail.com.au).
   
___ Blue Wave/DOS v2.21
                                         

--- Maximus 3.01
* Origin: The Software Parlour (3:635/544)
SEEN-BY: 50/99 78/0 620/243 623/630 632/349 635/503 544 727 711/401 409 410
SEEN-BY: 711/413 430 808 809 932 934 712/515 713/888 714/906 800/1 7877/2809
@PATH: 635/544 50/99 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™.