• Welcome to RadioDJ - Free Radio Automation Software Forum. Please log in or sign up.

Overly complicated, but fun RadioDJ delayed start .bat file.

Started by Hidyman, January 14, 2023, 07:41:08 AM


I am moving my RadioDJ installation to a new machine and moving to RadioDJ version 2.
I sometimes go on little tangents while diving into these projects.
Thought I would share this batch program to delay the start of RadioDJ until after the database is running:

REM Copy Start

@ECHO off

TITLE ^>      -- Delayed Start of RadioDJ --
REM Change the value of _seconds_to_wait to the number of seconds you need to delay the start of RadioDJ
SET _seconds_to_wait=30
SET _space_count=%_seconds_to_wait%


   PING -n 2>nul
   SET /a "_seconds_to_wait-=1"
   SET _space_count=%_seconds_to_wait%
   SET "_spaces="
   if %_space_count% NEQ 0 (
      SET _spaces= %_spaces%
      SET /a "_space_count-=1"
      goto fancyformat
   ECHO RadioDJ Activation Sequence
   ECHO Starts in --^> %_spaces%^<--%_seconds_to_wait%
   if %_seconds_to_wait% NEQ 0 goto waitloop
   ECHO RadioDJ Activation Sequence
   ECHO Starts in --^>X%_spaces%^<-- %_seconds_to_wait%
   ECHO Activation Sequence Initiated
   REM Change the second argument to the folder that contains your RadioDJ installation
   REM Change the third argument to the actual RadioDJ.exe file
   Start "RadioDJ Delayed Start" /D "C:\RadioDJv2\" "C:\RadioDJv2\RadioDJ.exe"
   If %errorlevel% EQU 0 (
      TIMEOUT /T 3 /NOBREAK>nul
      ECHO RadioDJ startup is a SUCCESS!
   ECHO Something went wrong!


REM Copy End

Also attached is a text file that can be renamed to a .bat file.


If you need to have e predefined startup sequence or simply have some program delayed i suggest the free version of this sw:

I'm using it to have a start sequence such as:

at 10'' from start run program a
at 20'' ... program b
and so on

Even in the free version there are nice features such as delay start program b to wait program a full start or "run as administrator" privilege.