10-09-2008 8:43 PM
OPEN DATASET p_opath FOR OUTPUT IN TEXT MODE MESSAGE gv_msg ENCODING DEFAULT.
IF sy-subrc <> 0.
1). How can I error here gv_msg with file path ( p_opath ) here ?
as gv_msg contians ' No such file or directory' in case of above sy-subrc = 8.
2 ). here, is always sy-subrc zero or eight ?
Thanks in adv
10-09-2008 8:54 PM
> OPEN DATASET p_opath FOR OUTPUT IN TEXT MODE MESSAGE gv_msg ENCODING DEFAULT.
>
> IF sy-subrc <> 0.
> 1). How can I error here gv_msg with file path ( p_opath ) here ?
> as gv_msg contians ' No such file or directory' in case of above sy-subrc = 8.
>
you can give your own meessage also, some meaningful one.
if sy-subrc eq 8.
message e000 with 'your own message'.
endif.
>
> 2 ). here, is always sy-subrc zero or eight ?
yes sy-subrc 0 or 8
10-09-2008 8:46 PM
Hi,
You can use message statement..
If sy-subrc <> 0.
message e398(00) with gv_msg p_opath.
endif.
OR concatenate the variables and display the message
OR You can prepare your own message.
Thanks
Naren
10-09-2008 8:54 PM
> OPEN DATASET p_opath FOR OUTPUT IN TEXT MODE MESSAGE gv_msg ENCODING DEFAULT.
>
> IF sy-subrc <> 0.
> 1). How can I error here gv_msg with file path ( p_opath ) here ?
> as gv_msg contians ' No such file or directory' in case of above sy-subrc = 8.
>
you can give your own meessage also, some meaningful one.
if sy-subrc eq 8.
message e000 with 'your own message'.
endif.
>
> 2 ). here, is always sy-subrc zero or eight ?
yes sy-subrc 0 or 8