2013 Oct 21 3:07 AM
Hi Guys,
I have a requirement to do some program logic under the table node in Smartform.
if I insert a program logic inside a table, when it will be processed..? before loop iteration or after it..?
I have to some text and numerical changes to some of the fields before it get printed inside the table loop for each item.
Thanks
Sam
2013 Oct 21 4:06 AM
Hi Sam,
If you insert programming logic inside table node, that will be executed every time in the loop. So, if your logic is to change values on workarea of table, you can insert in table node.
Thanks & Regards,
-Vijay
2013 Oct 21 6:33 AM
HI Sam Vel,
U have Nice Name, You Can perform these operation on your TABLE FIELDS compare,check,initialize to other field,sort,
YOU Need to assign some calculated value to Field Each time on LOOP .
to solve your problem it's easy to make ( program line) before loop in smartform
and make text and numerical changes.
Please tell me How Is That.
Thanks
2013 Oct 21 6:52 AM
Dear Sam Vel,
Wht you just have to do in which cell you want the changes to be happend.
before the text put a programlines right click create->flowlogic->programlines.
now dblc click on the programlines in this case %CODE3.
you will see the input and output parameters.
Here you can see I have been using the wa_ftab-item and v_item two variables.
Wa_ftab-item is coming from loop and v_item is the global dcelaration and now the result is coming in v_val.
Now My result is in v_val which I have decleared in the global definition.
now put the variable iv_val in the TEXT below the %CODE3.
you will get the desire result.
Regards,
2013 Oct 21 7:06 AM
2013 Oct 21 7:22 AM
Hi Sam ,
This is the way to use Program Line in Table Node:
And there is nothing new in putting code in Table node .
Put variable to be used in Input Parameter and Output Parameter .
Keep Learning and sharing,
Jeetendra
2013 Oct 21 7:26 AM
hi,
3 steps
1) make one Program limes in parent node of LOOP
in this case MAIN mainwindow
2) %code1 is default first program line name
inside program line
pass input and output parameters
which used in your logic inside %cod1
IT's done
Only two steps boss.
thanks
2013 Oct 25 1:39 PM
HI Sam,
one solution is That inside loop You Can Create PROGRAM LINES
and do your operation with table work area
THANKS
PRAVEEN