I want to get day, month and year components of NSDate in integer form i.e. if the date is 1/2/1988 then I should get 1, 2 and 1988 separately as an integer. How can I do this in iPhone? I found similar question but the method descriptionWithCalendarFormat: gives warning and seems to be deprecated by now.