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

CORRECT MY CODING...

Former Member
0 Likes
698

hi Gurus,

check my coding here...

if <wa_report>-PSTYV = 'YN61' or <wa_report>-PSTYV = 'YN67'.

<wa_report>-FOC = 'K'.

elseif ZOFM > 0 .

<wa_report>-FOC = 'V'.

else.

clear <wa_report>-FOC.

endif.

here im getting zofm is unknown but its defined in the structure zos009...so hw to solve it.

correct answeres will be awarded.

sirish.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
666

u r using the field name alone, u have to use the <work area> - <field > format

as per ur logic,

something like

<wa_report>-FOC = 'K'.

elseif <b>zos009-ZOFM > 0</b> .

<wa_report>-FOC = 'V'.

4 REPLIES 4
Read only

Former Member
0 Likes
666

HI,

use zos009-ZOFM > 0 .

rgds,

bharat.

Read only

Former Member
0 Likes
667

u r using the field name alone, u have to use the <work area> - <field > format

as per ur logic,

something like

<wa_report>-FOC = 'K'.

elseif <b>zos009-ZOFM > 0</b> .

<wa_report>-FOC = 'V'.

Read only

former_member386202
Active Contributor
0 Likes
666

Hi,

Try like this

if ( <wa_report>-PSTYV = 'YN61' ) or

( <wa_report>-PSTYV = 'YN67' ).

<wa_report>-FOC = 'K'.

elseif zos009-ZOFM > 0 . give here field name

<wa_report>-FOC = 'V'.

else.

clear <wa_report>-FOC.

endif.

Regards,

Prashant

Read only

Former Member
0 Likes
666

Hi ,

if <wa_report>-PSTYV = 'YN61' or <wa_report>-PSTYV = 'YN67'.

<wa_report>-FOC = 'K'.

elseif <b> zos009 ZOFM</b> > 0 .

<wa_report>-FOC = 'V'.

else.

clear <wa_report>-FOC.

endif.

Try using this.

Regards,

Priyanka.