Checklist
Steps to Reproduce
$sequenceNumber = Get-Random -Minimum ([uint32]::MaxValue / 2) -Maximum ([uint32]::MaxValue - 1);
$uniqueId = [guid]::NewGuid().ToString();
Write-Host "Unique Identifier: $uniqueId";
Write-Host "Sequence Number : $sequenceNumber";
$labels = New-BTText -Style Base -Text 'unbind_title'
$values = New-BTText -Style BaseSubtle -Text 'unbind_subtitle'
$progress = New-BTProgressBar -Status "bind_status" -Value "bind_value" -ValueDisplay "bind_value_display"
$col1 = New-BTColumn -Children $labels -Weight 4;
$col2 = New-BTColumn -Children $values -Weight 6;
$binding = New-BTBinding -Column $col1, $col2 -Children $progress;
$visual = New-BTVisual -BindingGeneric $binding;
$content = New-BTContent -Visual $visual;
$Content.GetContent()
$data0 = @{
unbind_title = 'Title 1';
bind_example = 'Sub title 1';
bind_status = 'Status initial'
bind_value = 0.5;
bind_value_display = 'Progress start';
};
Submit-BTNotification -Content $content -UniqueIdentifier $uniqueId -DataBinding $data0 -SequenceNumber $sequenceNumber;
Start-Sleep -Seconds 10;
$data = @{
unbind_title = 'Title new';
unbind_subtitle = 'Subtitle new';
bind_status = 'Status final'
bind_value = 0.7;
bind_value_display = 'Progress end';
};
Update-BTNotification -UniqueIdentifier $uniqueId -DataBinding $data -SequenceNumber $sequenceNumber;
Expected Behavior
There are two possible expected behaviors:
- If the databinding works with all text, then the text must be replaced.
- It the databinding works only with Progress Bar, then the text must not be shown as placeholder.
The error occurs when DataBindig is set with something. Not necessarily an existent placeholder.
Actual Behavior
When you run the code you can notice:
- "unbind_title" and "unbind_subtitle" are converted to placeholders and these are not replaced by the text with databinding.
- The placeholders are replaced only for progress bar.
Experience with Toast
Beginner
Environment data: PowerShell
Name Value
---- -----
PSVersion 5.1.26100.7920
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.26100.7920
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
Environment data: OS
Replace with the output of: Get-ComputerInfo | fl OsName, OsVersion, OsArchitecture
Environment data: BurntToast
ModuleType Version Name
---------- ------- ----
Script 1.1.0 BurntToast
Consent to Attribution
Checklist
Steps to Reproduce
Expected Behavior
There are two possible expected behaviors:
The error occurs when DataBindig is set with something. Not necessarily an existent placeholder.
Actual Behavior
When you run the code you can notice:
Experience with Toast
Beginner
Environment data: PowerShell
Environment data: OS
Environment data: BurntToast
Consent to Attribution