using gps time and date

im trying to use time and date from neo-6m for a telescope.
what i need is to take these statements and set them to vaarible
gps.time.hour ();
gps.time.minute ();
gps.time.second ();
gps.date.year ();
gps.date.date ();
gps.date.month ();

int monthA;
i tried monthA=gps.date.month ();
i check with Serial.print(monthA);
it print out a set zero

What library are you using?
What happens when you try to print gps.time.month() directly? Without seeing any code, the best you'll get is a guess. My guess is that gps.time.month() returns a character string. Try char monthA[]=gps.date.month ();

You are checking that you have good data, first, right? Somehow, I doubt that.