title: Getting calendar from URL with thunderbird-lightning
body: <p><strong>To summarize what is coming:</strong></p>
  
  <ul>
  <li>How can I dispatch the calendar via a link?</li>
  <li>Why is the calendar fully working when first saved on my local PC and cannot be modified when taken directly from the web though it is imported without messages?</li>
  <li>How can I find the cause of the failed modification?</li>
  </ul>
  
  <p><strong>Full explanation:</strong></p>
  
  <p>I am developing an application which produces a ICS Calendar. This calendar is dispatched to users via a URL. So far, I found out the user can import the calendar through <code>Calendar tab</code> -> <code>New Calendar</code> -> <code>On the Network</code>. Then providing the URL where the calendar is generated and following the wizard causes a new calendar to be created. This works just fine, even though I would like to find a way to allow the user to import the calendar (triggering the wizard automatically if that's the case) just clicking on my link. I tried embedding the link in a mail, but then when clicked it triggers the browser (if it is provided in HTTP protocol or an error when provided with WebDAV protocol). Do you know any way to produce a link which can achieve my goal?<br /><br/>
  However, the real problem is another. When I import the calendar as described (<code>Calendar tab</code> -> <code>New Calendar</code> -> <code>On the Network</code>) and then I try to modify any event data, I get a <code>MODIFICATION_FAILED</code> message, and the error console simply shows</p>
  
  <pre><code>Timestamp: 03/14/2013 12:20:08 PM
  Error: An error occurred when writing to the calendar Test! Error code: MODIFICATION_FAILED. Description: 
  Source File: resource://calendar/modules/calUtils.jsm -&gt; file:///home/mdavi/.thunderbird/sdq097yy.default/extensions/%7Be2fda1a4-762b-4020-b5ad-a41df1933103%7D/calendar-js/calCalendarManager.js
  Line: 976
  </code></pre>
  
  <p>How can I find the cause of this error? Moreover, I tried to export the generated calendar (or to download it from my link) to an ICS file, then to open such file via <code>File</code> -> <code>Open</code> -> <code>Calendar File ...</code> without modifying anything in the exported file and in this way I can even modify event data. So why? The ICS file I generated is very simple and looks like:</p>
  
  <pre><code>BEGIN:VCALENDAR
  PRODID:-//Events Calendar//iCal4j //EN
  METHOD:PUBLISH
  VERSION:2.0
  CALSCALE:GREGORIAN
  BEGIN:VEVENT
  UID:...
  SUMMARY:...
  DTSTART:...
  DTEND:...
  DESCRIPTION:...
  LOCATION:...
  URL:...
  END:VEVENT
  END:VCALENDAR
  </code></pre>
  
  <p>All the properties of VEVENT are well formed.<br /><br /></p>