Parker Software Ltd Homepage
Forum Home Forum Home > ThinkAutomation Business Process Automation > Scripting
  New Posts New Posts RSS Feed - Access Global Constant
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Access Global Constant

 Post Reply Post Reply
Author
Message Reverse Sort Order
bmorency View Drop Down
New User
New User


Joined: 24 Nov 2016
Location: canada
Points: 23
Post Options Post Options   Thanks (0) Thanks(0)   Quote bmorency Quote  Post ReplyReply Direct Link To This Post Topic: Access Global Constant
    Posted: 04 Jun 2019 at 7:26am
Hi,

Thank you I will give that a try.

Beau
Back to Top
parkersoft-nick View Drop Down
Admin Group
Admin Group
Avatar
Lead Developer - ThinkAutomation

Joined: 28 Dec 2015
Location: UK
Points: 133
Post Options Post Options   Thanks (0) Thanks(0)   Quote parkersoft-nick Quote  Post ReplyReply Direct Link To This Post Posted: 04 Jun 2019 at 7:23am
Hi Beau,

You can reference a constant in a ThinkAutomation script using the below syntax:

Constant("myconstantname")

So if wanted to use a connection string constant in a DB call via a script it would be along the lines of:

DB.open(Constant("myConnectionStringConstant"))

Hope this helps.

Nick.




Edited by parkersoft-nick - 04 Jun 2019 at 7:24am
Nick Proud - Parker Software
Software Architect ThinkAutomation
Back to Top
bmorency View Drop Down
New User
New User


Joined: 24 Nov 2016
Location: canada
Points: 23
Post Options Post Options   Thanks (0) Thanks(0)   Quote bmorency Quote  Post ReplyReply Direct Link To This Post Posted: 04 Jun 2019 at 7:15am
Hi,

I have setup a global constant connection string. I am wondering how do I access that variable in my script? A lot of my triggers access a database and I would like to change the connection string in one place.

Thank you.

Beau
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.05
Copyright ©2001-2016 Web Wiz Ltd.

This page was generated in 0.109 seconds.