web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Getting Calendar Event ID
Power Apps
Answered

Getting Calendar Event ID

(0) ShareShare
ReportReport
Posted on by 3,187

I have been through 4 or 5 'answered' questions on this topic and none of them work. They all return a giant string that 'cannot be converted to a number'. 

 

Here is my code for my on select to submit a form as well as add the calendar even:

Office365Outlook.V4CalendarPostItem(
 "** this is where my giant string for table id goes. this part works fine **",
 DataCardValue2.Text & " follow up",
 Text(
 DateTimeValue(
 DateValue1.SelectedDate & " " & TimeValue(
 Concatenate(
 HourValue1.Selected.Value,
 ":",
 MinuteValue1.Selected.Value
 )
 )
 )
 ),
 Text(
 DateTimeValue(
 DateValue2.SelectedDate & " " & TimeValue(
 Concatenate(
 HourValue2.Selected.Value,
 ":",
 MinuteValue2.Selected.Value
 )
 )
 )
 ),
 "(UTC-06:00) Central Time (US & Canada)"
);
Set(
 varCalEntryID,
 Last(
 Sort(
 Office365Outlook.V4CalendarGetItems(
 LookUp(
 Office365Outlook.CalendarGetTablesV2().value,
 name = "CRM"
 ).id
 ).value,
 createdDateTime
 )
 ).id
);
SubmitForm(Form1);
ResetForm(Form1)

 

I am trying to get the set variable to be set to the id of the event that was created and not the value of the calendar. I have tried many ways to do this with no luck at all. This does submit the form and it also submits the item to outlook. What I am trying to do is sneak the event id into a card on the form to be saved as CalendarEventID so that it can be used to edit/delete the calendar even from the app at some point in the future. (similar to Patch(List,Defaults(List),.....) to get the ID of the item that was just patched. 

 

TYIA!

Categories:
  • mmollet Profile Picture
    3,187 on at

    Any ideas where I can repost this question or go to try and find a solution? Any ideas would be appreciated!

  • Verified answer
    mmollet Profile Picture
    3,187 on at

    Ended up deleting the column in SP, the Card I was using in the form, recreateing the SP column, readding the card and then pasting the same code back in as it was needed. This fixed everything somehow and it is now adding, editing, and deleting the even as expected. Now to make a flow that removes the SP item when the even is removed from outlook. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 402 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 328

#3
WarrenBelz Profile Picture

WarrenBelz 296 Most Valuable Professional

Last 30 days Overall leaderboard