Sign in to follow this  
Followers 0
Paulio

String Substitutions in Super genies from Genies

2 posts in this topic

Hi Bit stuck here. I have 2 string substitutions in a genie which make up my tag names eg; NetworkBridge%NB#%_Meter%M#%_PV I have linked the genie to a super genie via a ASSPOPUP. I need to use the %NB#% & %M#% values from the genie in the super genie. If I placed my genie on a new page it will display a box which has %NB#% & %M#% and two entry fields. I need these two entries to be passed to the super genie. Any ideas?

Share this post


Link to post
Share on other sites
E.g. you enter AssPopUp("!MyGenie", "NetworkBridge%NB#%", "Meter%M#%_PV") in your genie object, you place the genie on a page and enter respectively 1 and 2 in the entry box. Now in your Super Genie object these 2 tags are referred to as ?INT 1? which will be substituted by NetworkBridge1, and ?INT 2? which will be substituted by Meter2_PV. Of course you have to use the data type as defined in the particular variable tags. See attached help file. At a certain point you will run into the restriction of the maximum of 8 variables which can be passed on using the AssPopUp function in a genie. To pass on more variables, in a Cicode file you can associate strings to 256 variables using the AssVarTags function (8 variables for every time you call this function) and separately you can open the super genie at the end of the AssVarTags lines with the WinNewAt function or PageDisplay function. You start the Cicode function with your function name and the string names you want to substitute. Now in the genie you call the function name and the strings, and in the Super Genie you place the substitution strings. Perhaps the attached explanation will be more clear... Hope this helps! Hang in there, I remember it took me a while to see the light on the whole Genie / Super Genie thing but once you get the hang of it you discover how much programming time this can actually save when using a lot of the same graphic objects. Definig_Substitutions_for_Super_Genies.pdf AssVarTags.pdf

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0