Business Professionals
Power BI | Power Pivot | Power Query | DAX
Cloud Flows | RPA | AI Builder | Copilot
60+ Formulas | Data Stories | Advanced Reporting & Modeling
VB Programming | Report Automation |
MS-Office Automation
Techno-Business Professionals
Power BI | Power Query | Advanced DAX | SQL - Query &
Programming
Microsoft Fabric | Power BI | Power Query | Advanced DAX |
SQL - Query & Programming
Power BI | Power Apps | Power Automate | Copilot Studio | Power Pages | Dataverse
Microsoft Power Apps | Microsoft Power Automate
Power BI | Adv. DAX | SQL (Query & Programming) |
VBA | Python | Web Scrapping | API Integration
Power BI | Power Apps | Power Automate |
SQL (Query & Programming)
Power BI | Adv. DAX | Power Apps | Power Automate |
SQL (Query & Programming) | VBA | Python | Web Scrapping | API Integration
Power Apps | Power Automate | SQL | VBA | Python |
Web Scraping | RPA | API Integration
Technology Professionals
Power BI | DAX | SQL | ETL with SSIS | SSAS | VBA | Python
Power BI | SQL | Azure Data Lake | Synapse Analytics |
Data Factory | Databricks | Power Apps | Power Automate |
Azure Analysis Services
Microsoft Fabric | Power BI | SQL | Lakehouse |
Data Factory (Pipelines) | Dataflows Gen2 | KQL | Delta Tables | Power Apps | Power Automate
Power BI | Power Apps | Power Automate | SQL | VBA | Python | API Integration
Power BI | Advanced DAX | Databricks | SQL | Lakehouse Architecture
Business Professionals
Power BI | Power Pivot | Power Query | DAX
Cloud Flows | RPA | AI Builder | Copilot
60+ Formulas | Data Stories | Advanced Reporting & Modeling
VB Programming | Report Automation |
MS-Office Automation
Techno-Business Professionals
Power BI | Power Query | Advanced DAX | SQL - Query &
Programming
Microsoft Fabric | Power BI | Power Query | Advanced DAX |
SQL - Query & Programming
Power BI | Power Apps | Power Automate | Copilot Studio | Power Pages | Dataverse
Microsoft Power Apps | Microsoft Power Automate
Power BI | Adv. DAX | SQL (Query & Programming) |
VBA | Web Scrapping | API Integration
Power BI | Power Apps | Power Automate |
SQL (Query & Programming)
Power BI | Adv. DAX | Power Apps | Power Automate |
SQL (Query & Programming) | VBA | Web Scrapping | API Integration
Power Apps | Power Automate | SQL | VBA |
Web Scraping | RPA | API Integration
Technology Professionals
Power BI | DAX | SQL | ETL with SSIS | SSAS | VBA
Power BI | SQL | Azure Data Lake | Synapse Analytics |
Data Factory | Azure Analysis Services
Microsoft Fabric | Power BI | SQL | Lakehouse |
Data Factory (Pipelines) | Dataflows Gen2 | KQL | Delta Tables
Power BI | Power Apps | Power Automate | SQL | VBA | API Integration
Power BI | Advanced DAX | Databricks | SQL | Lakehouse Architecture
LEARN THIS HANDS ON
Power Apps & Power Automate
Romanian accounting teams are now living with the same headache: invoices must be sent through e-Factura within 5 working days, and nobody wants to be the one who missed the deadline and triggered a fine. Email reminders and Excel lists get out of sync fast. This article shows how to build a robust e-Factura deadline tracker in Microsoft Teams using Power Automate, with the exact rules accountants care about.
We’ll use a realistic setup: invoices logged in a SharePoint list, a Power Automate flow to calculate the 5 working days rule, and Teams notifications that hit the right channels and people before you get anywhere near the 10,000 lei fine zone.
You’re in a mid-sized company. The process looks like this:
Symptoms:
We’ll build:
We’ll assume you already have a site for Finance/Accounting in SharePoint Online.
Create a new list called e-Factura Invoices with at least these columns:
Pending, Sent, Cancelled.Why SharePoint list?
We will not use a SharePoint Calculated column for working days logic. Instead, we’ll push all business logic into Power Automate, where we can control it and adjust for future rules.
The legal rule is 5 working days. The system needs to:
Out of the box, Power Automate has:
addDays() – adds calendar days, no weekend awareness.dayOfWeek() – returns 0–6 (Sunday–Saturday).There is no built-in function for working days or public holidays in cloud flows as of October 2026. So we:
For most teams, “skip weekends, ignore holidays” is already a big step forward compared to manual Excel tracking. You can refine later.
We’ll create a When an item is created or modified flow on the SharePoint list.
e-Factura Invoices.We’ll use one flow for both creation and updates, so any change to InvoiceDate or Status will recalc deadlines.
Add a Condition after the trigger:
Status is equal to Pending.If not Pending, we skip deadline calculation to avoid confusing data on cancelled or already sent invoices.
We want: DeadlineWorkingDays = InvoiceDate + 5 working days.
Approach:
Steps in the flow:
Initialize variable varCurrentDate (String)
formatDateTime(triggerOutputs()?['body/InvoiceDate'], 'yyyy-MM-dd')
Initialize variable varWorkingDaysCount (Integer)
0Do until loop
variables('varWorkingDaysCount') is equal to 5.Inside the Do until:
Compose – DayOfWeek
dayOfWeek(variables('varCurrentDate'))
Condition – Is working day?
outputs('Compose_-_DayOfWeek') is greater than or equal to 1(1 = Monday, 5 = Friday in Power Automate.)
varWorkingDaysCount by 1.Increment date: set varCurrentDate to next day
setVariable('varCurrentDate', formatDateTime(addDays(variables('varCurrentDate'), 1), 'yyyy-MM-dd'))
When the loop exits, varCurrentDate will be the day after the 5th working day, because we increment at the end of each iteration. To use the actual deadline date, we need to subtract one day.
Add a Compose – DeadlineDate action:
formatDateTime(addDays(variables('varCurrentDate'), -1), 'yyyy-MM-dd')
We’ll store a numeric difference between today and the deadline.
Add a Compose – DaysToDeadline:
sub(
int(formatDateTime(outputs('Compose_-_DeadlineDate'), 'yyyyMMdd')),
int(formatDateTime(utcNow(), 'yyyyMMdd'))
)
This is a simple calendar day difference, not working days. For alerting purposes (e.g., “deadline is in 1–2 days”), calendar days are usually fine. If you need working-day difference, you can reuse the same loop pattern.
Note: We’re using yyyyMMdd as an integer to avoid dealing with time zones and partial days. This works accurately as long as you treat all dates as local calendar days.
Finally, use Update item (SharePoint):
ID from trigger.Title from trigger (do not change).InvoiceDate from trigger.outputs('Compose_-_DeadlineDate').outputs('Compose_-_DaysToDeadline').Status from trigger.Make sure the Update item action includes all required columns, otherwise SharePoint will blank fields that are not included.
At this point, every pending invoice gets a computed working-days deadline and a day difference whenever it’s created or edited.
Now we want a separate flow that sends a daily summary into a Teams channel.
Add Get items (SharePoint):
e-Factura Invoices.Status eq 'Pending' and DaysToDeadline le 2
This picks all pending invoices where the deadline is within 2 calendar days (including overdue ones where DaysToDeadline is negative).
If your list grows large, consider:
Status and DaysToDeadline to keep queries fast.Add a Compose – MessageBody with an HTML table or markdown-like text. For example, using Create HTML table then a compose.
value of Get items.concat(
'<b>e-Factura deadlines (next 2 days)</b><br/>',
'Generated on: ', formatDateTime(utcNow(), 'yyyy-MM-dd HH:mm'), '<br/><br/>',
outputs('Create_HTML_table')
)
Teams supports HTML in Post message in a chat or channel when you set Message type appropriately.
Add Post message in a chat or channel (Microsoft Teams):
outputs('Compose_-_MessageBody').Optional: if Get items returns zero rows, you can add a condition and send a short “No pending deadlines within 2 days” message instead.
Channel messages are great for visibility, but you may also want direct pings for the person responsible.
The Post message in a chat or channel action does not support dynamic @mentions directly. To mention users dynamically, use Post adaptive card and wait for a response or Post adaptive card in a chat or channel with a card payload that includes mentions.
One practical pattern:
Create another Scheduled cloud flow at, say, 09:00.
Status eq 'Pending' and DaysToDeadline eq 1
value from Get items.Inside the loop:
Owner is not empty.Owner Email from the item.concat(
'Invoice ', items('Apply_to_each')?['Title'],
' for ', items('Apply_to_each')?['CustomerName'],
' (', string(items('Apply_to_each')?['Amount']), ' lei) ',
'must be sent to e-Factura by ',
formatDateTime(items('Apply_to_each')?['DeadlineWorkingDays'], 'yyyy-MM-dd'),
'.'
)
This uses the Teams chat action to open a direct chat between the Flow bot and the owner, which is supported in current Microsoft Teams connectors.
Now that the flows are running, make sure accountants actually see and use the tracker.
Practical steps:
Status = PendingDeadlineWorkingDays is in the next 7 days.Status to Sent and fill eFacturaSentDate as soon as they submit to e-Factura.This gives:
If your team wants to be strict about working days including public holidays, you need a holiday calendar.
Pattern that works well:
Date (Date only).IsWorkingDay (Yes/No).Populate it with at least the current and next year’s dates. Mark weekends and legal public holidays as IsWorkingDay = No.
In the deadline calculation flow:
Use Get items (SharePoint) on WorkingCalendar with filter:
Date eq 'variables(''varCurrentDate'')'
Check IsWorkingDay from that item instead of using dayOfWeek().
This adds one more dependency but keeps your working-day logic aligned with the legal calendar, which matters when fines are on the table.
The 5 working days, fines up to 10,000 lei pressure is not going away. A simple Power Automate + Teams setup that calculates working-day deadlines and pushes daily alerts takes that rule out of people’s heads and puts it into a repeatable system. Start with weekends-only logic, wire it into your e-Factura channel, and iterate toward a full working calendar once the team is comfortable.
This article reflects how Romanian accounting teams are codifying e-Factura working-day rules into Power Automate and Teams workflows to reduce manual tracking risk in environments where deadline compliance is critical.
Professionals who want to apply these patterns to their own data can explore Excelgoodies' Power Automate Course programme - taught live by instructors, with certification awarded once a real project is running at work.
Insights compiled through ongoing industry research and discussions within the Excelgoodies Analytics Community.
Power Automate
New
Next Batches Now Live
Power BI
SQL
Power Apps
Power Automate
Microsoft Fabrics
Azure Data Engineering