Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

TFKT Table

Former Member
0 Likes
1,508

Hi friends !

How can i use TFKT Table ? Have you a document explain it ?

Thanks !

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
953

Hi FABRICIO VAZ DE SOUZA ,

U can enter some formulas in TFKT Tables and directly use it for ur calculations in ur program ..

OR u can pass the formulas directly from the program in paramater in the fields

TFKT-ARG

TFKT-FKT

TFKT is the table which is allowed for mainenance. So if someone decide to change a formula lateron, they can just change the entry in the table. In other word, TFKT can serve as some sort of a configuration table.

Also pls have a look on below program...



REPORT ZTEST.

DATA: FORMULA(50) VALUE 'TFKT:CIRCLEAREA(A)',
RADIUS TYPE F VALUE '1000',
AREA TYPE F,
RETCODE LIKE SY-SUBRC.

WRITE: / 'Entered Radius :', RADIUS.

CALL FUNCTION 'CHECK_FORMULA'
EXPORTING FORMULA = FORMULA
PROGRAM = 'ZANAND_TEST'
ROUTINE = 'CHECK_VALUES'
IMPORTING SUBRC = RETCODE.

IF RETCODE IS INITIAL.
CALL FUNCTION 'EVAL_FORMULA'
EXPORTING FORMULA = FORMULA
PROGRAM = 'ZANAND_TEST'
ROUTINE = 'GET_VALUES'
IMPORTING VALUE = AREA
EXCEPTIONS OTHERS = 1.
WRITE: / 'AREA Computed :', AREA.
ENDIF.

FORM GET_VALUES USING PARM CHANGING WERT SUBRC.
IF PARM = 'A'.
WERT = RADIUS.
SUBRC = 0.
ENDIF.
ENDFORM.

FORM CHECK_VALUES USING PARM CHANGING SUBRC.
IF PARM = 'A'.
SUBRC = 0.
ENDIF.
ENDFORM.

Have a look at the sample programs RSCALC01 and RSCALC10 also...

Hope it will solve your problem.

<REMOVED BY MODERATOR>

Thanks & Regards

ilesh 24x7

Edited by: Alvaro Tejada Galindo on Mar 4, 2008 12:24 PM

Hi friends !

How can i use TFKT Table ? Have you a document explain it ?

Thanks !

2 REPLIES 2
Read only

Former Member
0 Likes
954

Hi FABRICIO VAZ DE SOUZA ,

U can enter some formulas in TFKT Tables and directly use it for ur calculations in ur program ..

OR u can pass the formulas directly from the program in paramater in the fields

TFKT-ARG

TFKT-FKT

TFKT is the table which is allowed for mainenance. So if someone decide to change a formula lateron, they can just change the entry in the table. In other word, TFKT can serve as some sort of a configuration table.

Also pls have a look on below program...



REPORT ZTEST.

DATA: FORMULA(50) VALUE 'TFKT:CIRCLEAREA(A)',
RADIUS TYPE F VALUE '1000',
AREA TYPE F,
RETCODE LIKE SY-SUBRC.

WRITE: / 'Entered Radius :', RADIUS.

CALL FUNCTION 'CHECK_FORMULA'
EXPORTING FORMULA = FORMULA
PROGRAM = 'ZANAND_TEST'
ROUTINE = 'CHECK_VALUES'
IMPORTING SUBRC = RETCODE.

IF RETCODE IS INITIAL.
CALL FUNCTION 'EVAL_FORMULA'
EXPORTING FORMULA = FORMULA
PROGRAM = 'ZANAND_TEST'
ROUTINE = 'GET_VALUES'
IMPORTING VALUE = AREA
EXCEPTIONS OTHERS = 1.
WRITE: / 'AREA Computed :', AREA.
ENDIF.

FORM GET_VALUES USING PARM CHANGING WERT SUBRC.
IF PARM = 'A'.
WERT = RADIUS.
SUBRC = 0.
ENDIF.
ENDFORM.

FORM CHECK_VALUES USING PARM CHANGING SUBRC.
IF PARM = 'A'.
SUBRC = 0.
ENDIF.
ENDFORM.

Have a look at the sample programs RSCALC01 and RSCALC10 also...

Hope it will solve your problem.

<REMOVED BY MODERATOR>

Thanks & Regards

ilesh 24x7

Edited by: Alvaro Tejada Galindo on Mar 4, 2008 12:24 PM

Read only

0 Likes
953

I need make a view to tfkt ? or i need to creat a copy of tfkt and male a view ?

thanks