Application Development 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: 

message.

Former Member
0 Kudos
358

hi guru

i have to generate some message.

one of them is

personnerl number &1 not in the valid period.

(for exception no_valididty)

i know little about se 91

but i could not get what i have to do with &1 and also what&1 do?

please help me with the same asap.

thanks

regrads.

anuj

16 REPLIES 16

suresh_datti
Active Contributor
0 Kudos
151

In this case &1 is a placeholder for the personnel number ie

in se91 lets say the message class is RP & the message number is 001

in your program you invoke this message as

message rp(001) with pernr-pernr.

~Suresh

0 Kudos
151

hi suresh,

i hav done the same but it is given an error that type of message should be mention.

that is I,E

please help me with the same

thanks

anuj

0 Kudos
151

Hi Anuj ,

With every message you need to specify the type of the message whether it is an Error message , Information message or a warning message , since you want to give an error message to write the statement as below

message <b>E</b>rp(001) with pernr-pernr.

Regards

Arun

0 Kudos
151

Hi Anuj,

Try this code,

message rp(001) with pernr-pernr type ' I '.

Thanks,

Reward If Helpful.

0 Kudos
151

hi viji

i have done the same but i am still getting the same message.

please help me sort the same

its saying that the the message should have a type either

I (Information), W (Warning) or A (Abend).

thanks

regrads

0 Kudos
151

Hi Anuj ,

Did you try the code i have posted.

Regards

Arun

0 Kudos
151

Hi,

try this , <b>it will work</b> :

data: text001 TYPE string VALUE '&1 string'.

REPLACE '&1' into text001 with 'test'.

message text001 type 'I'.

Regards,

Sooness

0 Kudos
151

hi arun.

yes i have tried ur code also

same message.

mention message type

anuj.

0 Kudos
151

Hi,

try this , it will work :

data: text001 TYPE string VALUE '&1 string'.

REPLACE '&1' into text001 with 'test'.

message text001 type 'I'.

<b>Only message types A, E, I, W, S, and X are allowed.</b>

Regards,

Sooness

0 Kudos
151

hi arun

please tell me where i have to put "&" the place holder.

it urgent.

please help me as soon as possible

thanks

anuj

0 Kudos
151

Hi Anuj ,

The Place holders & are placed where you want the value of the varaible.

e.g. You have a varaible v_test with value 100. and you want to display a message

Enter a value less than 100 then the message will be

Enter a value less than <b>&</b>.

and you call the message as below

<b>message E012(Z_TEST) with v_temp.</b>

E : Message Type Error

012 : Message Number

Z_TEST : Message Class

v_temp : Varaible containing the value to be repalced by &

Hope this helps.

Regards

Arun

0 Kudos
151

hi anuj,

so far as for the discustions you've created message callse T.code se91,

ex: message class name is zmsg assume for a while,

then u can write code like this,

at the report name,

zreport with message-id zmsg.

then if sy-subrc ne 0.

message i001 or s001 or e001(zmsg).

"and doble click on 001 ,

"enter yes,

"enter yes,

"on the message screen , provide your message at 001

"text personnerl number &1 not in the valid period'..

"save and back.

endif.

if u want personnel number instead of text 'personnel number,

then write like this,

message ioo1 (zsmg) with 'table-field'.(personnel no field)

and text shoud be & 1 not in the valid period.

reward points if helpful,

regards,

seshu.

Yogitha
Employee
Employee
0 Kudos
151

Hi,

Syntax:

Message <type><nnn>(message_class) [ with <v1> <v2>].

<type> = I(information), S(success), W(warning), E(error), A(termination), X(Short Dump).

<nnn>= message number

<v1> … = input parameter

In SE91, define the message class.

Then type the message corresponding to the desired message number.

e.g. Message class “AVY” message number “000”.

In the program where you want to raise the message

DATA: l_number type P_PERNR.

L_number = assign value.

Message E000(AVY) with l_number.

Regards,

Yogitha

Former Member
0 Kudos
151

Hi,

try with this code.

MESSAGE I001(zmsg) with itab-pernr.

where ' I ' is the message type, 001-message no and 'zmsg' - message class. The clause after 'with' will be replaced with place holder.

reward with points if it was useful.

Regards,

Hema.

S0025444845
Active Participant
0 Kudos
151

hi,

try with this.

MESSAGE i348(m7) WITH text-021.

where i messge type

347 message no

M7 message class

( in these u can put ur msg type , no and class as per ur requirement from se91)

asn after with u can pass watever u want in place of &.

for that either create text element or pass hard coded like

MESSAGE i348(m7) WITH 'PLANT'

if two & &

u can pass two values and at most u can pass upto 4 values.

regards,

sudha

Former Member
0 Kudos
151

hhhm,