cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Announcements
Walkthrough Wednesdays
616
Views
0
Helpful
8
Replies
nathan.a.reeves
Beginner

Possible to get script path from within script

Wondering if there's any possible way to determine the script name that's being run from within the script itself.  I realise that you can manually configure a variable but I'm trying to be able to do this automatically.  Find the path as well would be useful.

Any pointers?

8 REPLIES 8
Gergely Szabo
Advocate

Hi, what script do you mean? ICM? UCCX AEF?

G.

Apologies, should have included more info there.  Scripts are UCCX AEF.

Thanks.

Hi, is this IP IVR or pure UCCX?

I mean, there must be a way and after two hours of debugging, it really pisses me off. I am using an IP IVR and I don't see the running script name anywhere.

Also, can you tell me more about the context, what is the purpose of this infromation? Thanks.

G.

Seems my last reply didn't get saved.

Pure UCCX in this case.  Happen to be running standard license but also got premium etc on other installs I manage.

Trying to put together some standard scripts (eg prompt recording/enable/disable) which at the moment I have to update each time I deploy them to specify prompt and document folder names.  I was trying to pull the path from the running script and then default to using the same string for the path in the documents and prompts.  Just means I can deploy without having to change things.

Appreciate you looking into this.

Hi, I might be slow today but I think I am missing something.

This way: if you want to do the same thing with using different objects, e.g. the functionality would be playing the prompt but the exact prompt is decided at runtime, then you can use either the Parameters on the Application level (multiple applications with different sets of parameters pointing to the same script).

Alternatively, you can use an external data source to decide what to do (e.g. XML file in the Document Repo or even a HTTP source). 

Is this what you are after?

G.

Thanks for the update.  Yeah I'd considered both of those options (probably heading towards an xml file).  I was more just trying to get this to get auto determined at run time.  Guessing it will be via xml / parameter settings at this point if there's no easy way of getting the path programatically.

Hi, problem is that you can't really get the file path, or rather, it would be useless as scripts (and virtually all objects like documents, recordings etc) are stored in a database. 

Also, there's no easy way of getting this information. I mean, it must be somewhere but I can't see any publicly available method of getting that information within that script.

G.

Pure UCCX  (In this case standard license).  I was trying to construct some scripts I could easily use across different apps (eg a prompt recording / enable and disable process).  In my current use of the scripts, I have to update doc and prompt paths etc.  I was trying to grab the current script path and then use that same path for docs and prompts (so I don't have to manually change things).

Appreciate you looking into this.

Content for Community-Ad

Spotlight Awards 2021

This widget could not be displayed.