Omnis Windows Shortcut Question - Select Datafile

Doug Easterbrook doug at artsman.com
Tue Jan 5 22:30:23 UTC 2021


hi Jeff.

you can send command line parameters to the omnis executable and pick them up in sys(202)


We use this approach for our web services when we start multiple copies if omnis on the same machine.     While our needs are a little different than yours, the general gist of what we do is:

1) create a JSON file containing settings for omnis (eg port setup, postgres database location, user to login as, etc.)
2) start omnis with the above file name as a a parameter
3) read sys(202) as the first thing we do on startup
4) convert it from JSON to a row variable

and then do what we need to do.



You could use a DF1 for the same purpose with yout parameters in it.   the advantage of a DF1 is that there is some obsfucation possible since people may not have the file formats.   On the other hand, it makes it harder to set up the df1 if it needs customization for each user.


we have used XML as our startup file, which can be read with oXML … but that seems wordy


given the ubiquity of JSON, it is pretty to look at and the json capability in studio 10, it makes for easy creation and adjustment if need be.




our needs are a little different that yours, so one thing we do is create the file immediately before we start omnis and then have omnis destroy the file.      Thats because we have a tool that orchestrates many copies of omnis starting up and we don’t want it hanging around.

there is nothing wrong with permanent file either.   if things are sensitive, then just encstr() the entire file or the fields you don’t want people to see.   and decstr() it after omnis starts.  (or use any other encryption you like).



hope that helps.













Doug Easterbrook
Arts Management Systems Ltd.
mailto:doug at artsman.com
http://www.artsman.com
Phone (403) 650-1978

> On January 4, 2021, at 5:58 PM, Jeff Gibson <jgibson at interceptsolutions.com> wrote:
> 
> I have a quick question on incorporating the DF1 file to a library file.
> 
> 
> 
> So if I create a windows shortcut, in the path I can first set the path to
> the runtime, the add a second path to the library file.
> 
> 
> 
> My question is this.  Can a third path be added to the shortcut that would
> include the DF1 file?
> 
> 
> 
> So that way you would never be forced to select the datafile.  It would just
> automatically know the path.
> 
> 
> 
> Any info would be appreciated everyone!
> 
> 
> 
> Jeff Gibson
> 
> Nashville, TN
> 
> Oversite Online
> 
> 
> 
> _____________________________________________________________
> Manage your list subscriptions at http://lists.omnis-dev.com
> Start a new message -> mailto:omnisdev-en at lists.omnis-dev.com



More information about the omnisdev-en mailing list