PixInsight Forum (historical)

PixInsight => General => Off-topic => Topic started by: sleshin on 2011 May 31 17:42:17

Title: Loading PSM file at start up in ver 1.7
Post by: sleshin on 2011 May 31 17:42:17
In Pi 1.6 I set it up to automatically load a psm file per Juan's instructions here:

http://pixinsight.com/forum/index.php?topic=1649.msg9619#msg9619

Want to do the same in 1.7 but the Code: open $PXI_COREDIR/startup.scp  doesn't work. Get error message "No such file exists on the local filesystem: C:/Program" so can't get to the startup script file to allow modification.

Must require a different code line to do this in 1.7. Please advise.

Steve
Title: Re: Loading PSM file at start up in ver 1.7
Post by: Juan Conejero on 2011 May 31 22:51:41
Hi Steve,

That happens because there are white spaces in the value of the PXI_COREDIR variable. Try enclosing it between quotes; for example:

open "$PXI_COREDIR/startup.scp"

This is applicable to all platforms by the way.
Title: Re: Loading PSM file at start up in ver 1.7
Post by: sleshin on 2011 June 01 08:06:04
Thanks Juan,

The "  " worked and got the startup file into the script editor. I added the line with the path to the psm file but when I tried to save it I got error message:

Unable to rename file: C:/Program Files/PixInsight/bin/startup.scp: Win32 error (5): Access is denied.

What am I doing wrong this time? As you can tell, I'm not a programer. :)

Steve
Title: Re: Loading PSM file at start up in ver 1.7
Post by: georg.viehoever on 2011 June 01 09:44:30
Steve, you probably need to login as an administrator to edit the file.
Georg
Title: Re: Loading PSM file at start up in ver 1.7
Post by: sleshin on 2011 June 01 11:52:03
Hi Georg,

I am logged on administrator. Interestingly, able to save changes in startup file on my desktop and all works properly, but going through the same steps on my laptop, the file won't save. So, I remain stuck. Any other thoughts appreciated.

Steve
Title: Re: Loading PSM file at start up in ver 1.7
Post by: sleshin on 2011 June 02 08:38:24
Juan and Georg,

Got it to work on both computers. Just had to change the User account control setting on the laptop to get it to work. So, thanks to you both for the help.

Steve
Title: Re: Loading PSM file at start up in ver 1.7
Post by: Andres.Pozo on 2011 June 02 09:53:29
Juan and Georg,

Got it to work on both computers. Just had to change the User account control setting on the laptop to get it to work. So, thanks to you both for the help.

Steve
That is a quite radical action. For editing files in "controlled" directories like "C:\program files" or "c:\windows" there are easier and less risky methods.
The easiest way is finding the notepad in the Start menu, right click it and select "Run as administrator" in the context menu. Now you can edit and save any file in the system.
Title: Re: Loading PSM file at start up in ver 1.7
Post by: sleshin on 2011 June 02 10:25:59
Andres,

Thanks for that bit of information.

Steve