//On app start retrieve user emails and plans
Set(LoadEmails, true);
Concurrent(
Set(MyDomainName,Last(Split(Office365Users.MyProfile().Mail,"@")).Result),
Set(LastSynced, Now()),
Set(EmailFolderName, "Inbox"),
//Create new option for a plan. This is the first item in the MyPlanSelection
ClearCollect(MyPlansGalleryItems, {id: "NotAPlan2", title: "Create New Plan"}),
//Create new option for a bucket. This is the first item in the MyBucketSelection
ClearCollect(MyBucketsGalleryItems, {id: "NotABucket2", name: "Create New Bucket", planId: "NotAPlan2"}),
ClearCollect(DLAddresses,
ForAll(Filter(Split(Trim(SettingsDLsInUse.Text), ","), !IsBlank(Result)), {
Email: Result} ))
);
Concurrent(
ClearCollect(Emails, Office365.GetEmails({folderPath:EmailFolderName, fetchOnlyUnread: false, searchQuery: "(To:" & First(DLAddresses).Email & " OR CC:" & Dropdown1.SelectedText.Email & ")", top: 25})),
Collect(MyPlansGalleryItems, Planner.ListMyPlansV2().value)
);
Set(SelectedMail, First(Emails));
Set(LoadEmails, false)
WarrenBelz
637
Most Valuable Professional
stampcoin
570
Super User 2025 Season 2
Power Apps 1919
473