Hiyas,
Just wondering what the best way is to troubleshoot this error? I’ve pored over the .ps1 code and can’t spot where the error is. I’ve set the logging to debug (from the admin page) and downloaded the logs, can’t see in there anything that jumps out…
Dashboard .ps1 page shows this on load…
Log from the dashboard ‘Log’ tab in the admin pages…
Mar 29, 2022 10:31 AM An error occurred: The term '$JobName' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
Endpoint: eb79b775-5353-4877-ba96-a15adcb4d972
Session: 3eaf9ad4-afe8-4392-904e-9dc98a7e220c, User: DOMAIN\First.Last
Stack Trace:
- The term '$JobName' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. at eb79b775-5353-4877-ba96-a15adcb4d972:15
- eb79b775-5353-4877-ba96-a15adcb4d972:5
It looks like the $JobName variable is accidentally attempting to be called as like a function or something but I can’t see anywhere like that in the .ps1 page code.
Is there an even more verbose way to log what’s happening in the page, perhaps get the script line where this error is thrown?
Cheers!
Steve.