69:
How do I encode data as ICalendar format

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content do
	begin
		with Components.Add('VCALENDAR') do
		begin
			Properties.Add('VERSION','2.1').Parameters.Add('UNICODE',OleVariant(ICalendar1.toICalendar[OleVariant(True),EXICALENDARLib_TLB.exPropertyTypeBoolean]));
			Properties.Add('TEXT','This is just a bit of text to be encoded.');
			Properties.Add('BINARY',OleVariant(ICalendar1.toICalendar['This is just a bit of text to be encoded.',EXICALENDARLib_TLB.exPropertyTypeBinary]));
			with Components.Add('VEVENT') do
			begin
				Properties.Add('DTSTART','1/1/2001');
				Properties.Add('DTEND','1/2/2001 10:00:00 AM');
			end;
		end;
	end;
	OutputDebugString( Save() );
end
68:
How do I get the occurrences between giving start/end margins

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( 'AsArray: ' );
	OutputDebugString( RecurRange['DTSTART=19970310;FREQ=YEARLY;INTERVAL=2;COUNT=10;BYMONTH=1,2,3','1/1/2001','1/1/2002'] );
	OutputDebugString( 'AsString: ' );
	OutputDebugString( RecurRangeAsString['DTSTART=19970310;FREQ=YEARLY;INTERVAL=2;COUNT=10;BYMONTH=1,2,3','1/1/2001','1/1/2002'] );
end
67:
How do I get the value of specified part in the recurrence expression

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( 'FREQ: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurFREQ] );
	OutputDebugString( 'DTSTART: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurDTSTART] );
	OutputDebugString( 'UNTIL: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurUNTIL] );
	OutputDebugString( 'COUNT: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurCOUNT] );
	OutputDebugString( 'INTERVAL: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurINTERVAL] );
	OutputDebugString( 'WKST: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurWKST] );
	OutputDebugString( 'BYDAY: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurBYDAY] );
	OutputDebugString( 'BYMONTHDAY: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurBYMONTHDAY] );
	OutputDebugString( 'BYYEARDAY: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurBYYEARDAY] );
	OutputDebugString( 'BYWEEKNO: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurBYWEEKNO] );
	OutputDebugString( 'BYMONTH: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurBYMONTH] );
	OutputDebugString( 'BYSETPOS: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurBYSETPOS] );
	OutputDebugString( 'BYHOUR: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurBYHOUR] );
	OutputDebugString( 'BYMINUTE: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurBYMINUTE] );
	OutputDebugString( 'BYSECOND: ' );
	OutputDebugString( RecurPartValue['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',EXICALENDARLib_TLB.exRecurBYSECOND] );
end
66:
How do I check if the recurrence expression is syntactically correct (method 2)

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( '1.A) SyntaxError: ' );
	OutputDebugString( RecurPartValue['DTSTART=20151205;FREQ=DAILY;BYDAY=MO',EXICALENDARLib_TLB.exRecurSyntaxError] );
	OutputDebugString( '1.B) SyntaxErrorInfo: ' );
	OutputDebugString( RecurPartValue['DTSTART=20151205;FREQ=DAILY;BYDAY=MO',EXICALENDARLib_TLB.exRecurSyntaxErrorInfo] );
	OutputDebugString( '2.A) SyntaxError: ' );
	OutputDebugString( RecurPartValue['FREQ=DAILY;BYDAY=MO',EXICALENDARLib_TLB.exRecurSyntaxError] );
	OutputDebugString( '2.B) SyntaxErrorInfo: ' );
	OutputDebugString( RecurPartValue['FREQ=DAILY;BYDAY=MO',EXICALENDARLib_TLB.exRecurSyntaxErrorInfo] );
end
65:
How do I check if the recurrence expression is syntactically correct (method 1)

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( '1. If negative, the expression is incorrect' );
	OutputDebugString( RecurCheck['DTSTART=20151205;FREQ=DAILY;BYDAY=MO','12/5/2015'] );
	OutputDebugString( '2. If negative, the expression is incorrect' );
	OutputDebugString( RecurCheck['junk','1/1/2001'] );
end
64:
How do I check if a specified date match the giving recurrence

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( '12/5/2015' );
	OutputDebugString( RecurCheck['DTSTART=20151205;FREQ=DAILY;BYDAY=MO','12/5/2015'] );
	OutputDebugString( '12/7/2015' );
	OutputDebugString( RecurCheck['DTSTART=20151205;FREQ=DAILY;BYDAY=MO','12/7/2015'] );
end
63:
Recur: The 2nd to last weekday of the month

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970929;FREQ=MONTHLY;BYDAY=MO,TU,WE,TH,FR;BYSETPOS=-2',OleVariant(12)] );
end
62:
Recur: The 3rd instance into the month of one of Tuesday, Wednesday or Thursday, for the next 3 months

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970904;FREQ=MONTHLY;COUNT=3;BYDAY=TU,WE,TH;BYSETPOS=3',OleVariant(12)] );
end
61:
Recur: The last work day of the month

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970805;FREQ=MONTHLY;BYDAY=MO,TU,WE,TH,FR;BYSETPOS=-1',OleVariant(12)] );
end
60:
Recur: An example where the days generated makes a difference because of WKST (Sample 2)

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=SU',OleVariant(12)] );
end
59:
Recur: An example where the days generated makes a difference because of WKST (Sample 1)

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970805T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU;WKST=MO',OleVariant(12)] );
end
58:
Recur: Every 20 minutes from 9:00 AM to 4:40 PM every day

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=DAILY;BYHOUR=9,10,11,12,13,14,15,16;BYMINUTE=0,20,40',OleVariant(12)] );
end
57:
Recur: Every hour and a half for 4 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=MINUTELY;INTERVAL=90;COUNT=4',OleVariant(12)] );
end
56:
Recur: Every 15 minutes for 6 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=MINUTELY;INTERVAL=15;COUNT=6',OleVariant(12)] );
end
55:
Recur: Every 3 hours from 9:00 AM to 5:00 PM on a specific day

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=HOURLY;INTERVAL=3;UNTIL=19970902T170000Z',OleVariant(12)] );
end
54:
Recur: Every four years, the first Tuesday after a Monday in November, forever (U.S. Presidential Election day)

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19961105T090000;FREQ=YEARLY;INTERVAL=4;BYMONTH=11;BYDAY=TU;BYMONTHDAY=2,3,4,5,6,7,8',OleVariant(12)] );
end
53:
Recur: The first Saturday that follows the first Sunday of the month, forever

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970913T090000;FREQ=MONTHLY;BYDAY=SA;BYMONTHDAY=7,8,9,10,11,12,13',OleVariant(12)] );
end
52:
Recur: Every Friday the 13th, forever

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=MONTHLY;BYDAY=FR;BYMONTHDAY=13',OleVariant(12)] );
end
51:
Recur: Every Thursday, but only during June, July, and August, forever

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970605T090000;FREQ=YEARLY;BYDAY=TH;BYMONTH=6,7,8',OleVariant(12)] );
end
50:
Recur: Every Thursday in March, forever

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970313T090000;FREQ=YEARLY;BYMONTH=3;BYDAY=TH',OleVariant(12)] );
end
49:
Recur: Monday of week number 20 (where the default start of the week is Monday), forever

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970512T090000;FREQ=YEARLY;BYWEEKNO=20;BYDAY=MO',OleVariant(12)] );
end
48:
Recur: Every 20th Monday of the year, forever

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970101T090000;FREQ=YEARLY;BYDAY=20MO',OleVariant(12)] );
end
47:
Recur: Every 3rd year on the 1st, 100th and 200th day for 10 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970101T090000;FREQ=YEARLY;INTERVAL=3;COUNT=10;BYYEARDAY=1,100,200',OleVariant(12)] );
end
46:
Recur: Every other year on January, February, and March for 10 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970310T090000;FREQ=YEARLY;INTERVAL=2;COUNT=10;BYMONTH=1,2,3',OleVariant(12)] );
end
45:
Recur: Yearly in June and July for 10 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970610T090000;FREQ=YEARLY;COUNT=10;BYMONTH=6,7',OleVariant(12)] );
end
44:
Recur: Every Tuesday, every other month

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=MONTHLY;INTERVAL=2;BYDAY=TU',OleVariant(12)] );
end
43:
Recur: Every 18 months on the 10th thru 15th of the month for 10 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970910T090000;FREQ=MONTHLY;INTERVAL=18;COUNT=10;BYMONTHDAY=10,11,12,13,14,15',OleVariant(12)] );
end
42:
Recur: Monthly on the first and last day of the month for 10 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970930T090000;FREQ=MONTHLY;COUNT=10;BYMONTHDAY=1,-1',OleVariant(12)] );
end
41:
Recur: Monthly on the 2nd and 15th of the month for 10 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=MONTHLY;COUNT=10;BYMONTHDAY=2,15',OleVariant(12)] );
end
40:
Recur: Monthly on the third to the last day of the month, forever

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970928T090000;FREQ=MONTHLY;BYMONTHDAY=-3',OleVariant(12)] );
end
39:
Recur: Monthly on the second to last Monday of the month for 6 months

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970922T090000;FREQ=MONTHLY;COUNT=6;BYDAY=-2MO',OleVariant(12)] );
end
38:
Recur: Every other month on the 1st and last Sunday of the month for 10 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970907T090000;FREQ=MONTHLY;INTERVAL=2;COUNT=10;BYDAY=1SU,-1SU',OleVariant(12)] );
end
37:
Recur: Monthly on the 1st Friday until December 24, 1997

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970905T090000;FREQ=MONTHLY;UNTIL=19971224T000000Z;BYDAY=1FR',OleVariant(12)] );
end
36:
Recur: Monthly on the 1st Friday for ten occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970905T090000;FREQ=MONTHLY;COUNT=10;BYDAY=1FR',OleVariant(12)] );
end
35:
Recur: Every other week on Tuesday and Thursday, for 8 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=WEEKLY;INTERVAL=2;COUNT=8;WKST=SU;BYDAY=TU,TH',OleVariant(12)] );
end
34:
Recur: Every other week on Monday, Wednesday and Friday until December 24, 1997, but starting on Tuesday, September 2, 1997

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=WEEKLY;INTERVAL=2;UNTIL=19971224T000000Z;WKST=SU;BYDAY=MO,WE,FR',OleVariant(12)] );
end
33:
Recur: Weekly on Tuesday and Thursday for 5 weeks

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=WEEKLY;UNTIL=19971007T000000Z;WKST=SU;BYDAY=TU,TH',OleVariant(12)] );
end
32:
Recur: Weekly on Tuesday and Thursday for 5 weeks

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=WEEKLY;COUNT=10;WKST=SU;BYDAY=TU,TH',OleVariant(12)] );
end
31:
Recur: Every other day - forever

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=DAILY;INTERVAL=2',OleVariant(12)] );
end
30:
Recur: Daily until December 24, 1997

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=DAILY;UNTIL=19971224T000000Z',OleVariant(12)] );
end
29:
Recur: Daily for 10 occurrences

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( RecurAllAsString['DTSTART=19970902T090000;FREQ=DAILY;COUNT=10',OleVariant(12)] );
end
28:
How can I add a property of UTC offset type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('UTCOffset','+0100');
	end;
	OutputDebugString( Save() );
end
27:
How can I add a property of URI type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('URI','http://www.exontrol.com');
	end;
	OutputDebugString( Save() );
end
26:
How can I add a property of time type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Time1','12:00:00 PM');
		Properties.Add('Time2',OleVariant(ICalendar1.toICalendar[OleVariant(0.5),EXICALENDARLib_TLB.exPropertyTypeTime]));
		with Properties.Add('Time3',Null) do
		begin
			Value := OleVariant(0.5);
			Type := EXICALENDARLib_TLB.exPropertyTypeTime;
		end;
	end;
	OutputDebugString( Save() );
end
25:
How can I add a property of text/string type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Text1','A1');
		Properties.Add('Text2',OleVariant(ICalendar1.toICalendar['A1',EXICALENDARLib_TLB.exPropertyTypeText]));
		with Properties.Add('Text3',Null) do
		begin
			Value := 'A1';
			Type := EXICALENDARLib_TLB.exPropertyTypeText;
		end;
	end;
	OutputDebugString( Save() );
end
24:
How can I find properties of recurence type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Recur','FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=SA,SU');
	end;
	p := Root.Properties.Item['Recur'];
	i := toICalendar[p.Value,p.GuessType];
	OutputDebugString( 'icalendar:' );
	OutputDebugString( i );
	OutputDebugString( 'all:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,''] );
	OutputDebugString( 'FREQ:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'FREQ'] );
	OutputDebugString( 'UNTIL:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'UNTIL'] );
	OutputDebugString( 'COUNT:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'COUNT'] );
	OutputDebugString( 'INTERVAL:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'INTERVAL'] );
	OutputDebugString( 'BYSECOND:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'BYSECOND'] );
	OutputDebugString( 'BYMINUTE:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'BYMINUTE'] );
	OutputDebugString( 'BYHOUR:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'BYHOUR'] );
	OutputDebugString( 'BYDAY:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'BYDAY'] );
	OutputDebugString( 'BYMONTHDAY:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'BYMONTHDAY'] );
	OutputDebugString( 'BYYEARDAY:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'BYYEARDAY'] );
	OutputDebugString( 'BYWEEKNO:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'BYWEEKNO'] );
	OutputDebugString( 'BYMONTH:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'BYMONTH'] );
	OutputDebugString( 'BYSETPOS:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'BYSETPOS'] );
	OutputDebugString( 'WKST:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'WKST'] );
end
23:
How can I add a property of recurrence type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Recur','FREQ=WEEKLY;INTERVAL=2;COUNT=4;BYDAY=TU,SU');
	end;
	OutputDebugString( Save() );
end
22:
How can I find the duration in weeks, days, hours, minutes, seconds from a property of duration type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Period',OleVariant(ICalendar1.valuesToICalendar['Start=#1/1/2001#;Duration=1',EXICALENDARLib_TLB.exPropertyTypePeriod]));
	end;
	p := Root.Properties.Item['Period'];
	i := toICalendar[p.Value,p.GuessType];
	OutputDebugString( 'icalendar:' );
	OutputDebugString( i );
	OutputDebugString( 'all:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,''] );
	OutputDebugString( 'start:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'Start'] );
	OutputDebugString( 'end:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'End'] );
	OutputDebugString( 'duration:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'Duration'] );
	OutputDebugString( 'weeks:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'W'] );
	OutputDebugString( 'days:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'D'] );
	OutputDebugString( 'hour:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'H'] );
	OutputDebugString( 'min:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'M'] );
	OutputDebugString( 'sec:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'S'] );
end
21:
How can I add a property of period type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Period1',OleVariant(ICalendar1.valuesToICalendar['Start=#1/1/2001#;Duration=1',EXICALENDARLib_TLB.exPropertyTypePeriod]));
		Properties.Add('Period2',OleVariant(ICalendar1.valuesToICalendar['Start=#1/1/2001#;End=#1/2/2001#',EXICALENDARLib_TLB.exPropertyTypePeriod]));
		Properties.Add('Period3',OleVariant(ICalendar1.valuesToICalendar['Duration=1;End=#1/2/2001#',EXICALENDARLib_TLB.exPropertyTypePeriod]));
	end;
	OutputDebugString( Save() );
end
20:
How can I add a property of integer type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Integer1',OleVariant(1));
		Properties.Add('Integer2',OleVariant(ICalendar1.toICalendar[OleVariant(1),EXICALENDARLib_TLB.exPropertyTypeInteger]));
		with Properties.Add('Integer3',Null) do
		begin
			Value := OleVariant(1);
			Type := EXICALENDARLib_TLB.exPropertyTypeInteger;
		end;
	end;
	OutputDebugString( Save() );
end
19:
How can I add a property of float type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Float1',OleVariant(1.5));
		Properties.Add('Float2',OleVariant(ICalendar1.toICalendar[OleVariant(1.5),EXICALENDARLib_TLB.exPropertyTypeFloat]));
		with Properties.Add('Float3',Null) do
		begin
			Value := OleVariant(1.5);
			Type := EXICALENDARLib_TLB.exPropertyTypeFloat;
		end;
	end;
	OutputDebugString( Save() );
end
18:
How do I get the type of the property

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Duration1',OleVariant(ICalendar1.toICalendar[OleVariant(2.5),EXICALENDARLib_TLB.exPropertyTypeDuration]));
		with Properties.Add('Duration2',Null) do
		begin
			Value := OleVariant(2.5);
			Type := EXICALENDARLib_TLB.exPropertyTypeDuration;
		end;
	end;
	with Root.Properties.Item['Duration1'] do
	begin
		OutputDebugString( Name );
		OutputDebugString( 'Guess' );
		OutputDebugString( GuessType );
		OutputDebugString( Name );
		OutputDebugString( 'Type' );
		OutputDebugString( Type );
	end;
	with Root.Properties.Item['Duration2'] do
	begin
		OutputDebugString( Name );
		OutputDebugString( 'Guess' );
		OutputDebugString( GuessType );
		OutputDebugString( Name );
		OutputDebugString( 'Type' );
		OutputDebugString( Type );
	end;
end
17:
How can I get values of the duration iCalendar format

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	OutputDebugString( 'all:' );
	OutputDebugString( valuesFromICalendar['P1D',EXICALENDARLib_TLB.exPropertyTypeDuration,''] );
	OutputDebugString( 'duration:' );
	OutputDebugString( valuesFromICalendar['P1D',EXICALENDARLib_TLB.exPropertyTypeDuration,'Duration'] );
end
16:
How can I find the duration in weeks, days, hours, minutes, seconds from a property of duration type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Duration',OleVariant(ICalendar1.toICalendar[OleVariant(3.325),EXICALENDARLib_TLB.exPropertyTypeDuration]));
	end;
	p := Root.Properties.Item['Duration'];
	i := toICalendar[p.Value,p.GuessType];
	OutputDebugString( 'icalendar:' );
	OutputDebugString( i );
	OutputDebugString( 'all:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,''] );
	OutputDebugString( 'duration:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'Duration'] );
	OutputDebugString( 'weeks:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'W'] );
	OutputDebugString( 'days:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'D'] );
	OutputDebugString( 'hour:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'H'] );
	OutputDebugString( 'min:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'M'] );
	OutputDebugString( 'sec:' );
	OutputDebugString( valuesFromICalendar[i,p.GuessType,'S'] );
end
15:
How can I add a property of duration type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Duration1',OleVariant(ICalendar1.toICalendar[OleVariant(2.5),EXICALENDARLib_TLB.exPropertyTypeDuration]));
		with Properties.Add('Duration2',Null) do
		begin
			Value := OleVariant(2.5);
			Type := EXICALENDARLib_TLB.exPropertyTypeDuration;
		end;
		Properties.Add('Duration3',OleVariant(ICalendar1.valuesToICalendar['D=2;H=12',EXICALENDARLib_TLB.exPropertyTypeDuration]));
	end;
	OutputDebugString( Save() );
end
14:
How can I add a property of date-time type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('DateTime1','1/1/2001 12:00:00 PM');
		Properties.Add('DateTime2',OleVariant(ICalendar1.toICalendar['1/1/2001',EXICALENDARLib_TLB.exPropertyTypeDateTime]));
		with Properties.Add('DateTime3',Null) do
		begin
			Value := '1/1/2001';
			Type := EXICALENDARLib_TLB.exPropertyTypeDateTime;
		end;
	end;
	OutputDebugString( Save() );
end
13:
How can I add a property of date type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Date1','1/1/2001');
		Properties.Add('Date2',OleVariant(ICalendar1.toICalendar['1/1/2001',EXICALENDARLib_TLB.exPropertyTypeDate]));
		with Properties.Add('Date3',Null) do
		begin
			Value := '1/1/2001';
			Type := EXICALENDARLib_TLB.exPropertyTypeDate;
		end;
	end;
	OutputDebugString( Save() );
end
12:
How can I add a property of Calendar User Address type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('caladdress1','mailto:support@exontrol.com');
		Properties.Add('caladdress2',OleVariant(ICalendar1.toICalendar['mailto:support@exontrol.com',EXICALENDARLib_TLB.exPropertyTypeCalAddress]));
		with Properties.Add('caladdress3',Null) do
		begin
			Value := 'mailto:support@exontrol.com';
			Type := EXICALENDARLib_TLB.exPropertyTypeCalAddress;
		end;
	end;
	OutputDebugString( Save() );
end
11:
How can I add a property of boolean type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Boolean1',OleVariant(True));
		Properties.Add('Boolean2',OleVariant(ICalendar1.toICalendar['TRUE',EXICALENDARLib_TLB.exPropertyTypeBoolean]));
		with Properties.Add('Boolean3',Null) do
		begin
			Value := OleVariant(0);
			Type := EXICALENDARLib_TLB.exPropertyTypeBoolean;
		end;
	end;
	OutputDebugString( Save() );
end
10:
How can I add a property of binary type

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		Properties.Add('Binary1',OleVariant(ICalendar1.toICalendar['This is a bit of text converted to binary',EXICALENDARLib_TLB.exPropertyTypeBinary]));
		with Properties.Add('Binary2',Null) do
		begin
			Value := 'This is a bit of text converted to binary';
			Type := EXICALENDARLib_TLB.exPropertyTypeBinary;
		end;
	end;
	OutputDebugString( Save() );
end
9:
How can I access the root element of the iCalendar format

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	Load('BEGIN:VCALENDAR\r\nVERSION:2.0\r\nEND:VCALENDAR');
	OutputDebugString( Root.Name );
	OutputDebugString( Root.Properties.Item['Version'].Value );
end
8:
How can I get notified once the control loads a new component, property, when using Load or LoadFile methods

// AddComponent event - Occurs when a new component is added.
procedure TForm1.ICalendar1AddComponent(ASender: TObject; NewComponent : IComponent);
begin
	with ICalendar1 do
	begin
		OutputDebugString( NewComponent );
	end
end;

// AddProperty event - Occurs when a new property is added.
procedure TForm1.ICalendar1AddProperty(ASender: TObject; NewPropery : IProperty);
begin
	with ICalendar1 do
	begin
			OutputDebugString( NewPropery );
	end
end;

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	FireEvents := True;
	Load('BEGIN:VCALENDAR\r\nVERSION:2.0\r\nEND:VCALENDAR');
end
7:
How can I add a property with parameters

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		with Components.Add('VEVENT').Properties do
		begin
			Add('SUMMARY','Company Holiday Party').Parameters.Add('LANGUAGE','en-US');
			Add('DATE','1/1/2001');
		end;
	end;
	OutputDebugString( Save() );
end
6:
How can I load iCalendar from a string

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	Load('BEGIN:VCALENDAR\r\nVERSION:2.0\r\nEND:VCALENDAR');
	OutputDebugString( Content.Components.Item[OleVariant(0)].Name );
end
5:
How can I add VEVENT objects

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		with Properties do
		begin
			Add('Version','2.0');
			Add('PRODID','-//hacksw/handcal//NONSGML v1.0//EN');
		end;
		with Components.Add('VEVENT').Properties do
		begin
			Add('DTSTART','1/1/2001');
			Add('DTEND','1/2/2001');
			Add('SUMMARY','First Party');
		end;
		with Components.Add('VEVENT').Properties do
		begin
			Add('DTSTART','1/4/2001');
			Add('DTEND','1/5/2001');
			Add('SUMMARY','Second Party');
		end;
	end;
	OutputDebugString( Save() );
end
4:
How can I save the control's content to iCalendar format, as a file
ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		with Properties do
		begin
			Add('Version','2.0');
			Add('PRODID','-//hacksw/handcal//NONSGML v1.0//EN');
		end;
		with Components.Add('VEVENT').Properties do
		begin
			Add('DTSTART','1/1/2001');
			Add('DTEND','1/2/2001');
			Add('SUMMARY','Bastille Day Party');
		end;
	end;
	SaveFile('c:/temp/test.ical');
end
3:
How can I load the iCalendar format from a file

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	LoadFile('c:/temp/test.ical');
	OutputDebugString( Content.Components.Item['VCALENDAR'].Properties.Item['PRODID'].Value );
end
2:
How do I export the control's content to iCalendar format

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR') do
	begin
		with Properties do
		begin
			Add('Version','2.0');
			Add('PRODID','-//hacksw/handcal//NONSGML v1.0//EN');
		end;
		with Components.Add('VEVENT').Properties do
		begin
			Add('DTSTART','1/1/2001');
			Add('DTEND','1/2/2001');
			Add('SUMMARY','Bastille Day Party');
		end;
	end;
	OutputDebugString( Save() );
end
1:
How can I generate a VCALENDAR object

ICalendar1 := (IUnknown(ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.ICalendar.1'))) as EXICALENDARLib_TLB.ICalendar);
with ICalendar1 do
begin
	with Content.Components.Add('VCALENDAR').Properties do
	begin
		Add('Version','2.0');
		Add('PRODID','-//hacksw/handcal//NONSGML v1.0//EN');
	end;
	OutputDebugString( Save() );
end