Use the ItemProperties collection for that, it can take a property name instead of an index value.
VBA, where oAppt == an open appointment item:
Dim Result As Variant
Dim propName As String
propName = "ConversationTopic"
Result = oAppt.ItemProperties.Item(propName).Value
Debug.Print Result
Ken Slovak
Slovak Technical Services, Inc.
From: outlook-dev@yahoogroups.com [mailto:outlook-dev@yahoogroups.com] On Behalf Of mr_delphi_developer
Sent: Wednesday, July 08, 2009 12:17 PM
To: outlook-dev@yahoogroups.com
Subject: Obtain property value by name
Need to access Appointment property by propertyname.
How to do that?
Let's say I want to write a function and pass a property name and then
return the value of the property:
{Delphi}
function getPropValue(
begin
Result := AppointmentItem. ?????
end;