If I go and change the product value to different, it is not working. I need to stop and start dashboad. Is there a solution to this?
$Schedule = New-UDEndpointSchedule -Every 1 -Second
$Endpoint = New-UDEndpoint -Schedule $Schedule -Endpoint {
$Cache:Products = 100 # if I change the value here, it is not loading
}
Step 2 - Do a Sync-UDElement targeting the ID you set on the counter
$Endpoint = New-UDEndpoint -Schedule $Schedule -Endpoint {
$Cache:Products = get-random -Minimum 0 -Maximum 100 # if I change the value here, it is not loading
Sync-UDElement -Id "Counter1" -Broadcast
}
i have txt file C:\temp\myfile.txt
if I put an integer value in the txt file, works well, when I put a string value e.g. test in the txt file, it comes 0
why?
@leeberg
Not to hijack the thread but…
I Assume the Sync-UDelement is used to force refresh the UDCounter control - could you then leave out the -autorefresh parameter completely, in this particular example?