iphone - Retrieve date and time from UIDatePicker iOS -


i want retrieve date , time in format e.g "friday may 31, 2013 12:00 pm". how can achieve nsdateformatter?

nsdate *mydate = datepicker.date;  nsdateformatter *dateformat = [[nsdateformatter alloc] init]; [dateformat setdateformat:@"cccc, mmm d, hh:mm aa"]; nsstring *prettyversion = [dateformat stringfromdate:mydate]; 

Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -