Error Starting RadioFeed From Powershell

wbhartmanii

Member
Joined
Jun 30, 2015
Messages
8
Location
Grand Haven, MI
Running 2 instances of RadioFeed on my Win10 machine.
(I'm a software developer)
I'm making a PowerShell script that will run occasionally to automatically ensure that there are 2 instances running. If not, it will kill all instances and restart. The idea is that it will auto recover from a crash or any funny behaviors that happen from being up and unattended too long.

Here is a simple version of the script:

#If it's running, kill it and wait 3 seconds for good measure and let any files unlock
If ((Get-Process -Name RadioFeed -ErrorAction SilentlyContinue))
{
Stop-Process -Name "RadioFeed" -Force
Start-Sleep -s 3
}

#Start both versions
Start-Process -FilePath "E:\Programs\RadioFeed\RadioFeed - Marine\RadioFeed.exe"
Start-Process -FilePath "E:\Programs\RadioFeed\RadioFeed - Aviation\RadioFeed.exe"


The issue I'm having is that if I run the .ps1 in the PowerShell ISE it works great just as expected. But if I run it as a scheduled task, the launch of the application fails. It does start, but I get a message box from the application with this error: (well - 2 identical message boxes actually, 1 for each instance I started)
Can Not Find The File: ProScan1.dll In The Application Folder.
Check For The File Or Install The Complete Package.


Any ideas what might be happening in the apps? Permissions? File access clashes? I'm running the task as my username and with highest privileges.
 

EMTMFD

Newbie
Premium Subscriber
Joined
Sep 1, 2010
Messages
1
Location
Blackstone, Mass
Looks to me to probably be a permissions issue, or pathing issue. Scheduled tasks probably run using a system account, and if it can't find the path to the .dll you probably would see this. Also make sure the system account has execute rights to the folder and files....
 

a417

Active Member
Joined
Mar 14, 2004
Messages
504
this is what systemd excels at.

:ducks: heheh

Ok, it's been a while since i scheduled tasks on a windows machine, but it looks like it hasn't changed much. Are you running the .ps1 from the same directory as the application is stored in? I'm thinking if you're not running that task from the same directory as the app, that might cause what you are seeing when it runs via command line, but not from the task scheduler. I think it's the "Start in" box? Have you tried side by side installs in separate folders?
 

ProScan

Member
Premium Subscriber
Joined
Jul 2, 2006
Messages
3,526
Location
Ontario, Calif.
Running 2 instances of RadioFeed on my Win10 machine.
(I'm a software developer)
I'm making a PowerShell script that will run occasionally to automatically ensure that there are 2 instances running. If not, it will kill all instances and restart. The idea is that it will auto recover from a crash or any funny behaviors that happen from being up and unattended too long.

Here is a simple version of the script:

#If it's running, kill it and wait 3 seconds for good measure and let any files unlock
If ((Get-Process -Name RadioFeed -ErrorAction SilentlyContinue))
{
Stop-Process -Name "RadioFeed" -Force
Start-Sleep -s 3
}

#Start both versions
Start-Process -FilePath "E:\Programs\RadioFeed\RadioFeed - Marine\RadioFeed.exe"
Start-Process -FilePath "E:\Programs\RadioFeed\RadioFeed - Aviation\RadioFeed.exe"


The issue I'm having is that if I run the .ps1 in the PowerShell ISE it works great just as expected. But if I run it as a scheduled task, the launch of the application fails. It does start, but I get a message box from the application with this error: (well - 2 identical message boxes actually, 1 for each instance I started)
Can Not Find The File: ProScan1.dll In The Application Folder.
Check For The File Or Install The Complete Package.


Any ideas what might be happening in the apps? Permissions? File access clashes? I'm running the task as my username and with highest privileges.
I'm looking at this now.
 

ProScan

Member
Premium Subscriber
Joined
Jul 2, 2006
Messages
3,526
Location
Ontario, Calif.
Running 2 instances of RadioFeed on my Win10 machine.
(I'm a software developer)
I'm making a PowerShell script that will run occasionally to automatically ensure that there are 2 instances running. If not, it will kill all instances and restart. The idea is that it will auto recover from a crash or any funny behaviors that happen from being up and unattended too long.

Here is a simple version of the script:

#If it's running, kill it and wait 3 seconds for good measure and let any files unlock
If ((Get-Process -Name RadioFeed -ErrorAction SilentlyContinue))
{
Stop-Process -Name "RadioFeed" -Force
Start-Sleep -s 3
}

#Start both versions
Start-Process -FilePath "E:\Programs\RadioFeed\RadioFeed - Marine\RadioFeed.exe"
Start-Process -FilePath "E:\Programs\RadioFeed\RadioFeed - Aviation\RadioFeed.exe"


The issue I'm having is that if I run the .ps1 in the PowerShell ISE it works great just as expected. But if I run it as a scheduled task, the launch of the application fails. It does start, but I get a message box from the application with this error: (well - 2 identical message boxes actually, 1 for each instance I started)
Can Not Find The File: ProScan1.dll In The Application Folder.
Check For The File Or Install The Complete Package.


Any ideas what might be happening in the apps? Permissions? File access clashes? I'm running the task as my username and with highest privileges.
It's fixed. Email me so I can send you the latest RadioFeed file.

{edit} Also you can use the existing version you have now by doing this:

On the PS command line
CD E:
CD \Programs\RadioFeed\RadioFeed - Aviation\
 
Last edited:

ProScan

Member
Premium Subscriber
Joined
Jul 2, 2006
Messages
3,526
Location
Ontario, Calif.
It's fixed. Email me so I can send you the latest RadioFeed file.

{edit} Also you can use the existing version you have now by doing this:

On the PS command line
CD E:
CD \Programs\RadioFeed\RadioFeed - Aviation\
Or do it in the script. I was using the command line to duplicate the problem.
 

wbhartmanii

Member
Joined
Jun 30, 2015
Messages
8
Location
Grand Haven, MI
Awesome! The PS script edit does work! I'll assume the fix will be in a future release but this works for now so no need to send the new version right now.
Modified the Start-Process part to be:

CD E:
CD '\Programs\RadioFeed\RadioFeed - Marine'
Start-Process -FilePath "E:\Programs\RadioFeed\RadioFeed - Marine\RadioFeed.exe"

CD E:
CD '\Programs\RadioFeed\RadioFeed - Aviation'
Start-Process -FilePath "E:\Programs\RadioFeed\RadioFeed - Aviation\RadioFeed.exe"


Big thanks!
 
Top