0
#include <iostream>
#include <fstream>
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include <ctype.h>
#include <conio.h>
#include <dos.h>
#include <Windows.h>
#include <exception>
#include <cmath>
#include <ctime>
#include <iomanip>
#include <time.h>
using namespace std;


void WORKING :: issuebook(void)
{ ...............


    struct date d ;
    getdate(&d);
    d1 = d.da_day ;
    m1 = d.da_mon ;
    y1 = d.da_year ;

I have an error C3861: 'getdate': identifier not found. or identifier "getdate" is undefined. Anyone plz help me to solve it . Thank you .

zak
  • 1
  • 2
  • Did you `#include ` ? Note also that the standard version of [`getdate`](https://linux.die.net/man/3/getdate) takes a string, not a `struct time`. – Paul R Oct 12 '16 at 07:45
  • yes I am use this #include . same error give the VS 2012 . – zak Oct 12 '16 at 07:59
  • Did you fix the other error too, i.e. wrong parameter type being passed to `getdate` ? – Paul R Oct 12 '16 at 08:00
  • yes I fix the all others errors . just 1 error remaing . and i can't solve it . but it can't give me this error wrong parameter type . just give me (getdate identifier not found) or ( getdate is undefined) – zak Oct 12 '16 at 08:06
  • Please hit the [edit] link and update the question so that it shows the current, fixed version of the code. – Paul R Oct 12 '16 at 08:07
  • OK - I think I see the problem - you are trying to use an ancient and non-standard `getdate` from the days of Turbo C and DOS (1980s!) - like [here](http://www.programmingsimplified.com/c/dos.h/getdate). That old non-standard header was `` and it only worked with the long-obsolete Turbo C compiler. Use standard library functions instead. – Paul R Oct 12 '16 at 08:12
  • ohh yes , but can you plz tell me what standard library functions I use ? – zak Oct 12 '16 at 08:20
  • it depends on what you want to do - I suggest you start by looking at [`localtime`](https://linux.die.net/man/3/localtime). See: [this example](http://stackoverflow.com/a/1442131/253056). – Paul R Oct 12 '16 at 08:25

0 Answers0