Outlook Automation:MeetingItem

zimbazimba Member Posts: 11
edited 2004-06-14 in Navision Attain
Hi all , how are you ?

I am self training for outlook automations….
I try to use Outlook “MeetingItem” but I get error I cant find any help in MSDN


VAR:
OutlookApp Automation 'Microsoft Outlook 10.0 Object Library'.Application
OutlookMeeting Automation 'Microsoft Outlook 10.0 Object Library'.MeetingItem

CODE:
CLEAR(OutlookApp);
CLEAR(OutlookMeeting);

CREATE(OutlookApp);
//CREATE(OutlookMeeting);
OutlookMeeting:= OutlookApp.CreateItem(3);

              
OutlookMeeting.Subject:=’TEXT SAMPLE’;
OutlookMeeting.Body:= ’TEXT SAMPLE’;
OutlookMeeting.ReminderSet:= TRUE;
OutlookMeeting.Save;
OutlookMeeting.Display;
 CLEAR(OutlookApp);
CLEAR(OutlookMeeting);


I get error messsage :

"Invalid assigment.It is not possible to assing a_TaskItem to a MeetingItem"

Why ? Please Can you Help Me….

Comments

  • ajayjainajayjain Member Posts: 119
    You can download outlook integration module from download section.
    Ajay Jain
    UK
  • Dmitry_ChadaevDmitry_Chadaev Member Posts: 52
    Hi Zimba,

    Would that be ok for you?

    Variables:
    OutlookApp Automation 'Microsoft Outlook 11.0 Object Library'.Application
    OutlookMeeting Automation 'Microsoft Outlook 11.0 Object Library'.AppointmentItem

    CLEAR(OutlookApp); 
    CLEAR(OutlookMeeting); 
    
    CREATE(OutlookApp); 
    //CREATE(OutlookMeeting); 
    OutlookMeeting:= OutlookApp.CreateItem(1);  // Note that it is 1 here.
                  
    OutlookMeeting.Subject:='TEXT SAMPLE';
    OutlookMeeting.Body:= 'TEXT SAMPLE';
    OutlookMeeting.ReminderSet:= TRUE; 
    OutlookMeeting.Save; 
    OutlookMeeting.Display; 
     CLEAR(OutlookApp); 
    CLEAR(OutlookMeeting);
    

    It works at least :)
    Best regards,
    Dmitry
  • zimbazimba Member Posts: 11
    Thank you so much Dmitry Chadaev
Sign In or Register to comment.