Archive old Google Calendar events from iCal 4?

I have 8 Google calendars filled with events going back years. It's too big and I want to thin it out by archiving all events older than two years. I'll do it manually, but I can't find a way that works. I haven't found any way within Google to do it and to do it manually from within Google, you have to select each event separately. Too much work.
To do it for a Mobile Me calendar, I can just:
- Create a corresponding archive calendar (ie, Archive Personal for my Personal calendar) that is On My Mac
- Select only one calendar to view (Personal)
- List all events by typing a period in the search bar
- Select all events in the list that I want to move
- Right click or control click one of those selected events in the calendar (not the list) and choose the calendar Archive Personal to move it to
For the Mobile Me calendar, the events are moved to the Archive Personal calendar and removed from the Mobile Me calendar. Perfect.
When I try that with a Google calendar, it all seems to work in iCal, but the event remains on the Google calendar. No good.
I tried another way...
- I exported one of the calendars from Google into an Archive calendar On My Mac
- I was planning to delete everything after a certain date on the Archive calendar and delete everything before a certain date on the Google calendar, but when you search for all of the events in the Archive calendar On My Mac, it shows duplicates of every event. Somehow it's showing the Google calendar events as well as the archive calendar events even though the archive is the only calendar selected. The search should only result in events from that calendar!
Also, searching for a list of all events in a calendar in iCal 4.04 doesn't work too well. Once you move events, the update of the list is spotty. To really see what is left in the calendar, you need to quit iCal and restart it and do the search over again. Hopefully that's fixed in the Lion version!
If anyone can think of a solution to accomplish this — any better way to archive off old events from a Google calendar, I would appreciate it!

I just started using MobileMe yesterday and have a similar issue. The only past events in my iPhone are recurring events like birthdays. None of my old one-time events synced to the iPhone. Fortunately, they're all still in iCal (local and online). Does anyone have tips on how to get all events, past, present, and future on the iPhone?

