This question about Topic Markup Language and applications: More info required
Conditionally pass parameter to Topic
I want to pass a parameter to another topic after a condition is met. Using preferences, for example with IF statements, does not appear to work as all the macros (and set statements) in the first topic are expanded at run time.
The user will select the parameter from a list. Right now the only way I have gotten this to work is for the list to consist of anchors to different sections of the first topic. In each section is a
WikiWord link to a different topic. Right now there 30 sections and counting. I am hoping there is a way to set the value of a single parameter to be passed from a large number of choices.
The parameter to be passed will be used to link to a specific destination in a documentation library (either PDF or HTML).
--
DavidHearshen - 23 Mar 2022
If you could, break down exactly what you mean by "pass a parameter to another topic after a condition is met." What do you want to pass to the other topic? Just a url parameter or do you want to save some value in the other document? And what kind of "condition" in the first topic are you thinking of? Selections in a form? A change of a particular
DataForm field?
You're correct with regards to preferences. Although you
can use IF statements in a preference (
System.Macros), you can not
define a macro inside an IF statement. Another option is
System.VarSET which does allow for defining variables during runtime that act much like macros.
Your last statement seems to suggest that you're using a form to define parameters to generate your link to documentation. Are you only needing to display the links or are you wanting to store them somewhere? Or am I completely missing what you're after?
--
LynnwoodBrown - 24 Mar 2022