cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
dbutskhrikidze
New Member

Read from Excel file

Hello, 

I am trying to create following scenario, if user asks "how many days of vacation are left ?", chatbot will check excel file and return data for this particular user. Any idea or help ?

2 REPLIES 2
JenniferK
Advocate II
Advocate II

You'll need to call an action from your topic. You'll pass the user info and possibly the date range to the Power Automate flow you'll need to write. Your flow should return a number.

Expiscornovus
Super User
Super User

Hi @dbutskhrikidze,

 

Like @JenniferK already suggested, this should be possible via an action. Can you share more details about the format of your Excel file?

 

Below is an example of how you could interact with an Excel file.

 

1. Example Excel file with a formatted table which has an EmployeeMail column.

 

vacationdaysleft_excel.png

 

2. Example topic. Authentication is enable for the bot. Because of this you can use the bot.UserId in the mapping of the Action step.

 

vacationdaysleft_topic.png

 

3. A flow which receives the user id value and uses that to lookup the mail address. That mail address value is used to filter for the correct row in the Excel sheet.

 

With the expression below the number of days are returned in the VacationDaysLeft output variable.

first(outputs('List_rows_present_in_a_table')?['body/value'])?['VacationDaysLeft']

 

vacationdaysleft_flow.png

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Canadian Cloud 2022 768x460.png

Register for a free PVA chatbot creation workshop.

Learn how to respond rapidly to your customers and employees at scale, using intelligent conversational chatbots.

Super User 2 - 2022 Congratulations 768x460.png

Welcome Super Users

The Super User program for 2022- Season 2 has kicked off!

Top Solution Authors
Users online (5,358)