Hello community, I have an SPList named "Ingresos", and a field called "Clase" dropdown box type, so The document has a number of document wich is in the field named "Numero", then each value of the "Clase "dropdown box has a different value in "Numero".. but all of them are correlate values........., So I would like to suggest the next value in the "Numero" field when the Form is in NEW mode.., I I mean whtn I add records the field "Numero" suggests the next value...,(according to the "Clase" )
thank you
Solved! Go to Solution.
Hi @alexaristide ,
Ok, so the Clase column is choices type, right?
Please try this, set the Numero field Default value based on Clase dropdown selected value.
If(FormName.Mode = FormMode.New,
If(ClaseDropdowName.Selected.Value="A",
If(1001 in Filter(Ingresos,Clase.Value="A").Numero,
Last(Sort(Filter(Ingresos,Clase.Value="A"),Numero,Ascending)).Numero+1,
1001),
ClaseDropdowName.Selected.Value="B",
If(1001 in Filter(Ingresos,Clase.Value="B").Numero,
Last(Sort(Filter(Ingresos,Clase.Value="B"),Numero,Ascending)).Numero+1,
1001),
)
Parent.Default
)
Hope this helps.
Sik
@alexaristide
Could you please give a few specific examples of how the Numero value is determined with actual numbers?
the Numero value is a correlative number of document.., for example, 1001, 1002, 1003, 1004, etc.,
Hi @alexaristide ,
May I understand that you want to set the Numero field to be AutoNumber like this?
Please try to modify the Default property of TextInput box in Numero DataCard as follows.
If(FormName.Mode = FormMode.New,If(1001 in Ingresos.Numero,Last(Sort(Ingresos,Numero,Ascending)).Numero+1,1001),Parent.Default)
Hope this helps.
Sik
I am afraid this solution works in order to have the NEXT value of Numero..,. but, there are two "classes" of Numero, I mean there are in the CLASE field (dropdown box type) two values for the document.., so, I need to validate when it is for the next value of number for the document CLASE A, and when the document is of CLASE B, each correlative is different..,
CLASE is a dropdown box type column wich contains two values (A, B),
thank you
Hi @alexaristide ,
Ok, so the Clase column is choices type, right?
Please try this, set the Numero field Default value based on Clase dropdown selected value.
If(FormName.Mode = FormMode.New,
If(ClaseDropdowName.Selected.Value="A",
If(1001 in Filter(Ingresos,Clase.Value="A").Numero,
Last(Sort(Filter(Ingresos,Clase.Value="A"),Numero,Ascending)).Numero+1,
1001),
ClaseDropdowName.Selected.Value="B",
If(1001 in Filter(Ingresos,Clase.Value="B").Numero,
Last(Sort(Filter(Ingresos,Clase.Value="B"),Numero,Ascending)).Numero+1,
1001),
)
Parent.Default
)
Hope this helps.
Sik
User | Count |
---|---|
261 | |
110 | |
90 | |
54 | |
44 |