Skip to content

Commit bb3df98

Browse files
authored
Merge pull request #899 from ProVal-Tech/origin-feature-invoke-oem-update-with-prompt
Approved
2 parents 7c2f669 + 11e7b5b commit bb3df98

6 files changed

Lines changed: 398 additions & 24 deletions

File tree

‎docs/dattormm/components/invoke-oem-update-with-prompt.md‎

Lines changed: 111 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ tags: ['windows', 'dell', 'lenovo', 'hp', 'notifications', 'drivers', 'bios', 'f
99
draft: false
1010
unlisted: false
1111
last_update:
12-
date: 2026-09-14
12+
date: 2026-09-24
1313
---
1414

1515
## Overview
@@ -18,6 +18,8 @@ This is a Datto implementation of the agnostic [Invoke-OEMUpdateWithPrompt](/doc
1818

1919
The script prompts logged-in users before BIOS and firmware updates, allows postponement for a configured number of cycles, and then enforces the update. It is designed for a single deployment from Datto RMM, then continues through scheduled task re-runs on the endpoint.
2020

21+
While the update installs, an optional on-screen notification keeps the user informed — either repeated at an interval or kept on screen for the whole update. Prompts can also carry your own branding through the `Icon` and `HeaderImage` variables, which accept a web URL, local path, or UNC share and are staged locally by the script before use.
22+
2123
## Dependencies
2224

2325
- [Invoke-OEMUpdateWithPrompt](/docs/52c50165-38d5-4793-b751-97260ab31f72)
@@ -85,8 +87,60 @@ Run with user parameter `SkipWeekends = True`.
8587

8688
Expected output:
8789

88-
- There will be no popup get generated on the users machine during weekend.
89-
- Will is useful as user will not miss any popup during weekends.
90+
- No popup is generated on the user's machine during weekends.
91+
- This is useful because the user will not miss any popup during weekends.
92+
93+
### Scenario 7: ShowProgressPrompt (Interval Mode)
94+
95+
Run with user parameters `ShowProgressPrompt = True`, `ProgressPromptInterval = 10`, `ProgressPromptTimeout = 300`.
96+
97+
Expected output:
98+
99+
- While the update installs, a notice appears on the user's desktop for 5 minutes every 10 minutes.
100+
- The notice closes itself and repeats at the next interval until the update finishes.
101+
- The notice only appears while a user is logged in and the machine is unlocked; on a locked or logged-off machine the interval simply passes without a notification.
102+
103+
### Scenario 8: KeepProgressPromptVisible (Stay Mode)
104+
105+
Run with user parameter `KeepProgressPromptVisible = True`.
106+
107+
Expected output:
108+
109+
- The notice appears as soon as the update starts and stays on the desktop for the whole update.
110+
- Clicking its OK button only hides it until the next check brings it back.
111+
- `ShowProgressPrompt` is not needed, because `KeepProgressPromptVisible` implies it. When both are set, stay mode wins and the interval settings are ignored.
112+
113+
### Scenario 9: PromptDisplayRetryCount
114+
115+
Run with user parameters `PromptDisplayRetryCount = 2`, `PromptDisplayRetryDelay = 60`.
116+
117+
Expected output:
118+
119+
- A prompt that fails to display is retried up to two extra times, a minute apart.
120+
- A failed attempt does not consume one of the user's postponements; a prompt the user simply ignored is handled as missed rather than retried.
121+
- If every attempt fails, the script cleans up its tasks and reschedules itself for the next interval, preserving all prompt state.
122+
123+
### Scenario 10: Icon and HeaderImage
124+
125+
Run with user parameters `Icon = https://example.com/icon.png` and `HeaderImage = \\fileserver\share\header.png`.
126+
127+
Expected output:
128+
129+
- Both values are passed through unchanged; the script stages verified local copies in its prompt working directory and runs every prompt with those local paths.
130+
- The logged-in user never needs access to the original sources, and a failed refresh keeps the last good copy.
131+
132+
## While the Update Runs
133+
134+
Firmware installs can take a long time with nothing visible on screen. Two optional modes keep the user informed; both are off by default:
135+
136+
- **Interval mode (`ShowProgressPrompt = True`):** every `ProgressPromptInterval` minutes a notice appears for `ProgressPromptTimeout` seconds, closes itself, and repeats until the update finishes. Set `ProgressPromptInterval` to `0` to turn the interval notices off.
137+
- **Stay mode (`KeepProgressPromptVisible = True`):** the notice appears as soon as the update starts and stays on screen until the update finishes. Clicking its OK button only hides it until the next check brings it back — intentional, so nobody power-cycles a machine they think is stuck.
138+
139+
Stay mode wins when both are configured, and `KeepProgressPromptVisible` implies `ShowProgressPrompt`, so the two never need to be enabled together. The notice only appears while a user is logged in and the machine is unlocked, and it is closed and cleaned up as soon as the update finishes. A reboot triggered by the update closes it too, and the leftover task is removed on the next run.
140+
141+
## Prompt Display Retry
142+
143+
A prompt that fails to display — the scheduled task never reached the prompt application, or its output matched no known button caption — is retried up to `PromptDisplayRetryCount` extra times, `PromptDisplayRetryDelay` seconds apart. A failed attempt never consumes one of the user's postponements, and a prompt the user simply ignored is still handled as a missed prompt rather than retried. When every attempt fails, the script cleans up its tasks and reschedules itself for the next interval, preserving all prompt state so the cycle resumes where it left off instead of starting over.
90144

91145
## Customize the Prompt Text
92146

@@ -98,7 +152,7 @@ Titles and messages both have Datto variables, so no change to the component is
98152

99153
These are the messages users see when the text parameters are left empty. Wording follows the display language of the logged-in user.
100154

101-
Names such as `PromptsLeft` and `ScheduledUpdateTime` are replaced with live values before the prompt appears. `\n` produces a line break.
155+
Names such as `PromptsLeft`, `ScheduledUpdateTime`, and `UpdateElapsedMinutes` are replaced with live values before the prompt appears. `\n` produces a line break.
102156

103157
#### Titles
104158

@@ -107,6 +161,7 @@ Names such as `PromptsLeft` and `ScheduledUpdateTime` are replaced with live val
107161
| `Title` | BIOS / Firmware Update | BIOS / Firmware Update |
108162
| `ReminderPromptTitle` | BIOS / Firmware Update - Starting Soon | BIOS / Firmware Update - Start binnenkort |
109163
| `CompletionPromptTitle` | BIOS / Firmware Update - Complete | BIOS / Firmware Update - Voltooid |
164+
| `ProgressPromptTitle` | BIOS / Firmware Update - In Progress | BIOS / Firmware Update - Bezig |
110165

111166
#### Messages
112167

@@ -166,15 +221,30 @@ The BIOS/Firmware update has completed successfully. A reboot was not required t
166221
De BIOS/Firmware-update is succesvol voltooid. Er was geen herstart nodig om de updates van vandaag te installeren.\n\nUw computer is klaar voor gebruik.\n\nKlik op OK om te bevestigen.
167222
```
168223

224+
**In-progress notice** — `ProgressPromptMessage`
225+
226+
*English*
227+
228+
```text
229+
A BIOS/Firmware update is currently being installed on your computer. The installation is still running in the background.\n\nYour computer may restart automatically once the update has finished, so please save your work and leave the computer switched on.\n\nNo action is needed from you.
230+
```
231+
232+
*Dutch*
233+
234+
```text
235+
Er wordt momenteel een BIOS/Firmware-update op uw computer uitgevoerd. De installatie is nog bezig op de achtergrond.\n\nUw computer kan automatisch opnieuw opstarten zodra de update is voltooid. Sla uw werk op en laat de computer ingeschakeld.\n\nU hoeft verder niets te doen.
236+
```
237+
169238
#### Extra line on laptops
170239

171-
On laptops, notebooks, and tablets the following line is added before the closing sentence of these three prompts. Desktops do not see it.
240+
On laptops, notebooks, and tablets the following line is added before the closing sentence of these four prompts. Desktops do not see it.
172241

173242
| Prompt | English | Dutch |
174243
| --- | --- | --- |
175244
| Regular prompt | Please connect your laptop to power before the update begins. Do not run the update on battery. | Sluit uw laptop aan op de netstroom voordat de update begint. Voer de update niet uit op accustroom. |
176245
| Final prompt | Please make sure your laptop is connected to power at the time you select. | Zorg ervoor dat uw laptop op het gekozen tijdstip op de netstroom is aangesloten. |
177246
| Reminder prompt | Please make sure your laptop is connected to power now. | Zorg ervoor dat uw laptop nu op de netstroom is aangesloten. |
247+
| In-progress notice | Please keep your laptop connected to power until the update has finished. | Laat uw laptop aangesloten op de netstroom totdat de update is voltooid. |
178248

179249
### Insert live values
180250

@@ -191,6 +261,9 @@ Type any of these names into your message as a plain word. The real value is fil
191261
| `DelayAfterFinalSeconds` / `DelayAfterFinalMinutes` | Grace period after the final prompt |
192262
| `ScheduledUpdateTime` | Time the user picked (reminder prompt only) |
193263
| `MinutesUntilUpdate` | Minutes until the update starts (reminder prompt only) |
264+
| `ProgressIntervalMinutes` | Minutes between in-progress notices |
265+
| `ProgressTimeoutSeconds` / `ProgressTimeoutMinutes` | How long each in-progress notice stays on screen |
266+
| `UpdateElapsedMinutes` | Minutes the update has been running (in-progress notice only) |
194267
| `ComputerName` | Machine name |
195268
| `UserName` | Logged-in username |
196269

@@ -202,10 +275,17 @@ Use `\n` for a line break.
202275
A firmware update is pending on ComputerName. You have PromptsLeft reminder(s) left, one every PromptIntervalHours hour(s).\n\nSave your work and click Update Now.
203276
```
204277

278+
**Example with the in-progress notice:**
279+
280+
```text
281+
IT is updating the firmware on ComputerName. This has been running for UpdateElapsedMinutes minute(s).\n\nPlease leave the machine switched on.
282+
```
283+
205284
### Things to know
206285

207286
* These names are reserved words. If a message needs the literal word `ComputerName`, reword it.
208287
* Button labels always follow the user's language and cannot be changed.
288+
* The in-progress notice always carries an OK button. In stay mode, clicking it only hides the notice until the next check brings it back.
209289
* Custom text is not translated and does not receive the automatic connect-to-power line shown on laptops. Include that wording yourself if your fleet has laptops.
210290

211291
### Sample Prompts - English
@@ -227,6 +307,10 @@ A firmware update is pending on ComputerName. You have PromptsLeft reminder(s) l
227307

228308
![Image7](../../../static/img/docs/52c50165-38d5-4793-b751-97260ab31f72/image7.webp)
229309

310+
### Update In Progress Notification - English
311+
312+
![Image13](../../../static/img/docs/52c50165-38d5-4793-b751-97260ab31f72/image13.webp)
313+
230314
### Sample Prompts - Dutch
231315

232316
![Image4](../../../static/img/docs/52c50165-38d5-4793-b751-97260ab31f72/image4.webp)
@@ -237,6 +321,10 @@ A firmware update is pending on ComputerName. You have PromptsLeft reminder(s) l
237321

238322
![Image8](../../../static/img/docs/52c50165-38d5-4793-b751-97260ab31f72/image8.webp)
239323

324+
#### Update In Progress Notification - Dutch
325+
326+
![Image14](../../../static/img/docs/52c50165-38d5-4793-b751-97260ab31f72/image14.webp)
327+
240328
## Datto Variables
241329

242330
| Variable Name | Default | Type | Description |
@@ -245,18 +333,24 @@ A firmware update is pending on ComputerName. You have PromptsLeft reminder(s) l
245333
| `IntervalMinutes` | `240` | String | Minutes between each prompt. After postpone or miss, a SYSTEM scheduled task re-runs the script at this interval. |
246334
| `RegularPromptTimeout` | `600` | String | Seconds before a regular prompt auto-closes and counts as missed. |
247335
| `FinalPromptTimeout` | `900` | String | Seconds before the final prompt times out and the upgrade is forced. |
248-
| `DelayAfterFinalPrompt` | `600` | String | Seconds to wait before forcing the upgrade after the final prompt times out or user picks a time < 15 min away. |
336+
| `DelayAfterFinalPrompt` | `600` | String | Seconds to wait before forcing the upgrade after the final prompt times out without a user selection. |
337+
| `PromptDisplayRetryCount` | `1` | String | Extra attempts to display a prompt when it fails to appear or returns unreadable output. `0` gives each prompt a single attempt. A failed attempt never consumes a postponement. |
338+
| `PromptDisplayRetryDelay` | `30` | String | Seconds to wait between prompt display attempts, giving a transient condition a chance to clear. |
249339
| `SkipWeekends` | `False` | Boolean | Prevents prompts on Saturdays and Sundays. |
250340
| `IfNotLoggedIn` | `False` | Boolean | Runs the upgrade immediately without prompting if no user is logged in. |
251341
| `Force` | `False` | Boolean | Clears all scheduled tasks and stored state, restarting the prompt cycle from 0. |
252342
| `UsePsWindowsUpdate` | `False` | Boolean | Uses the PSWindowsUpdate module instead of OEM-specific scripts (Dell/HP/Lenovo). |
253343
| `HandleBitLocker` | `False` | Boolean | Suspends BitLocker protection on the OS drive for one reboot cycle before OEM updates run. If no reboot is required after the update, BitLocker protection is automatically resumed. |
254344
| `SuppressPopupTimeWindows` | | String | Time window (24-hour format, e.g., `1800-0900`) during which prompts are suppressed. |
255-
| `Icon` | | String | URL or local file path for the icon displayed in the prompt dialog (e.g., `https://example.com/icon.png` or `C:\Icons\icon.png`). |
256-
| `HeaderImage` | | String | URL or local file path for the header image displayed at the top of the prompt dialog (e.g., `https://example.com/header.png` or `C:\Images\header.png`). |
345+
| `Icon` | | String | URL, local path, or UNC share path for the icon displayed in the prompt dialog (e.g., `https://example.com/icon.png` or `\\server\share\icon.png`). Passed through unchanged; the script stages a verified local copy and runs every prompt with that path. |
346+
| `HeaderImage` | | String | URL, local path, or UNC share path for the header image displayed at the top of the prompt dialog. Passed through unchanged and staged locally in the same way as `Icon`. |
257347
| `OEMScriptParametersOverride` | | String | Custom parameter string passed to the vendor update script, replacing the default parameter set for the detected manufacturer (e.g., `'/applyUpdates -updateType=bios -silent'` for Dell DCU or `-Category 'Drivers','Tools' -AllowReboot` for PSWindowsUpdate). |
258348
| `MaxMissedPromptsBeforeForce` | `0` | String | Consecutive missed prompts (locked screen, or nobody logged in) before the update is forced without prompting. `0` disables forcing. |
259349
| `UpdateDuringSuppress` | `False` | Boolean | Allows a forced or unattended update to run inside a suppress window or on a weekend. Prompts are still never shown during those times. |
350+
| `ShowProgressPrompt` | `False` | Boolean | Shows a notice on the user's desktop while the update installs, repeating every `ProgressPromptInterval` minutes for `ProgressPromptTimeout` seconds. |
351+
| `ProgressPromptInterval` | `10` | String | Minutes between in-progress notices. `0` turns the interval notices off. Ignored when `KeepProgressPromptVisible` is enabled. |
352+
| `ProgressPromptTimeout` | `300` | String | Seconds each in-progress notice stays on screen before it closes on its own. Ignored when `KeepProgressPromptVisible` is enabled. |
353+
| `KeepProgressPromptVisible` | `False` | Boolean | Keeps the in-progress notice on the desktop for the whole update and brings it back if dismissed. Overrides the interval settings and implies `ShowProgressPrompt`. |
260354
| `Theme` | `Dark` | Selection | Prompt window theme. `Dark` or `Light`. |
261355
| `Title` | | String | Title for the regular and final prompts. Blank uses the built-in title. |
262356
| `RegularPromptMessage` | | String | Body of the postponable prompts. Blank uses the built-in wording. |
@@ -265,6 +359,8 @@ A firmware update is pending on ComputerName. You have PromptsLeft reminder(s) l
265359
| `ReminderPromptMessage` | | String | Body of the 10-minute warning. Blank uses the built-in wording. |
266360
| `CompletionPromptTitle` | | String | Title of the completion confirmation. Blank uses the built-in title. |
267361
| `CompletionPromptMessage` | | String | Body of the completion confirmation. Blank uses the built-in wording. |
362+
| `ProgressPromptTitle` | | String | Title of the in-progress notice shown while the update installs. Blank uses the built-in title. |
363+
| `ProgressPromptMessage` | | String | Body of the in-progress notice. Blank uses the built-in wording. |
268364

269365
## Output
270366

@@ -276,6 +372,13 @@ Activity Log
276372

277373
## Changelog
278374

375+
### 2026-09-24
376+
377+
- Added the optional **update in progress notification**: new `ShowProgressPrompt`, `ProgressPromptInterval`, `ProgressPromptTimeout`, `KeepProgressPromptVisible`, `ProgressPromptTitle`, and `ProgressPromptMessage` variables keep the user informed while the update installs. Stay mode keeps the notice on screen for the whole update and wins when both modes are configured.
378+
- Added `PromptDisplayRetryCount` and `PromptDisplayRetryDelay`. A prompt that fails to display is retried and never consumes a postponement; when every attempt fails, the script reschedules itself for the next interval with the stored prompt state untouched.
379+
- `Icon` and `HeaderImage` now accept a web URL, local path, or UNC share and are passed through unchanged; the script stages verified local copies in its prompt working directory, so the component no longer pre-downloads image files.
380+
- Picks up the agnostic script improvements for prompt task start detection and reschedule-on-failure. See the [agnostic script changelog](/docs/52c50165-38d5-4793-b751-97260ab31f72#changelog).
381+
279382
### 2026-09-14
280383

281384
- Every prompt title and message is now a Datto variable, so wording can be changed per job without editing the component.

0 commit comments

Comments
 (0)