a!localVariables( local!Details: rule!GetInformation(), a!formLayout( ....... showwhen:if(local!Details <> "ERROR") ) )
Hi,
I want to show the formLayout in the design mode(designer/expression) irrespective of the return value of rule!GetInformation() expression rule. However in runtime the form should load as mentioned in above code i.e., based on the return value of rule!GetInformation() .
Kindly suggest.
Discussion posts and replies are publicly visible
Appian does not support to run code depending on whether it runs in designer or "runtime".
What do you want to achieve?
Since i want to load the interface for designing and see the changes reflecting i dont want the rule to be called how to achieve that. when i am designing.
I am not sure I understand which problem you want to solve. What is wrong with that rule? When I design an interface, I typically provide some test data to see how it works.
That rule is a integration call which will throw an error when data is not passed. We dont want to pass the data when we are designing an interface and hence interface should load with no data. In designer/Expression mode we want the integration call(expression rule) not to happen such that interface is loaded.
I would create a rule input isIntegrationEnabled which I would set to false in design mode.
In your interface, I would create a local variable with the same name and use a!defaultValue to set it to true in the case it is not defined.
You can then use the local!isIntegrationEnabled to only call the integration if enabled.
But ... designing an interface without showing ANY data ... not sure how I would do that ... maybe lots of guessing and rolling a dice!?!?!
Then, you could just use some example data instead of calling the integration in case no data is passed.
To be honest, I do not see the problem ....