This worked for me, you can try the same. I had to navigate from one page to another, so posting the link to the two pages.
First -> https://discussions.apple.com/message/16497282#16497282
Then, from there to -> https://discussions.apple.com/message/16479587#16479587
I had to go into Settings>iCloud> and turn on Calendars. After that, I tried to attempt and run my code, and it was working well and fine again.
Do attempt this, if you facing a similar problem.
I was working on iPad 2, and with iOS 6.1.3 installed on the device.