The internet calendar file "abc.ics" does not contain any appointments - c#

I have created a .ics VTODO calender, but when I open the file in Microsoft outlook its shows the following error
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//DDay.iCal//NONSGMLddaysoftware.com//EN
BEGIN:VTODO
CREATED:20070101T000000Z
DESCRIPTION:fdsdsfds
DTSTAMP:20070101T000000Z
DTSTART:20070101T080000
DUE;VALUE=DATE:20070107
DURATION:P5DT16H
SEQUENCE:0
STATUS:NEEDS-ACTION
SUMMARY:xxxx
UID:b6709c95-5523-46aa-a7e5-1b5ea034b86a
BEGIN:VALARM
ACTION:DISPLAY
DESCRIPTION:Reminder
TRIGGER:-PT30M
END:VALARM
END:VTODO
END:VCALENDAR

VTODO is not supported by Outlook: see Microsoft's spec (https://msdn.microsoft.com/en-gb/library/cc463911.aspx)

Related

How to extract data using Ical.Net?

I have an ics file I want to read data out from. I downloaded Ical.Net using Nuget and I'm trying to figure out how to work with it. All I want to do is get the same info as I would get if I uploaded my ics file to this website: https://icsconvert.appspot.com/
Which is, for each "event":
Summary
Description
Start
End
Location
But I don't understand how I can get that info out of the file. Here's what I have so far:
string filepath = #"C:\My\file\path\myIcs.ics";
System.IO.StreamReader file = new System.IO.StreamReader(filepath);
string content = file.ReadToEnd();
file.Close();
Ical.Net.Calendar calendar = Ical.Net.Calendar.Load(content);
foreach (var c in calendar.RecurringItems)
{
// 1. Do something!
// 2. ????
// 3. Profit!
}
Here's a sample file I got from here:
BEGIN:VCALENDAR
VERSION:2.0
CALSCALE:GREGORIAN
BEGIN:VEVENT
SUMMARY:Access-A-Ride Pickup
DTSTART;TZID=America/New_York:20130802T103400
DTEND;TZID=America/New_York:20130802T110400
LOCATION:1000 Broadway Ave.\, Brooklyn
DESCRIPTION: Access-A-Ride trip to 900 Jay St.\, Brooklyn
STATUS:CONFIRMED
SEQUENCE:3
BEGIN:VALARM
TRIGGER:-PT10M
DESCRIPTION:Pickup Reminder
ACTION:DISPLAY
END:VALARM
END:VEVENT
BEGIN:VEVENT
SUMMARY:Access-A-Ride Pickup
DTSTART;TZID=America/New_York:20130802T200000
DTEND;TZID=America/New_York:20130802T203000
LOCATION:900 Jay St.\, Brooklyn
DESCRIPTION: Access-A-Ride trip to 1000 Broadway Ave.\, Brooklyn
STATUS:CONFIRMED
SEQUENCE:3
BEGIN:VALARM
TRIGGER:-PT10M
DESCRIPTION:Pickup Reminder
ACTION:DISPLAY
END:VALARM
END:VEVENT
END:VCALENDAR
How can I get the data I want? I want to use the foreach to save that data into a custom list.
As far as I can see you just have a set of two separate events there, not recurring events (as in defined with an RRULE).
I think you would likely find what you need in calendar.Events instead (I've never used this library, just had a quick poke at the source code and it looks like the calendar class has an "Events" property).

Read Undelivered email body in C# windows form

I am developing one tool to keep track of emails and would like to trace the emails undelivered to sender.
I dont want to use any third party tool or any external reference
What I have tried?
-To read report Item but Body is in Chinese like language
-Googled on some solutions but nothing is working i.e. solution is related to
//PR_TRANSPORT_MESSAGE_HEADERS
link to get property name "http://schemas.microsoft.com/mapi/proptag/0x0C1A001F"
outlook PropertyAccessor class
PropName link is not working anymore.
Could anyone here please help me I would like to get from which sender the email delivery is failed.
Thank you in advance.
The PR_TRANSPORT_MESSAGE_HEADERS property contains the same Diagnostic information shown in the body. You just need to read it using the PropertyAccessor class and parse the string with From and To entries.
Outlook.PropertyAccessor oPA = reportItem.PropertyAccessor;
string transportHeaders = (string)oPA.GetProperty("http://schemas.microsoft.com/mapi/proptag/0x007D001E");

Google calendar incorrect imports DDay multiple-day events

I'm using a DDay library to create iCal file. Here's an example of one event that I created:
BEGIN:VCALENDAR
VERSION:2.0
METHOD:PUBLISH
PRODID:-//MyProduct
BEGIN:VEVENT
CATEGORIES:Office event
DESCRIPTION:Rudniy\, Kazahstan office has a work day.
DTEND;VALUE=DATE:20141207
DTSTAMP:20141230T085900Z
DTSTART;VALUE=DATE:20141206
SEQUENCE:0
SUMMARY:Work Day in RDN
UID:6418abbe-1904-40c4-8544-e87dd4f4c002
END:VEVENT
END:VCALENDAR
When I import that calendar to Google Calendar, the result event is only on 2014-12-06 and is one day long (instead of two).
Can please somebody tell what's wrong?
When you use end.date and start date properties, you will give date in the format "yyyy-mm-dd". In google calendar, these properties are used to create ONLY "All-day events". Here is link for the details on using properties.
Try using the properties end.dateTime(format is 2015-01-03T10:00:00.000-07:00) and start.dateTime properties to create multiple-day events.
Okay, finally I got it. The END date specifies NON-INCLUSIVE end date for event. So I just should add 1 day to each end date by myself.

how debug application using .wer files

I recently submitted application on windows marketplace and got the crashing report in .wer format. but I dont know how to understand the report to find out the problem.I am opening it into notepad but not able to understand anything and I am unable to open it in visual studio 2012.Kindly help
Here is the report content:
Version=1
EventType=MoAppCrash
EventTime=130416971751387322
ReportType=2
Consent=1
UploadTime=130416971751699856
ReportIdentifier=b78d10da-c17e-11e3-8252-2cd05aaed19e
IntegratorReportIdentifier=b78d10d9-c17e-11e3-8252-2cd05aaed19e
WOW64=1
NsAppName=praid:App
Response.BucketId=TestBucket
Response.BucketTable=4
Response.LegacyBucketId=TestBucket
Response.type=4
Sig[0].Name=Package Full Name
Sig[0].Value=14665AAQ.AAQ_1.0.3.11_neutral__mqjtjzf78eaaj
Sig[1].Name=Application Name
Sig[1].Value=praid:App
Sig[2].Name=Application Version
Sig[2].Value=1.0.0.0
Sig[3].Name=Application Timestamp
Sig[3].Value=5347e402
Sig[4].Name=Fault Module Name
Sig[4].Value=combase.dll
Sig[5].Name=Fault Module Version
Sig[5].Value=6.3.9600.16520
Sig[6].Name=Fault Module Timestamp
Sig[6].Value=52e6927e
Sig[7].Name=Exception Code
Sig[7].Value=800f1000
Sig[8].Name=Exception Offset
Sig[8].Value=0007fd17
DynamicSig[1].Name=OS Version
DynamicSig[1].Value=6.3.9600.2.0.0.256.48
DynamicSig[2].Name=Locale ID
DynamicSig[2].Value=1033
DynamicSig[22].Name=Additional Information 1
DynamicSig[22].Value=896a
DynamicSig[23].Name=Additional Information 2
DynamicSig[23].Value=896a5d446a93e35895a2b8d22860148e
DynamicSig[24].Name=Additional Information 3
DynamicSig[24].Value=0488
DynamicSig[25].Name=Additional Information 4
DynamicSig[25].Value=04885d6165bbbf9c1e9404f1069bd19d
UI[2]=C:\Program Files\WindowsApps\14665AAQ.AAQ_1.0.3.11_neutral__mqjtjzf78eaaj\AskAQuestion.exe
LoadedModule[0]=C:\Program Files\WindowsApps\14665AAQ.AAQ_1.0.3.11_neutral__mqjtjzf78eaaj\AskAQuestion.exe
LoadedModule[1]=C:\Windows\SYSTEM32\ntdll.dll
LoadedModule[2]=C:\Windows\SYSTEM32\MSCOREE.DLL
LoadedModule[3]=C:\Windows\SYSTEM32\KERNEL32.dll
LoadedModule[4]=C:\Windows\SYSTEM32\KERNELBASE.dll
LoadedModule[5]=C:\Windows\SYSTEM32\ADVAPI32.dll
LoadedModule[6]=C:\Windows\SYSTEM32\msvcrt.dll
LoadedModule[7]=C:\Windows\SYSTEM32\sechost.dll
LoadedModule[8]=C:\Windows\SYSTEM32\RPCRT4.dll
LoadedModule[9]=C:\Windows\SYSTEM32\SspiCli.dll
LoadedModule[10]=C:\Windows\SYSTEM32\CRYPTBASE.dll
LoadedModule[11]=C:\Windows\SYSTEM32\bcryptPrimitives.dll
LoadedModule[12]=C:\Windows\Microsoft.NET\Framework\v4.0.30319\mscoreei.dll
LoadedModule[13]=C:\Windows\SYSTEM32\SHLWAPI.dll
LoadedModule[14]=C:\Windows\SYSTEM32\combase.dll
LoadedModule[15]=C:\Windows\SYSTEM32\USER32.dll
LoadedModule[16]=C:\Windows\SYSTEM32\GDI32.dll
LoadedModule[17]=C:\Windows\system32\IMM32.DLL
LoadedModule[18]=C:\Windows\SYSTEM32\MSCTF.dll
LoadedModule[19]=C:\Windows\Microsoft.NET\Framework\v4.0.30319\clr.dll
LoadedModule[20]=C:\Windows\SYSTEM32\MSVCR120_CLR0400.dll
LoadedModule[21]=C:\Windows\SYSTEM32\kernel.appcore.dll
LoadedModule[22]=C:\Windows\SYSTEM32\ole32.dll
LoadedModule[23]=C:\Windows\assembly\NativeImages_v4.0.30319_32\mscorlib\ebdd49343f711b2029293f8e621b28a2\mscorlib.ni.dll
LoadedModule[24]=C:\Windows\System32\twinapi.appcore.dll
LoadedModule[25]=C:\Windows\System32\WinTypes.dll
LoadedModule[26]=C:\Windows\Microsoft.NET\Framework\v4.0.30319\clrjit.dll
LoadedModule[27]=C:\Windows\SYSTEM32\OLEAUT32.dll
LoadedModule[28]=C:\Windows\System32\Windows.UI.Xaml.dll
LoadedModule[29]=C:\Windows\SYSTEM32\UIAutomationCore.DLL
LoadedModule[30]=C:\Windows\SYSTEM32\NInput.dll
LoadedModule[31]=C:\Windows\SYSTEM32\WININET.dll
LoadedModule[32]=C:\Windows\SYSTEM32\d3d11.dll
LoadedModule[33]=C:\Windows\SYSTEM32\dwmapi.dll
LoadedModule[34]=C:\Windows\SYSTEM32\UxTheme.dll
LoadedModule[35]=C:\Windows\SYSTEM32\XmlLite.dll
LoadedModule[36]=C:\Windows\SYSTEM32\SHELL32.dll
LoadedModule[37]=C:\Windows\SYSTEM32\urlmon.dll
LoadedModule[38]=C:\Windows\SYSTEM32\TWINAPI.dll
LoadedModule[39]=C:\Windows\SYSTEM32\iertutil.dll
LoadedModule[40]=C:\Windows\SYSTEM32\dxgi.dll
LoadedModule[41]=C:\Windows\SYSTEM32\shcore.dll
LoadedModule[42]=C:\Windows\SYSTEM32\CRYPTSP.dll
LoadedModule[43]=C:\Windows\system32\rsaenh.dll
LoadedModule[44]=C:\Windows\SYSTEM32\bcrypt.dll
LoadedModule[45]=C:\Windows\SYSTEM32\actxprxy.dll
LoadedModule[46]=C:\Program Files (x86)\Common Files\microsoft shared\ink\tiptsf.dll
LoadedModule[47]=C:\Windows\SYSTEM32\dwrite.dll
LoadedModule[48]=C:\Windows\SYSTEM32\igd10iumd32.dll
LoadedModule[49]=C:\Windows\SYSTEM32\ncrypt.dll
LoadedModule[50]=C:\Windows\SYSTEM32\NTASN1.dll
LoadedModule[51]=C:\Windows\SYSTEM32\igdusc32.dll
LoadedModule[52]=C:\Windows\SYSTEM32\d2d1.dll
LoadedModule[53]=C:\Windows\SYSTEM32\dcomp.dll
LoadedModule[54]=C:\Windows\SYSTEM32\MrmCoreR.dll
LoadedModule[55]=C:\Windows\SYSTEM32\Bcp47Langs.dll
LoadedModule[56]=C:\Windows\SYSTEM32\profapi.dll
LoadedModule[57]=C:\Windows\System32\Windows.UI.dll
LoadedModule[58]=C:\Windows\assembly\NativeImages_v4.0.30319_32\System\8455c031f8ffe82a0109c563873260e8\System.ni.dll
LoadedModule[59]=C:\Windows\assembly\NativeImages_v4.0.30319_32\System.Runt0d283adf#\e209e80a78aee1367c92f1dd884d8f58\System.Runtime.WindowsRuntime.ni.dll
LoadedModule[60]=C:\Windows\assembly\NativeImages_v4.0.30319_32\System.Runtc259d85b#\00fd6b9fc7353b024079f65164bdc73f\System.Runtime.WindowsRuntime.UI.Xaml.ni.dll
LoadedModule[61]=C:\Windows\System32\Windows.ApplicationModel.dll
LoadedModule[62]=C:\Windows\system32\windowscodecs.dll
LoadedModule[63]=C:\Windows\SYSTEM32\PhotoMetadataHandler.dll
LoadedModule[64]=C:\Windows\SYSTEM32\PROPSYS.dll
LoadedModule[65]=C:\Windows\SYSTEM32\oleacc.dll
LoadedModule[66]=C:\Windows\Microsoft.NET\Framework\v4.0.30319\diasymreader.dll
State[0].Key=Transport.DoneStage1
State[0].Value=1
FriendlyEventName=Stopped working
ConsentKey=MoAppCrash
AppName=14665AAQ.AAQ_mqjtjzf78eaaj!App
AppPath=C:\Program Files\WindowsApps\14665AAQ.AAQ_1.0.3.11_neutral__mqjtjzf78eaaj\AskAQuestion.exe
NsPartner=windows
NsGroup=windows8
ApplicationIdentity=254467B9963B346A2B88CAE91E846F7F
You can't debug application crashes with this .wer files.
The only useful information is the error code 800f1000:
C:\Users\André>err 800f1000
# for hex 0x800f1000 / decimal -2146496512
SPAPI_E_ERROR_NOT_INSTALLED winerror.h
# No installed components were detected.
# 1 matches found for "800f1000"
You need a dmp file which you can get from the Quality Reports page and debug it.

Outlook 2010 shows time one hour ahead

I have created following ".ics" file. When I open it in Google and iCal it shows correct time but when I open in Outlook 2010 it shows time one hour ahead. Any help?
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//www.marudot.com//iCal Event Maker
X-WR-TIMEZONE:America/Los_Angeles
BEGIN:VEVENT
DTSTART;TZID=America/Los_Angeles:20140510T110000
DTEND;TZID=America/Los_Angeles:20140510T111500
SUMMARY:Appointment-11:00 AM-PST
DESCRIPTION:Appointment-11:00 AM-PST
LOCATION:Location: TBD
END:VEVENT
END:VCALENDAR
When using local time with timezone, adding a TZID to all date related properties is not enough. That is because there is no global registry of TZID that is understood by all clients. Hence, one must include in the iCalendar stream the timezone definition that corresponds to this TIZD.
In other words, your stream is not iCalendar compliant. Before the event (before BEGIN:VEVENT), you should have a proper VTIMEZONE definition corresponding to the TZID America/Los_Angeles. See https://www.rfc-editor.org/rfc/rfc5545#section-3.8.3.1
In your case, it would be something like:
BEGIN:VTIMEZONE
TZID:America/Los_Angeles
TZURL:http://tzurl.org/zoneinfo/America/Los_Angeles
X-LIC-LOCATION:America/Los_Angeles
BEGIN:DAYLIGHT
TZOFFSETFROM:-0800
TZOFFSETTO:-0700
TZNAME:PDT
DTSTART:20070311T020000
RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=2SU
END:DAYLIGHT
BEGIN:STANDARD
TZOFFSETFROM:-0700
TZOFFSETTO:-0800
TZNAME:PST
DTSTART:20071104T020000
RRULE:FREQ=YEARLY;BYMONTH=11;BYDAY=1SU
END:STANDARD
END:VTIMEZONE
I don't think "TZID=America/Los_Angeles" is a time zone that Outlook understand. Try to create a an appointment in Outlook and save it as an ICS file. What TZ does Outlook use?

Categories

Resources