View Single Post
  #2  
Old July 8th 09, 06:44 PM posted to microsoft.public.outlook.program_vba
Michael Bauer [MVP - Outlook]
external usenet poster
 
Posts: 1,885
Default Obtain property value by name



You need to handle every supported case, e.g.:

Select Case Propname
Case "Start": getPropValue=Item.Start
Case "Subject": getPropValue=Item.Subject
End Select

--
Best regards
Michael Bauer - MVP Outlook

: Outlook Categories? Category Manager Is Your Tool
: VBOffice Reporter for Data Analysis & Reporting
: http://www.vboffice.net/product.html?pub=6&lang=en


Am Wed, 8 Jul 2009 08:25:21 -0700 (PDT) schrieb MB34:

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:
{Delphi}
function getPropValue(Propname: String): Variant;
begin
Result := AppointmentItem. ?????
end;

Ads