My main goal is to enable typed search with a Form's DataCard component so I've created a ComboBox and referenced it in the respective DataCard (Área_DataCard3) Update function. This works fine, but whenever the form updates its DataCards with error messages, the ComboBox component does not update its position. It uses the position from before the form is updated.
Y
RectQuickActionBar3.Height +
Área_DataCard3.Y +
DataCardKey9.Y +
DataCardKey9.Height + 5
Is this a bug? Is there anyway I can recalculate the ComboBox Y value after the form is updated?
Thanks!
Hi @Anonymous ,
The reason why you met this problem is that the value inside the form like RectQuickActionBar3.Height,Área_DataCard3.Y will all become invalid after the form is submitted.
So I suggest you set these values that you need as variables befor the form is submitted and then you could use.
For example:
Set the submit button's OnSelect:
Set(var1,RectQuickActionBar3.Height);
Set(var2,Área_DataCard3.Y);
Set(var3,DataCardKey9.Y);
Set(var4,DataCardKey9.Height); SubmitForm(Form1)
Set the Form's OnSuccess: Set(var5,"a")
Set the combo box's Y:
If(IsBlank(var5),original Y,var1+var2+var3+var4+5) //if the form is submitted, the combo box's position will change
Best regards,
Thank you, Phoebe Liu!
However, that did not fix my issue. My problem happens when the form fails and the error messages make the DataCards move on screen. When I submit a failed form again, the position correctly update to its position. Maybe it has to do with the order that the components position are updated but shouldn't changes to Área_DataCard3 flag the ComboBox Y as "dirty"?