Running a script file (MyScript.txt) from startup

Discussion forum for G-Force users

Moderators: BTT, andy55, b.dwall, juxtiphi

Post Reply
ddonovan
Posts: 7
Joined: Fri Aug 24, 2012 1:57 pm
Location: Minneapolis

Running a script file (MyScript.txt) from startup

Post by ddonovan »

Before the introduction of python in version 5, I used to be able to start a script file automatically at startup. How I did this before, was to have a line at the end of the “Boot.txt” file that would include the script that I wanted to run at startup. Something like this:
#include "MyScript.txt"

This would run the script file at startup. Now the change of the application to run Python files during startup, this functionality is gone. So far, I’ve tried these methods at the end of SSEngine.py, but they seem to only expect Python files:
SoundSpectrum.RunFile( '/Library/ MyScript.txt’)
SoundSpectrum.Include( '/Library/ MyScript.txt’)

These methods load the script, but it is interpreted as though it is a python file.

However, if I change the name to CTRL X.txt, and type CTRL X on the keyboard, the file loads and runs as expected.

Is there any way to run a (.txt) script file during startup?

FrankN
Posts: 316
Joined: Thu Mar 07, 2013 11:19 pm

Post by FrankN »

Hi ddonovan,

Thanks for writing! That's a good question! We haven't written a method for it yet.

However, I'm no expert at Python, but it seems like there should be a way to pass that txt file. Please, let us know if you find something!

jerohm
Senior Member
Posts: 421
Joined: Fri Jan 09, 2009 5:19 pm

Re: Running a script file (MyScript.txt) from startup

Post by jerohm »

ddonovan wrote:Before the introduction of python ...
:
Is there any way to run a (.txt) script file during startup?
Yes, TODAY anyway [at least on Win7]

Edit into:
C:\Program Files (x86)\SoundSpectrum\G-Force\Resources\Common\Startup.txt

Since 'I' have no control, I am not sure how long this method will work.
jrm

ddonovan
Posts: 7
Joined: Fri Aug 24, 2012 1:57 pm
Location: Minneapolis

Post by ddonovan »

Thanks for your help!
Your suggestion seems to work fine!

Pity there isn’t a list on methods that have been deprecated since the release of a new architecture. Other methods I’ve used in the past, seem to be obsolete now.

FrankN
Posts: 316
Joined: Thu Mar 07, 2013 11:19 pm

Post by FrankN »

Hi again,

We've been getting a lot of requests for this. Once the scripting changes have settled down, I'll write one.

Post Reply