morciani
15 years agoOccasional Contributor
Referencing properties inside a DataGen Test Step
Hello,
Is there a way to reference properties from within a DataGen Test step? I want to be able to conditionally set the value of a second property based on the value of the first property. Both properties are contained in the same DataGen step (DataGen_getGlobalData) Take this example of this Test Step:
Test Step Name: DataGen_getGlobalData
Property1: SignOnRoleCd (Type = Script, Mode = STEP, not Shared)
Configuration:
import javax.swing.*
String SignOnRoleCd=JOptionPane.showInputDialog("SignOnRoleCd: Agent or Customer");
Property2: PIN ((Type = Script, Mode = STEP, not Shared)
Configuration:
if (#SignOnRoleCd == "Customer")
{
String PIN = "N0000000"
} else {
String PIN=JOptionPane.showInputDialog("PIN");
}
How do I reference SignOnRoleCd within the configuration of Property2?
Is there a way to reference properties from within a DataGen Test step? I want to be able to conditionally set the value of a second property based on the value of the first property. Both properties are contained in the same DataGen step (DataGen_getGlobalData) Take this example of this Test Step:
Test Step Name: DataGen_getGlobalData
Property1: SignOnRoleCd (Type = Script, Mode = STEP, not Shared)
Configuration:
import javax.swing.*
String SignOnRoleCd=JOptionPane.showInputDialog("SignOnRoleCd: Agent or Customer");
Property2: PIN ((Type = Script, Mode = STEP, not Shared)
Configuration:
if (#SignOnRoleCd == "Customer")
{
String PIN = "N0000000"
} else {
String PIN=JOptionPane.showInputDialog("PIN");
}
How do I reference SignOnRoleCd within the configuration of Property2?