Table of Contents

Getting started with TMS FNC Cloud Microsoft Outlook Calendar

Prerequisites

  • TMS FNC Core installed and the runtime package added to the project.
  • TMS FNC Cloud Pack installed.
  • An app registered in the Microsoft Entra admin center with a client ID, client secret, and a registered redirect URI, with Calendar permissions granted.

Add the component

  1. Drop TTMSFNCCloudMicrosoftOutlookCalendar onto a form (or create it in code).
  2. Set the app credentials on Authentication (client ID, secret, redirect URI).
  3. Call Connect to authenticate, then call calendar operations from OnConnected.

Minimal example

Set the credentials, connect, and list the account's calendars once connected:

procedure TForm1.FormCreate(Sender: TObject);
begin
  // Credentials from your app registration (https://portal.azure.com).
  TMSFNCCloudMicrosoftOutlookCalendar1.Authentication.ClientID := 'your-client-id';
  TMSFNCCloudMicrosoftOutlookCalendar1.Authentication.Secret := 'your-client-secret';
  // Must match a redirect URI registered on the app.
  TMSFNCCloudMicrosoftOutlookCalendar1.Authentication.CallBackURL := 'http://127.0.0.1:8000';

  TMSFNCCloudMicrosoftOutlookCalendar1.OnConnected := OutlookCalendarConnected;
  // Opens the Microsoft consent page in the browser and exchanges the code for tokens.
  TMSFNCCloudMicrosoftOutlookCalendar1.Connect;
end;

procedure TForm1.OutlookCalendarConnected(Sender: TObject);
begin
  TMSFNCCloudMicrosoftOutlookCalendar1.GetCalendars;
end;

Next steps

  • Authentication — credentials, the OAuth flow, and persisting tokens
  • Calendars — listing, creating, renaming and deleting calendars, including shared calendars
  • Events — retrieving, creating, updating and deleting calendar events
  • API reference — full class reference