hello
I need your help, I have 2 ROSTER:
1st ROSTER food list
2° ROSTER, all the ingredients of each food must be listed, for which with the help of "setvalueset" (CPI_02) the values of ROSTER 1 are obtained, and in the variable (CPI_03) the name of the food of ROSTER 1 is assigned.
PROC CPI_02 // Aca se muestra la lista de preparaciones de la comda 1
// Estando en esta posición se ejecutara tando al avanzar como al retroceder
onfocus
preparaciones1.clear();
for CP_ROSTER where CP_01 > 0 do
preparaciones1.add(CP_02, CP_01);
enddo;
preparaciones1.sort(by code);
setvalueset (CPI_02, preparaciones1);
postproc
CPI_03 = getvaluelabel ($);
But I need the row number and name of the food from ROSTER 1 to be assigned in the variable (CPI_03), currently only the name of the food from ROSTER 1 is assigned.
Thank you for your time and support.
Atte. Paul Hinojosa
HELP - SETVALUESET
-
- Posts: 166
- Joined: November 21st, 2022, 4:41 pm
Re: HELP - SETVALUESET
Hello,
You are currently assigning the value of CPI_03 in CPI_02's postproc with "CPI_03 = getvaluelabel($)". This would for instance take CPI_02's value of "01" and assign CPI_03 the associated label of "POLLO". If you want CPI_03 to be "01 - POLLO" with both the value and the label, then in CPI_02's postproc you need to instead do something like
This should create a text using maketext that has CPI_02's number followed by the label, then sets that new text as CPI_03's value.
Hope this helps,
Justin
You are currently assigning the value of CPI_03 in CPI_02's postproc with "CPI_03 = getvaluelabel($)". This would for instance take CPI_02's value of "01" and assign CPI_03 the associated label of "POLLO". If you want CPI_03 to be "01 - POLLO" with both the value and the label, then in CPI_02's postproc you need to instead do something like
Code: Select all
CPI_03 = maketext("%v - %v", $, getvaluelabel($) );
Hope this helps,
Justin
Re: HELP - SETVALUESET
Thank you so much
It works just as she expected.
Thanks for the support.
Atte.
Paul Hinojosa
It works just as she expected.
Thanks for the support.
Atte.
Paul Hinojosa