Hi, just wondering how I can assign the member of the "struct tm" to an integer? I tried doing the following, but get the error message "dereferencing pointer to incomplete type". when I do line 5 to line 8. Thanks in advance.
Code:int hour,sec,min; time_t now; struct tm *tm_now; now=time(NULL): tm_now=localtime(&now); hour=tm_now->tm_hour; /* starting here */ min=tm_now->tm_min; sec=tm_now->tm_sec;