These are my structures and when i try to access them i get an error message that says 'structure required on left side of . or .* in function main. I have put the code below the structures any help would be much appreciated
typedef struct {
char part_num[7];
int quantity;
} I_R_details;
typedef struct {
char cust_name[21];
char cust_addr[61];
float cust_bal;
long credit_limit;
} creation_details;
typedef struct
{
char record_type;
char cust_code[7];
union
{
I_R_details irInfo;
creation_details cInfo;
} unval;
}customer;
...
if(unval.I_R_details.record_type == 'I' )
I want to see if the first letter in the record is an I then i do some code which is ok but unsure about this line though
many thanks