what to write script in

joey.jeremiah

ProgressTalk Moderator
Staff member
admscript.bat is what runs the scripts, similar to pro.bat
here's an example -

rem call is only necessary if you're running it from a batch file, but it can't hurt
call admscript script.p -db <mydatabase>


the sample.bat, just as an example, points to a c:\openedge\wrk\sports2000
database, and also access the db in single user mode ( -1 ).

if you open sample.bat, you'll see something like so ( i don't have the prog in
front of me at the moment )

call admscript sample.p -db c:\openedge\wrk\sports2000 -1
change the "-db ... -1" to something else, for example, "-db x:\mydatabase.db"

and give it another try ...


BTW i'm assuming you're using proenv ( from your start \ progress menu )
which, basically, sets a few environment variables.
 

joey.jeremiah

ProgressTalk Moderator
Staff member
I thought we should continue the discussion publicly ( hope it's not a problem ).

billfaith said:
it worked. it scrolls through a list of all the tables.

Great, now you're free to use 4gl.


Basically you can use the script I posted at the start, use sample.bat and
sample.p as an example.

You can then schedule the batch to run every hour or so, in windows.
Though the user disconnect script can be tweaked.


A few things I'd like to do in "Admin Script" is make it more durable in terms
of where it is runned from. Haven't thought about it, maybe add an .ini
and a propath, or add the prog to the %dlc% ?.

I'll be abit busy tomorrow and maybe the day after, maybe someone else
can come up with a way to make those changes ...

Happy to hear someone, somewhere is using it :)
 
Top