The trick is to use a MS-Dos Batch file to start a special mode in kolmafia called CLI Mode.
Download the Jar version instead of the exe, then create a batch file similar to the following.
Code:
java -jar KoLmafia-7.6.jar --CLI script=scripts\scriptname.ash
or
Code:
java -jar KoLmafia-7.6.jar --CLI script=scripts\scriptname.txt
just like when you are saving an ash script, you must change the extension when you save the file. Save it with the .bat extension. Save the batch file in the same directory as kolmafia. Note change 7.6 to the version of kolmafia you ar using. It goes without saying that "scriptname" is the name of your script.
If you are using an ash script, it is easier to set up a seperate non ash script to handle logon. Save that file with a .txt extension. and call it in the batch file.
Code:
login username
call scripts\scriptname.ash
Logout
using a .txt file to handle logon has many many advantages. the main script could be used to handle multiple characters is one. The second is when modifying the main script it can be started from the normal user interface.
Now instead of scheduling kolmafia to run each day, schedule the batch file to run. The batch file will start kolmafia. kolmafia will not have the user interface when ran this way. If the script halts and cannot continue, then type "priphea" and press enter, and the normal user interface you are used to will appear.
Of course, you must have the password for the character saved in order for kolmafia to be able to log on using this method.
For testing, you can double click the batch file in windows, and it will run.
Double clicking the jar version of kolmafia in windows starts it the in the same way as the exe, so you wont need to keep the exe around unless you just want to.
Hmm, guess Nightmist beat me to it.