Howto: Undo iCal import in Google Calendar
Imagine this situation: you just imported your full schedule for this semester into your main Google Calendar when you decide make some changes to your courses or want to switch to an iCal feed. In this and many other cases it would be nice if Google provided any form of undo import option. Unfortunately there is no automated way of doing this just yet, so manually deleting all events seems to be the only option. Somebody came up to me today asking if there is any way of solving this problem, so i figured something out. All you need is the original ics file and a simple text editor.
To get started open up your ics file in a simple text editor. On windows built-in notepad would work, but i prefer Notepad++. You will notice that an ics file basically consists of a long list of data for all events in the file. We need to trick Google Calendar into believing that all the events are cancelled. The iCal format contains a lot of parameters, one of them is the “Status” parameter. Usually in ics files this is set to confirmed. We will use this status to trick Google Calendar.
- Open the find/replace function
- Replace all occurrences of “STATUS:CONFIRMED” to “STATUS:CANCELLED”
- Save the file
- Re-import the file to the same Google Calendar
Tags: calendar, Eveoh, gcal, google, ical, ics, import, mytimetable, tu delft, undo
Trackback from your site.
Comments (138)
James
| #
Find/Replace worked great for me as well. Removed 209 entries easily by editing the .ics file using TextWrangler on a Mac.
It worked after replacing BEGIN:VEVENT with BEGIN:VEVENT\nSTATUS:CANCELLED
Reply
Peter Egziabher
| #
I tried to replace on Mac with BEGIN:VEVENT\nSTATUS:CANCELLED
But I got the notice “Failed to import events: Unable to process your iCal/CSV file..”
Any suggestions? Would be much appreciated, my calendar is OVERFLOWING. Thank you!
Reply
Alfred Lua
| #
This solved my problem in less than a minute! Thanks!
Reply
Subie
| #
Thanks, you saved me pain…
Reply
David
| #
This totally worked, and it seems that this is a real problem for many people.
Thanks for posting this.
Reply
Luca
| #
Thanks für this great hint!
Reply
Marci
| #
I think I’m missing something, because this is not working for me. Please HELP!!!!!
Reply
Gerhard
| #
Unfortunately it doesn’t work for me: I changed the status to Cancelled as descripted, imported it and now I got the 356 dates twice…
In my Ics file there is no “SEQUENCE” to change.
Any ideas?
Reply
milosz
| #
I have 542 events. Am using TextEdit on a Mac. So I still have to replace the 2nd to last line with STATUS:CANCELLED – but I have to do this 542 times!!??? This doesn’t help at all. Is there a way to do it ONCE and finish it?
Reply
Josh
| #
YOU ARE AWESOME! WORKED PERFECT
Reply
Joe
| #
Niiiice!
Reply
demos
| #
You need to also replace STATUS:TENTATIVE with STATUS:CANCELLED
Reply
Adam
| #
This process didn’t work for me without knowing the UID for each item. So I can’t just set status to cancelled in the original ICS.
I can export the entire calendar (which has UIDs in it) as a new ICS, remove the entries (that weren’t in the original import file), and set status to cancelled. But that can be a PITA, depending on what else is on the calendar.
Any thoughts?
Reply
Mike
| #
Fab – worked for me
Changed all STATUS: CONFIRMED and STATUS:TENTATIVE to STATUS:CANCELLED in Notpad.
Worked first time
Reply
Alex
| #
Years later this really helped me out man, thanks
Reply
Lana
| #
I did search and replace in MS Word but the file was saves as .docx. How do I convert it to .ics in order to export it in Google Calendar?
Reply
Soph
| #
Forever thanks!!!
Reply
Andi
| #
Thanks a lot!
You saved me from deleting 84 entries by hand!
Reply
Amanda
| #
Worked!
Someone asked about a text edit on Mac. There is a replace all function available.
So, just one time is necessary 🙂
Thanks!
Reply
Thomas Duncan
| #
Maybe you can add James comment
replace BEGIN:VEVENT with BEGIN:VEVENT\nSTATUS:CANCELLED
in your description… I had the problem that i had the wrong order because my file didn’t have a STATUS
Reply
Andy
| #
I accidentally imported my Outlook Calendar (.ics file) to my Google Calendar and want to undo this. I tried the above \n and \r options and neither work, as all attempts to import the modified .ics file result in:
“Processed zero events. Failed to import events: Unable to process your iCal/CSV file..”
I don’t know if it is relevant or not but the .ics file icon now appears as a Notepad document rather than a calendar document (after editing in Notepad and saving). If anybody has a solution, please add to the comments so I can eliminate half of my double events. Thanks!
Reply
Andy
| #
Guess I should have read the first page of comments before posting! The post by “Tom (not Verhoeff)” (/2011/01/31/howto-undo-ical-import-in-google-calendar/comment-page-1/#comment-16174) outlines exactly what I needed to do. My duplicate Outlook events have been removed!
**Also, I now realize the icon simply displays the default app in which the file will open and is unrelated to the file’s functionality.
Reply
Matty
| #
Wow. Great solution – worked perfectly. Thanks for saving me a major headache!
Reply
Simon
| #
Brilliant solution! This fixed my problem, thanks 🙂
Reply
mike
| #
I have done the same thing but I have used a CSV file initially to do the import – is there an equivalent change that would work in a CSV file?
thanks
Mike
Reply
Frédéric
| #
What worked for me was this:
FIND> SUMMARY
REPLACE> METHOD:CANCEL\r\nSTATUS:CANCELLED\r\nSUMMARY
found the solution here: https://productforums.google.com/forum/#!topic/calendar/4L_g0_q4lzc
Reply
Junior Belfort
| #
Hi guys! I have got a trouble with university essays. There is a great number tasks to do in a week. How do you normally resolve similar problems? Do you know any reliable college writing firms that guarantee professional assistance for schoolers? Thank you! (Edited, already found an answer, sorry 🙂 ) Forgot, that i had a pleasant collaboration with http://master-of-papers.com/ Last year this website handled a bunch of essays for me. Each and all were submitted with success. The least rating was good, so i think i should stick with that service 🙂 Sorry again, if i posted in wrong place or smth. like that ) P.S. If you have any suggestions though, please post your options
Reply
Sarah
| #
the “\n” part doesn’t create a new line in my text document. so instead of getting the result:
BEGIN:VEVENT
UID:
[…]
DESCRIPTION:
CLASS:PUBLIC
STATUS:CANCELLED
END:VEVENT
i’m getting
BEGIN:VEVENT
UID:
[…]
DESCRIPTION:
CLASS:PUBLIC
STATUS:CANCELLED\nEND:VEVENT
any suggestions?
Reply
Sean
| #
Worked perfectly for me!!! Thanks
Reply
Will
| #
Oh boy, you just saved me from a world of pain! Thanks!
Reply
Vonetta
| #
I have a Mac, using TextEditor app; tried every combo of suggestions mentioned in this blog and chain of comments. I am still getting the error message. Someone please help me!!!
Reply
aa
| #
It worked perfectly for me!! Thanks so much!!
I have a Mac too I tried this using TextEditor, but the /n doesn’t create a new line on TextEditor.
What I did was that I downloaded “Sublime Text 2” for Mac (It’s free though). Then you follow the same pattern mentioned above >> replace “END:VEVENT” with “STATUS:CANCELLED\nEND:VEVENT”
**But in the find and replace function you need to enable regular expression in order to enable the /n command to create a new line. You can do this by pressing the “.*” button on the left before clicking replace all.
That works for me! hope this helps!
Reply
Eric
| #
Yaaaay!!! It worked even in year 2015 😀
I had to add STATUS:CANCELLED with find/replace (used Notepad++ for that).
I misspelled CANCELLED the first time (forgot the double-L), otherwise worked perfectly 🙂
Thanks!
Reply
Min
| #
Exactly what I needed. Thanks
Reply
Joe Tyburczy
| #
Awesome — thanks! If (like mine) your events don’t have a STATUS field, you can just use text edit to find a field that your file does have, was consistent across all events, and that STATUS should be listed after, such as: SEQUENCE:0
Then replace it with:
SEQUENCE:99
STATUS:CANCELLED
(Note that you have to include the carriage return in the “replace” field — which you can do by typing it into the first event and then copy/pasting both lines at once into the “replace” field.)
Reply
Joël
| #
So, it also works fine for me. Thanks for this great hint. It prevents me from lots of pain…
Reply
Lauren
| #
Thanks so much!
Had to fiddled a bit, make sure I saved file in correct format etc. But finally got rid of those 500 events I would have otherwise had to remove manually.
Reply
Hitesh
| #
worked great : replace BEGIN:VEVENT with BEGIN:VEVENT\nSTATUS:CANCELLED
thanks
Reply
kaiserschmarrn
| #
thanks!
Reply
Susan C
| #
This worked perfectly – thank you!
Reply
pixarius
| #
GREAT ! Thanks !!
Reply
https://www.instapaper.com/read/715620109
| #
https://www.instapaper.com/read/715620109
Howto: Undo iCal import in Google Calendar | Tom Verhoeff
Reply
learn the facts here now
| #
learn the facts here now
Howto: Undo iCal import in Google Calendar | Tom Verhoeff
Reply
Zahra
| #
Thanks a bunch!
After a couple of days of frustration it saved me 🙂
Reply
Dan
| #
Woooooooot praise God, it worked!
Replaced
END:VEVENT
with
STATUS:CANCELLED
END:VEVENT
Reply
Ata
| #
Use sublime text, copy exactly what is below and replace all! \n for newline did not work for me!
Replaced
END:VEVENT
with
STATUS:CANCELLED
END:VEVENT
Reply
Thomas Ölmbro
| #
THANX A MILLION!
Saved my day after making an exceptionally stupid mistake…
Reply
CX
| #
Many thanks, you saved my bacon!
Reply
Frank M
| #
Many thanks! Great solution
Reply
Ellen
| #
mine wouldn’t include the return and STATUS:CANCELLED\nEND:VEVENT
just came in like that.
google calendar is saying they are not working right now each time I try..
Reply