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

sapscript problem or condition

Former Member
0 Likes
676

example my code

/: IF &REGUH-LAUFI+5(1)& = 'R'

/* -


modifiche BGP 08.06.06

/: IF &REGUH-ZBUKR& = 'CAI0'

/: OR &REGUH-ZBUKR& = 'CAI1'

/: OR &REGUH-ZBUKR& = 'CAI2'

A1 ,,CMF - ROM

/: ELSE

A1 ,,Tesoreria

/: ENDIF

me unknown command

1 ACCEPTED SOLUTION
Read only

kesavadas_thekkillath
Active Contributor
0 Likes
646

This message was moderated.

5 REPLIES 5
Read only

kesavadas_thekkillath
Active Contributor
0 Likes
647

This message was moderated.

Read only

Former Member
0 Likes
646

i have solved

/: IF &REGUH-LAUFI+5(1)& = 'R'

/* -


modifiche BGP 08.06.06

/: IF &REGUH-ZBUKR& = 'CAI0' OR &REGUH-ZBUKR& = 'CAI1' OR &REGUH-ZBUKR& = 'CAI2'

A1 ,,CMF - ROM

/: ELSE

A1 ,,Tesoreria

/: ENDIF

me unknown command

Read only

0 Likes
646

/: IF &REGUH-ZBUKR& = 'CAI0'

/: OR &REGUH-ZBUKR& = 'CAI1' OR &REGUH-ZBUKR& = 'CAI2'

/: OR &REGUH-ZBUKR& = 'AIR1' OR &REGUH-ZBUKR& = 'AIR2'

/: endif

when I run the syntax check tells me that the command 'or' is unknown

Read only

0 Likes
646

Hi,

You have to use the IF statement in the same line.

/: IF &REGUH-ZBUKR& = 'CAI0' OR &REGUH-ZBUKR& = 'CAI1' OR &REGUH-ZBUKR& = 'CAI2' OR &REGUH-ZBUKR& = 'AIR1' OR &REGUH-ZBUKR& = 'AIR2'

When you reach the end of the line press Shift+F8 to extend the line in script editor and comeplete the if statement in the same line.

Regards,

Vik

Read only

0 Likes
646

if not do it with the length.