Error when adding new scripts

You have a question or need an advice about how to do something? Ask it here!
Post Reply
polp6880
Posts: 36
Joined: 19 Apr 2020 19:04
Error when adding new scripts

Post by polp6880 »

Hi,

We've recently been receiving an error when trying to add new scripts. The error is shown below:

Code: Select all

19/06/2021 08:37:17 [v4.2.4.2]:********** Error/Exception Information **********
Error Message: The given path's format is not supported.
Error Type: System.NotSupportedException
Error Source: mscorlib.Void EmulateFileIOPermissionChecks(System.String)
********** System Stack Trace **********
   at System.Security.Permissions.FileIOPermission.EmulateFileIOPermissionChecks(String fullPath)
   at System.Security.Permissions.FileIOPermission.QuickDemand(FileIOPermissionAccess access, String fullPath, Boolean checkForDuplicates, Boolean needFullPath)
   at System.IO.FileInfo.Init(String fileName, Boolean checkHost)
   at ProppFrexx.ScriptLibrary.Save()
   at ProppFrexx.ScriptLibraryConfigDialog.Xw6i()
   at ProppFrexx.ScriptLibraryConfigDialog.Pw6O(Object  , EventArgs  )
   at System.Windows.Forms.Control.OnClick(EventArgs e)
   at DevExpress.XtraEditors.BaseButton.OnMouseUp(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at DevExpress.Utils.Controls.ControlBase.BaseWndProc(Message& m)
   at DevExpress.XtraEditors.BaseControl.WndProc(Message& msg)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
********** End **********
As soon as this error is shown (either when testing a script or trying to save a new script), the application gives me the option to STOP or CONTINUE. If I choose STOP the application hangs completely. I also get this error as soon as I open up the General Settings view.

We have a lot of already working scripts in this setup and we only started receiving this error very recently.

Any help on how I could solve this would be greatly appreciated.

Thanks!
User avatar
radio42
Site Admin
Posts: 8295
Joined: 05 Apr 2012 16:26
Location: Hamburg, Germany
Contact:
Re: Error when adding new scripts

Post by radio42 »

The Exception indicates it’s trying to access an illegal file path, i.e possibly containing illegal characters.
An alternative is, that the file path became broken, because of a hard disk or network issue.

However, you can not initially create a (new) script with an illegal path - so something else outside of ProppFrexx must have changed or became broken.

What’s the exact path and filename of the script on which the exception occurs on?
When you just select the script in the Script Library dialog, the path and filename of the script is shown.
It is also shown at the top of the Script Library Editor (where you clicked the 'Test...' button) - so provide some screenshots...
AND check the accessibility of exactly those .pfs files.
I assume, that the error is in access this file...

Also check, if you by chance accidentally added an illegal character to the Default Script Folder (e.g. an invisible to human eye "‪" left-to-right embedding character). See the general settings, section Scripts/Scheduler.
polp6880
Posts: 36
Joined: 19 Apr 2020 19:04
Re: Error when adding new scripts

Post by polp6880 »

Hi Bernd,

When trying to add a new script, at the top of the window, the script file location is "1:test.pfs" - assuming that the script name is "test". Same happens when I try adding a new script and clicking the Test button.

When checking the previously added scripts I can see the proper directory location and script file name: C:\Users\User\AppData\Roaming\radio42\ProppFexx ONAIR\4.0\scripts\script.pfs

I tried checking for the directory settings in General Settings but I can't see an option to change the directory in "Scripts/Scheduler". For "default script folder" I only have a button that when clicked, shows the same error I posted above. Do I have to look someplace else for this?

It seems that the proper folder location for scripts cannot be read. Is there a way I can manually set this location?
User avatar
radio42
Site Admin
Posts: 8295
Joined: 05 Apr 2012 16:26
Location: Hamburg, Germany
Contact:
Re: Error when adding new scripts

Post by radio42 »

Your path and location "1:test.pfs" is incorrect! 1: is not a valid path - as such you get the error.
No idea how you ever created that, as I am impossible to do so and ProppFrexx doesn't allow that - maybe you changed that manually?!

Go to the path as you specified above, e.g. C:\Users\User\AppData\Roaming\radio42\ProppFexx ONAIR\4.0\scripts\:

a) open the file "ProppFrexx ONAIR.config"
locate in the section <SCHEDULER> the entry called "<add key="DefaultScriptPath" value=..." and change the value to a valid default path, e.g. to:
<add key="DefaultScriptPath" value="\Users\yourname\AppData\Roaming\radio42\ProppFrexx ONAIR\4.0\scripts" />

b) open the file "ProppFrexx ONAIR.scriptlibs"
and change all invalid paths (denoted in the "<add key=..." entry to a valid path.
polp6880
Posts: 36
Joined: 19 Apr 2020 19:04
Re: Error when adding new scripts

Post by polp6880 »

Yes - this indeed is a very strange issue.

I opened up the "ProppFrexx ONAIR.config" file and the path was set to "1:". I changed this value to the proper scripts folder, saved the file and restarted ProppFrexx. Upon opening, I re-checked the config file and everything was still ok.

I then tried to add a new script but at the top of the window, I saw "1:" once again. I re-opened the config file and the value was again reset to "1:". I changed again but noticed that as soon as I create a new script, the value is reset. This also happens whenever I open General Settings.

The script paths in "ProppFrexx ONAIR.scriptlibs" are all correct.
User avatar
radio42
Site Admin
Posts: 8295
Joined: 05 Apr 2012 16:26
Location: Hamburg, Germany
Contact:
Re: Error when adding new scripts

Post by radio42 »

When did you change the config file - while PF was open?
Note, that you must close PF - change the file and save it and after that you can restart PF.

However, did you maybe use "1:test" as a new filename?!
Note, that you should only specify a valid filename in the 'New Script' dialog, e.g. "test"
polp6880
Posts: 36
Joined: 19 Apr 2020 19:04
Re: Error when adding new scripts

Post by polp6880 »

Hi Bernd,

I just had time to do this and the issue is now resolved.

I dug a bit deeper into this and noticed that my colleague was creating top of the hour scripts and the first attempt was creating a script named "1:00". I can now see what issue could something like this cause :) Maybe in the future, there can be an extra check added when creating the script in PPFX so others don't fall into this.

Anyways, thanks a lot for the amazing support Bernd. It's much appreciated.
User avatar
radio42
Site Admin
Posts: 8295
Joined: 05 Apr 2012 16:26
Location: Hamburg, Germany
Contact:
Re: Error when adding new scripts

Post by radio42 »

That extra check is already added to the latest version ;-)
polp6880
Posts: 36
Joined: 19 Apr 2020 19:04
Re: Error when adding new scripts

Post by polp6880 »

Awesome! Top-notch support! Cheers!

Post Reply