Similar Messages

  • Can't edit Google Calendar events in iCal

    I am using Google Calendar's new CalDAV sync system and their "Calaboration" tool to sync my iCal (version 3.0.5, and I'm using Mac OS 10.5.2) with my Google Calendars, per the instructions on this page:
    http://www.google.com/support/calendar/bin/answer.py?answer=99358#ical
    It seems to work ok in that I can now see my google calendar events in iCal. I can also add an event to that calendar in iCal, and it will sync to my google calendar. However, I can't seem to edit an event in iCal that was created on the Google Calendar web page. That is, all my events that I created in Google Calendar do indeed appear in iCal, but I can't edit them in iCal. I can edit events that I create for that calendar in iCal, but not ones I created in google calendar. Not a huge deal, but I was wondering if this is how it is supposed to work, because it seems a tad inconvenient.
    (I do have my e-mail address in my address book "me" card, so that's not the problem.)

    Yeah, I tried deleting the calendars in iCal and re-synching to them via Calaboration, but the same problem persisted.
    I did find the solution after a bit of experimenting, though. To solve it, I basically created a new calendar on Google Calendar, imported all my events from my old google calendar into it, then used Calaboration to sync iCal to the new Google calendar, and now I can edit events in iCal and GCal without problems. I don't actually know what the problem WAS, but this seems to have solved it. Maybe I made my original Google Calendar too long ago and it had some old bad settings I couldn't see? I dunno, but it doesn't matter now.
    For those who might have this same problem, here's how I transferred my old Google Calendar events into a new Google Calendar without losing anything: (You actually don't need to delete your old Google Calendar at all if you don't want to, so there's no reason to worry about losing your events.)
    1. In GCal, click the "settings" link at the top right of the web page. Then select the "Calendars" tab. Click the "Export My Calendars" link, which should be under your list of calendars, next to the cancel button. This will download a .zip file to your computer, containing all of your google calendars as individual .ics files. Go ahead and unzip them so that the .ics file for the calendar you want to duplicate is sitting in a folder somewhere on your computer.
    2. Now In GCal, click on the "Create" link on the lower righthand side of the "My Calendars" box, which is on the lefthand side of the screen.
    3. Create a new blank calendar and name it whatever you want. This is the blank calendar into which you will import your old calendar's events.
    4. Now, in GCal, click "Add" at the bottom right of the "Other Calendars" box, which is under the "My Calendars" box on the left side of the web page.
    5. Select "Import Calendar".
    6. Click "Choose File" and browse to the .ics file you want to duplicate on your computer.
    7. In the "Choose Calendar" pull-down menu, select the new, blank calendar you made in step 3.
    8. Click Import. This may take a few minutes, depending on the number of events you have in your .ics calendar file.
    9. Once it's done, look at the calendar to make sure your events all came into your new Google Calendar ok. It should look exactly like the original google calendar, but it will be a different color.
    10. NOW, use Calaboration to sync your iCal to the New Calendar you just made in Google Calendar.
    11. Once it's done synching, you should be able to edit events in the calendar in iCal.

  • How do I move google calendar events to iCal?

    how do I move google calendar events to iCal?

    ab1268,
    I'm trying to do this very thing.  I have multiple google calendars set up (one for each kid, my husband etc.).  I want to move to iCal exclusively.  Based on your note above, should I export each individual calendar within ical.  Remove each from the iCal account and then reimport then into ical?  I suppose the risk is low b/c the data still exists in google.
    Please advise - I would hate to misstep.  Very new to the apple world (aside from iphone / ipad).
    Thanks!

  • How can i import my calendar events from google calendar to ical?

    how can i import my calendar events from google calendar to ical?

    To set up CalDAV support for Google Calendar in Apple's iCal, follow these steps:
    Open Apple iCal, go to Preferences and then the Accounts tab.
    Click on the + button to add an account.
    In the box that pops up, enter a description for the account and your Google Account username and password.
    Under Server Options, add the following URL:
    https://www.google.com/calendar/dav/[email protected]/user//www.google.com/calendar/dav/[email protected]/user
    Replace '[email protected]' with the email address that you use to log in to Calendar. Make sure to include the '@domain.com' portion (which is @gmail.com for Gmail users) in this section.
    DO NOT substitute your username for 'user' at the end of the URL.
    Leave the Use Kerberos v5 for authentication option unchecked.
    Click Add.
    Under the Delegation tab, select the calendars you'd like to add to iCal by checking the boxes next to them. You may need to hit refresh to get the latest list of calendars.
    Add your email address to your Address Book card by selecting Add Email. You'll be prompted to add your email address only if your address is not already in your Address Book.
    You won't be able to invite or email guests to Google Calendar events within iCal if your address is not in your Address Book.
    Your Google Calendar will now appear in iCal's list of calendars, and changes you make to your Google Calendar in iCal will be reflected when you sign in to Google Calendar.
    Event information will automatically refresh every five minutes. You can change this interval by opening the iCal > Preferences > Accounts menu and selecting a new refresh interval under the 'Refresh calendars' drop-down. Keep in mind you can also force a refresh by selecting a calendar and pressing the Apple and R keys at the same time.
    Calendars that are checked but disabled have already been added to iCal - you can remove them from within iCal.

  • ICal will only to connect to old google calendar with same email

    I used my email address to establish a Google calendar and link it to iCal.  I have since abandoned that goodle calendar and started using a different calendaring program, but with the same email address.  When I try to link the new calendar program with iCal it recognizes the old email address and attempts to connect it to the old google calendar.  I don't have deleted all of the old accounts, but there must be a preferences file or something that is being kept around.  Any ideas?

    Just in case I was unclear, here's my scenario. I have a google calendar on my iCal that I want to share. I can share from Google but the person I want to send it to isn't set up on Google (old man). However, he does have an iPhone and understands that all he has to do is accept an invitation to see a shared calendar from an iOS device. Share a google calendar the same way I share a iCal is what I'm trying to figure out without going through each entry and converting to a new calendar.

  • How can i export events from ical to word

    I need to use the description of many events from Ical in a text using Word for Mac.
    How can I do it?

    thisone - Thanks for your response, but unlike most events, this one does not have an edit button before the Event Details screen. In the top right hand corner next to the words 'Event Details' there is just an empty space.
    This event is extremely pesky and I have repeatedly synced my phone in attempt to remove it. It was an invitation I accepted for a recurring weekly event, which was sent to an email address for my old job. That email address is no longer active and no longer existing on my phone, but this event continues to show up on my calendar every single Tuesday.
    Help?

  • Bug: Repeating Google Calendar Events Show Up On The Wrong Days

    I've created a Google Calendar event that repeats "Daily," every two days, from 6:00pm to 6:30pm. It shows up fine in my Google Calendar, but the Pre's Calendar puts them on the wrong days. For example, the repeating event that should be scheduled for today shows up tomorrow (offset by +1 day). 
    I tried turning off network timezones, but the bug remains.
    Any help would be greatly appreciated. If this is a bug, how can I submit it to Palm?
    Thanks! 
    Post relates to: Pre p100eww (Sprint)
    Some new data:
    If I create the repeating event on my Pre, rather than via Google, it shows up on the Pre correctly. However, it only shows up for one day via Google (today); the event is not repeated. When I edit the event in Google, it's setup correctly. I tried saving the event from there, but it doesn't cause Google to recognize it should repeat.
    Very frustrating.
    Even more new data:
    Created yet another event via my Pre instead of via Google. This time Google picked up the correct repeat pattern, and my Pre now shows it on the correct days.
    Calendar sync needs serious work, based on my experience. I have issues with Facebook events showing up an hour later than they should, too. Dunno if this has been fixed yet.
    New Data (01/28/2010)
    Not sure why, but the above success reverted back to being off by one day; temporary success only.
    Message Edited by tlpbsd on 01-28-2010 11:52 AM
    This question was solved.
    View Solution.

    Hi, another quick question: you say you turned off network timezones.... did you make sure that the (now manually set) timezone is correct?
    Sounds similar to other issues related to the timezone being off, but usually the appointments were off by hours... not day(s).  However if your timezone is set to something really odd and the event you're creating is around midnight (again depends on a few things here), then MAYBE this is it.
    If it isn't, one of the support guys will have to chat with you privately about possibly collecting logs, getting more granular details, etc.

  • How to delete all events from iCal?

    Is it possible to select and delete all events from iCal? Or is it simpler to delete the calendar itself? Thanks!

    Sorted now!
    To clarify for people like me: type "." in the search bar
    Then click on the first item in the results pane
    Go to the other end of the list, hold down shift, and click the LAST item
    They should all be highlighted now
    Then use Edit/Delete
    NB it may take a couple of mins (or ten!) for the items to disappear from your view, particularly if syncing with MobileMe.

  • Google calendar event times are shown as -1h

    Summary:
    When I create a new event in the built in WP8 calendar app to a Google calendar the time of the event is being displayed as one hour earlier.
    Steps to reproduce:
    Create a new event in calendar. Choose one of the Google calendars configured (I have two configured in my phone). Set time as 2013/07/17 16:00. Save the event.
    Expected behavior:
    The event time in the agenda view is shown as 2013/07/17 16:00.
    Observed behavior:
    The event time in the agenda view is shown as 2013/07/17 16:00 for a few seconds. It then automatically changes to 2013/07/17 15:00.
    Other notes:
    I have two Google calendars configured. I can observe the same misbehavior on both.
    I also have a Microsoft (@hotmail.com) calendar configured. This works as expected.
    When I log into my Google calendar using a web browser, the time is shown as expected.
    When I use a third party calendar (Chronos) and sync my Google account directly, the time is shown as expected.
    When I use a third party calendar (Chronos) and use it simply as an interface to the built in WP calendar the time is off again showing 2013/07/17 15:00.
    The timezone on my WP is set to (UTC) London.
    I started noticing this perhaps a week ago. It was working as expected before.
    Phone model is Nokia Lumia 925
    Phone OS version is 8.0.10327.77
    Notes 1-6 suggests to me that the internal calendaring module in WP8 fails to recognize DST (daylight saving time) in timezone (UTC) London or misinterprets relevant information fields on Google calendar objects.
    Note 7 suggests to me that this is related to an update to my WP8 phone or a change in Google calendar API.
    Any help is much appreciated, this is driving me rather nuts.
    Thanks,
    Kaarel

    Further investigation reveals this only happens when the event is created from within WP native calendar app and disappears when I make an edit to the event in any other calendar client including Google web. So a more appropriate description of the problem would be:
    "Native calendar app keeps subtracting 1h off a Google calendar event on EVERY edit"
    Create an event at 2013/07/17 15:00 in WP native calendar app. Result: Event shows as 2013/07/17 15:00 in the calendar app for a few seconds, then updates itself to 2013/07/17 14:00.
    Edit the event title and save in WP native calendar app. Event time moves by -1h again to 2013/07/17 13:00.
    Edit the event title in Google web calendar.
    Subsequent edits in WP native calendar do not mess up the time any longer. If I fix the time to what I originally intended (2013/07/17 15:00) in WP native calendar app, it stays there and shows correctly in all previously mentioned calendar viewers.
    I just learned that Lumia 925 was released with GDR2 update pre-installed. This update is only now being made generally available. If the issue is secific to the CalDAV implementation in GDR2 rather than specific to my phone only, this would make a lot of angry people. I hope I'm wrong on this though as it's an extremely frustrating problem.

  • Problem while bringing Google Calendar events to Oracle Tables

    Hi Friends,
    I have written the following code to bring the Google Calendar Events to Oracle Tables...
    CREATE OR REPLACE procedure XX_DEV.authenticate_service_test(p_email in varchar2,p_password in varchar2)
    is
    l_request utl_http.req;
    l_response utl_http.resp;
    l_params varchar2(255);
    l_resp_data VARCHAR2(4000);-- CHARACTER SET;
    l_auth_token VARCHAR2(4000);
    l_cal_entry CLOB;
    v_response_xml XMLType;
    v_entry_id varchar2(100);
    xml_result xmltype;
    cnt number:= 0;
    v_xmldoc CLOB;
    v_start_time date;
    v_end_time date;
    cursor c1 is select x.title title, x.content content, x.where where, x.start_time start_time, x.end_time end_time, x.entry_id entry_id from
    xmltable('feed/entry'
    passing xmltype(v_xmldoc)
    columns title varchar2(1000) path '/entry/title/text()'
    ,content clob path '/entry/content/text()'
    ,where clob path '/entry/gd-where/@valueString'
    ,start_time varchar2(100) path '/entry/gd-when/@startTime'
    ,end_time varchar2(100) path '/entry/gd-when/@endTime'
    ,entry_id varchar2(1000) path '/entry/id'
    ) x ;
    begin
    -- access the oracle wallet to allow us to make an https request
    utl_http.set_wallet(path => 'file:/u01/app/oracle/product/11.2.0/owm/wallets/oracle11/',password => 'srisys123');
    -- set up the request body with our credentials
    l_params := 'Email=' || p_email || '&Passwd=' || p_password ||'&service=cl' || '&source=e-DBA-test-1.0';
    l_request := utl_http.begin_request('https://www.google.com/accounts/ClientLogin','POST','HTTP/1.1');--accounts/ClientLogin
    -- set the request headers
    utl_http.set_header(l_request,'Content-Type','application/x-www-form-urlencoded');
    utl_http.set_header(l_request,'Content-Length',length(l_params));
    -- write out the request body
    utl_http.write_text( l_request, l_params );
    -- get the response
    l_response := utl_http.get_response( r => l_request );
    dbms_output.put_line('Status Code: '||l_response.status_code);
    loop
    utl_http.read_line( r => l_response, data => l_resp_data, remove_crlf => TRUE);
    dbms_output.put_line(l_resp_data);
    if substr(l_resp_data, 1, 5) = 'Auth=' then
    l_auth_token := substr(l_resp_data, 6);
    end if;
    end loop;
    exception
    when utl_http.end_of_body then
    null;
    dbms_output.put_line('Auth Token: '||l_auth_token);
    utl_http.end_response ( l_response );
    -- replace the substitution variables in the template with the parameter values
    --utl_http.end_response ( l_response );
    l_request := utl_http.begin_request(
    'http://www.google.com/calendar/feeds/default/private/full',
    'GET',
    'HTTP/1.1');
    utl_http.set_header(
    l_request,
    'Content-Type',
    'application/atom+xml');
    utl_http.set_header(
    l_request,
    'Authorization',
    'GoogleLogin auth='||l_auth_token);
    l_response := utl_http.get_response( r => l_request );
    utl_http.read_text(
    l_response,
    l_cal_entry
    dbms_output.put_line('Status Code: ' || l_response.status_code);
    /*select replace(l_cal_entry,'<?xml version='||'''1.0'''||' encoding='||'''UTF-8'''||'?>','') into l_cal_entry from dual;
    select ltrim(l_cal_entry,substr(l_cal_entry,1,148)) into l_cal_entry from dual;
    select '<feed'||l_cal_entry into l_cal_entry from dual;
    select replace (l_cal_entry,':','-') into l_cal_entry from dual;*/
    dbms_output.put_line('Calendar Event: ' || l_cal_entry);
    -- xml_result :=XMLType.extract(l_cal_entry,'//title');
    delete from xml_test1;
    insert into xml_test1 values (l_cal_entry);
    utl_http.end_response ( l_response );
    select DATA into v_xmldoc from XML_TEST1;
    execute immediate 'alter session set events = ''31156 trace name context forever, level 2''';
    for i in c1
    loop
    l_cal_entry:= NULL;
    dbms_output.put_line('Result: '||i.title||'*'||i.content||'*'||i.name||'*'||i.start_time||'*'||i.end_time||'*'||i.entry_id);
    begin
    select 1 into cnt from events_bkp where entry_id = i.entry_id;
    select nvl(to_date(rtrim(replace(i.start_time,'T',' '),substr(replace(i.start_time,'T',' '),12,20))||
    replace(substr(replace(i.start_time,'T',' '),12,8),'-',':'),'yyyy-mm-dd hh24:mi:ss'),sysdate) into v_start_time from dual;
    select nvl(to_date(rtrim(replace(i.end_time,'T',' '),substr(replace(i.end_time,'T',' '),12,20))||
    replace(substr(replace(i.end_time,'T',' '),12,8),'-',':'),'yyyy-mm-dd hh24:mi:ss'),sysdate) into v_end_time from dual;
    update events_bkp set description = i.title, notes = nvl(i.content,'No Notes'), start_date_time = v_start_time, end_date_time = v_end_time
    where entry_id = i.entry_id;
    exception when others then
    select nvl(to_date(rtrim(replace(i.start_time,'T',' '),substr(replace(i.start_time,'T',' '),12,20))||
    replace(substr(replace(i.start_time,'T',' '),12,8),'-',':'),'yyyy-mm-dd hh24:mi:ss'),sysdate) into v_start_time from dual;
    select nvl(to_date(rtrim(replace(i.end_time,'T',' '),substr(replace(i.end_time,'T',' '),12,20))||
    replace(substr(replace(i.end_time,'T',' '),12,8),'-',':'),'yyyy-mm-dd hh24:mi:ss'),sysdate) into v_end_time from dual;
    insert into events_bkp values(events_seq.nextval, 9, 1,1, 4, i.title, nvl(i.content,'No Notes'), v_start_time, v_end_time,'','',
    4, 1, sysdate, 1, sysdate, 13, i.entry_id);
    end;
    commit;
    end loop;
    execute immediate 'alter session set events = ''31156 trace name context off''';
    end authenticate_service_test;
    I am able to execute it successfully with my username and password but I am getting error when the number of events are more than 15...
    The parameter l_cal_entry which is of clob datatype is not holding the whole xml data.
    Please advice....
    Thank You,
    Srikanth

    Hi Friends,
    Now I am able to load all the events of a user by adding the following code
    loop
    utl_http.read_text(l_response, l_cal);
    l_cal_entry:= l_cal_entry||l_cal;
    end loop;
    but I am getting problem when the user has more than one calendar. The Begin_request link I am using is...
    'https://www.google.com/calendar/feeds/default/private/full'
    Using this, I am able to get only the events of a default calendar associated to the user.
    How can I get the events of all calendars or a particular calendar associated with the user.
    I may have to change the above link... I have tried with various combinations by appending calendar id but I am unable get the right combination
    Please advice...
    Thank You,
    Srikanth

  • How do you view on iPhone events from iCal that are six months out?

    I am trying to synch my iCal with an iPhone. When I synch the calendar it will only show events for the next few weeks. How do I get my iPhone calendar to show events from iCal that are six or eight months out?
    Thanks

    Corey,
    Welcome to Apple Discussions.
    What calendars have you chosen to sync in iTunes>Info>Calendars?
    What happens in iTunes if you select your iPhone under "Devices," then choose Info>Advanced>Replace information on this iPhone>: and check "Calendars"/"Sync?"
    ;~)

  • When a third party program creates a new Google calendar event using a http link I cannot click the save button in Firefox 9.01 or 10b2.

    I use a TV listings program called DigiGuide. This has a script that opens a new Google Calendar event page in my browser for a specified TV program with all fields already completed. I then just have to click the SAVE button on the Google Calendar site to save the event - but since updating to 9.01 from 8.xx this button and others (Discard, Search) has no effect, although the cursor changes when over the button as if it recognised a link. Opening the same page in Chrome works fine. I have also noticed that Calendar's other buttons (e.g. next/previous period) can stop working on the main Calendar page, which I have as a pinned tab - in this event navigating away from Calendar and back again regains that functionality. The issue persists in Firefox 10b2.

    Further investigation reveals this only happens when the event is created from within WP native calendar app and disappears when I make an edit to the event in any other calendar client including Google web. So a more appropriate description of the problem would be:
    "Native calendar app keeps subtracting 1h off a Google calendar event on EVERY edit"
    Create an event at 2013/07/17 15:00 in WP native calendar app. Result: Event shows as 2013/07/17 15:00 in the calendar app for a few seconds, then updates itself to 2013/07/17 14:00.
    Edit the event title and save in WP native calendar app. Event time moves by -1h again to 2013/07/17 13:00.
    Edit the event title in Google web calendar.
    Subsequent edits in WP native calendar do not mess up the time any longer. If I fix the time to what I originally intended (2013/07/17 15:00) in WP native calendar app, it stays there and shows correctly in all previously mentioned calendar viewers.
    I just learned that Lumia 925 was released with GDR2 update pre-installed. This update is only now being made generally available. If the issue is secific to the CalDAV implementation in GDR2 rather than specific to my phone only, this would make a lot of angry people. I hope I'm wrong on this though as it's an extremely frustrating problem.

  • Script creates+deletes Google Calendar-events. (free SMS-notification)

    I posted this in another thread too, but since a discussion would be off-topic there (http://bbs.archlinux.org/viewtopic.php?id=64933):
    Here a Python script that creates a Google Calendar-event in the main calendar, with as subject the contents of a specified file.
    Feel free to post modifications/optimizations! I use it this way to get notified of unanswered conversations in finch (as in the thread above), it was easier to work with a file then with specifying arguments..
    PS. The script uses python-mechanize, which is in community.
    #!/usr/bin/python
    # From: gondil
    # To: the Arch Linux forums ;)
    # Version 2 (deletion added)
    import mechanize
    import sys
    import urllib2
    import httplib
    from urllib2 import HTTPError
    # Create a mechanize browser
    mech = mechanize.Browser()
    mech.set_handle_robots(False)
    # With Goggles desired UAgent
    mech.addheaders = [("User-agent", "Java/1.5.0_06")]
    # See the G-API: We need a some token here, that is displayed by /~pkelchte/ (mah personal php site on ESAT that only does that)
    mech.open("https://www.google.com/accounts/AuthSubRequest?scope=http://www.google.com/calendar/feeds/&session=1&secure=0&next=http://homes.esat.kuleuven.be/~pkelchte/index.php")
    # But before we get the token, we need to submit our user-data
    mech.select_form(nr=0)
    mech["Email"] = "" # REPLACE THIS WITH YOUR GOOGLE ACCOUNT
    mech["Passwd"] = "" # AND THIS WITH YOUR PASSWORD
    try:
    mech.submit()
    except:
    print "Did not submit credentials"
    sys.exit("Error in submitting credentials")
    # Because that's not enough, we need to confirm that we want to go trough with this and submit another form...
    mech.select_form(nr=0)
    mech.submit(id='allow')
    # By now, we have one token, but it's not the final token! We need *another* token, called the AuthSubSessionToken, sigh...
    mech.addheaders = [("Authorization", "AuthSub token=\"" + mech.response().read() + "\""), ("User-agent", "Java/1.5.0_06")]
    mech.open("http://www.google.com/accounts/AuthSubSessionToken")
    # A bunch of tokens later...
    # Let's use urllib2 to do this POST request (some xml-y thing is the string you would manually type in the "New event" box on Google Calendar)
    # Encore some headers
    authsub = "AuthSub token=\"" + mech.response().read().replace("\n","").split("=")[1] + "\""
    headers = {"Authorization": authsub, "User-Agent": "Java/1.5.0_06", "Content-Type": "application/atom+xml", "GData-Version": "2"}
    # Read the file that we're interested in! Damn, it's so interesting!!
    file = open('/home/gondil/public_html/fifo', 'r') # CHANGE THIS FILE WITH YOUR THING
    message = file.read()
    file.close()
    # The actual event
    event = """
    <entry xmlns='http://www.w3.org/2005/Atom' xmlns:gCal='http://schemas.google.com/gCal/2005'>
    <content type="html">""" + message + """</content>
    <gCal:quickadd value="true"/>
    </entry>
    req = urllib2.Request("http://www.google.com/calendar/feeds/default/private/full", event, headers)
    calresponse = urllib2.urlopen(req)
    # Normally, we stop here... but since Google likes traffic, we need to go to a slightly different url, with the same headers and POST data
    req2 = urllib2.Request(calresponse.geturl(), event, headers)
    try:
    calresponse2 = urllib2.urlopen(req2)
    # You can check but normally this is a 201 CREATED response or something, I don't really care... It's my code, right :P
    except HTTPError, e :
    # I placed this sleep to give the event at least a 20 second lifetime (poor, poor event...)
    import time
    time.sleep(20)
    # Retrieve the event's edit url
    eventurl = e.read().split("<link rel='edit' type='application/atom+xml' href='http://www.google.com")[1].split("'/>")[0]
    # The Deletion has to be done via httplib, because Google wants a DELETE request (urllib2 only handles GET and POST)
    conn = httplib.HTTPConnection("www.google.com")
    conn.request("DELETE", eventurl, "", headers)
    calresponse3 = conn.getresponse()
    # Again, they like to have a little more traffic, we need to append a session ID to that last url (we can find it in the redirect page)
    eventurl2 = calresponse3.read().split("HREF=\"")[1].split("\"")[0]
    # Ooh and here there is need of a new header, no questions please
    headers2 = {"Authorization": authsub, "User-Agent": "Java/1.5.0_06", "Content-Type": "application/atom+xml", "GData-Version": "2", "If-Match": "*"}
    conn.request("DELETE", eventurl2, "", headers2)
    calresponse4 = conn.getresponse()
    # No errors? Ok we can close the connection
    conn.close()
    index.php looks like this (again I don't guarantee that I'll keep my index.php page like that for eternity, but I'll notify you when the url changes):
    <?php
    print $_POST['token'];
    print $_GET['token'];
    ?>
    Last edited by gondil (2009-04-23 22:45:38)

    I posted this in another thread too, but since a discussion would be off-topic there (http://bbs.archlinux.org/viewtopic.php?id=64933):
    Here a Python script that creates a Google Calendar-event in the main calendar, with as subject the contents of a specified file.
    Feel free to post modifications/optimizations! I use it this way to get notified of unanswered conversations in finch (as in the thread above), it was easier to work with a file then with specifying arguments..
    PS. The script uses python-mechanize, which is in community.
    #!/usr/bin/python
    # From: gondil
    # To: the Arch Linux forums ;)
    # Version 2 (deletion added)
    import mechanize
    import sys
    import urllib2
    import httplib
    from urllib2 import HTTPError
    # Create a mechanize browser
    mech = mechanize.Browser()
    mech.set_handle_robots(False)
    # With Goggles desired UAgent
    mech.addheaders = [("User-agent", "Java/1.5.0_06")]
    # See the G-API: We need a some token here, that is displayed by /~pkelchte/ (mah personal php site on ESAT that only does that)
    mech.open("https://www.google.com/accounts/AuthSubRequest?scope=http://www.google.com/calendar/feeds/&session=1&secure=0&next=http://homes.esat.kuleuven.be/~pkelchte/index.php")
    # But before we get the token, we need to submit our user-data
    mech.select_form(nr=0)
    mech["Email"] = "" # REPLACE THIS WITH YOUR GOOGLE ACCOUNT
    mech["Passwd"] = "" # AND THIS WITH YOUR PASSWORD
    try:
    mech.submit()
    except:
    print "Did not submit credentials"
    sys.exit("Error in submitting credentials")
    # Because that's not enough, we need to confirm that we want to go trough with this and submit another form...
    mech.select_form(nr=0)
    mech.submit(id='allow')
    # By now, we have one token, but it's not the final token! We need *another* token, called the AuthSubSessionToken, sigh...
    mech.addheaders = [("Authorization", "AuthSub token=\"" + mech.response().read() + "\""), ("User-agent", "Java/1.5.0_06")]
    mech.open("http://www.google.com/accounts/AuthSubSessionToken")
    # A bunch of tokens later...
    # Let's use urllib2 to do this POST request (some xml-y thing is the string you would manually type in the "New event" box on Google Calendar)
    # Encore some headers
    authsub = "AuthSub token=\"" + mech.response().read().replace("\n","").split("=")[1] + "\""
    headers = {"Authorization": authsub, "User-Agent": "Java/1.5.0_06", "Content-Type": "application/atom+xml", "GData-Version": "2"}
    # Read the file that we're interested in! Damn, it's so interesting!!
    file = open('/home/gondil/public_html/fifo', 'r') # CHANGE THIS FILE WITH YOUR THING
    message = file.read()
    file.close()
    # The actual event
    event = """
    <entry xmlns='http://www.w3.org/2005/Atom' xmlns:gCal='http://schemas.google.com/gCal/2005'>
    <content type="html">""" + message + """</content>
    <gCal:quickadd value="true"/>
    </entry>
    req = urllib2.Request("http://www.google.com/calendar/feeds/default/private/full", event, headers)
    calresponse = urllib2.urlopen(req)
    # Normally, we stop here... but since Google likes traffic, we need to go to a slightly different url, with the same headers and POST data
    req2 = urllib2.Request(calresponse.geturl(), event, headers)
    try:
    calresponse2 = urllib2.urlopen(req2)
    # You can check but normally this is a 201 CREATED response or something, I don't really care... It's my code, right :P
    except HTTPError, e :
    # I placed this sleep to give the event at least a 20 second lifetime (poor, poor event...)
    import time
    time.sleep(20)
    # Retrieve the event's edit url
    eventurl = e.read().split("<link rel='edit' type='application/atom+xml' href='http://www.google.com")[1].split("'/>")[0]
    # The Deletion has to be done via httplib, because Google wants a DELETE request (urllib2 only handles GET and POST)
    conn = httplib.HTTPConnection("www.google.com")
    conn.request("DELETE", eventurl, "", headers)
    calresponse3 = conn.getresponse()
    # Again, they like to have a little more traffic, we need to append a session ID to that last url (we can find it in the redirect page)
    eventurl2 = calresponse3.read().split("HREF=\"")[1].split("\"")[0]
    # Ooh and here there is need of a new header, no questions please
    headers2 = {"Authorization": authsub, "User-Agent": "Java/1.5.0_06", "Content-Type": "application/atom+xml", "GData-Version": "2", "If-Match": "*"}
    conn.request("DELETE", eventurl2, "", headers2)
    calresponse4 = conn.getresponse()
    # No errors? Ok we can close the connection
    conn.close()
    index.php looks like this (again I don't guarantee that I'll keep my index.php page like that for eternity, but I'll notify you when the url changes):
    <?php
    print $_POST['token'];
    print $_GET['token'];
    ?>
    Last edited by gondil (2009-04-23 22:45:38)

  • How can I get ALL of my Google Calendars to show on the iCal on my iPhone? I see all of my Google Calendars on the iCal on my Mac, but I do not see them in the iCal on my iPhone. I only see one Google Cal, but not the others.

    How can I get ALL of my Google Calendars to show on the iCal on my iPhone?
    I see all of my Google Calendars on the iCal on my Mac, but I do not see them in the iCal on my iPhone. I only see one Google Cal, but not the others.

    https://www.google.com/calendar/iphoneselect

  • TS3999 I see all of my calendar events in iCal and on my iPhone, but not in the iCloud web app.  Any ideas why?

    I see all of my calendar events in iCal and on my iPhone, but not in the iCloud web app.  Any ideas why?

    If the calendar is on iCoud.com, all you would need to do to get it on your phone is go to Settings>iCloud on your phone, sign into your iCoud account and turn Calendars on.  The iCloud calendars will then download to your phone.

Maybe you are looking for

  • Wifi disconnects on highish throughput

    Hi, I've got wireless problems with the combination of my router and my laptop. Whenever I download something more than say 1MB the connection drops. This happens with Youtube, Google Image search and Pacman updates. The connection re-establishes aft

  • TS1717 iTunes upgrade trouble

    I Updated my iTunes on my laptop today but when I restarted the computer and tried to go in iTunes, I got an error message "This copy of iTunes is corrupted or is not installed correctly. Please reinstall iTunes". What do I do?

  • PerformancePoint Scorecard not usable by non-admin/creator

    [Using SharePoint 2013 Enterprise SP1] I (as a farm admin) have been successfully creating and using PerformancePoint Scorecards/KPIs which were created in Dashboard Designer. Another admin has been able to use them as well. But when I try to even ju

  • Flip book component in new version of Flash Cs

    Hi all, Realy i've thinking many times to have a plugin in adobe flash, that will include a flip book component wich will be easy to build an online magazine for our real estate agency in marrakesh, i've used the latest trial version of adobe flash C

  • Disable EWS

    Hello we are working on Exchange 2010. Now we decide to disable Mac outlook thus EWS. I did some google and found this post :http://blogs.technet.com/b/matabra/archive/2012/08/23/block-mobile-apps-that-use-exchange-web-services.aspx It's useful, when