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: 

eCATT

Former Member
0 Kudos

Hello,

How to use the command Message - End Message to capture the messages occured during a execution. Tried all the ways but not able to capture the message and export it to the integrated script. It would be great if any one could provide me with unit testing and integrated test scripts for FI postings.

Regards,

Manoj

5 REPLIES 5

Former Member
0 Kudos

Hi,

for capturing the message,while u r recording some transactions with the use of sapgui some status bar message will come rite so at that time use chegui or getgui in that dialog box and capture the message.

once u select that chegui or getgui, when u r going to the particular transaction keep in status bar the red colour box appears click there.

Then one more pop up box appears there select text and then ok....i hope it helps u....

Thank u,

Manjula Devi.D

sachin_b
Employee
Employee
0 Kudos

Hi Manoj,

Unlike TCD which stores the messages that were thrown during the execution of the transaction in an internal table, the SAPGUI doesnu2019t have such temporary storage property. In either of the cases, it is advisable to enclose the recorded transaction within a MESSAGE ENDMESSAGE block.

MESSAGE ENDMESSAGE block apart from capturing the messages that were thrown also helps in setting user exits / rules to handle the messages. It has a feature to ALLOW/ EXPECT / EXIT ON a particular message in the MESSAGE header.

Enclose the transaction recording ( TCD / SAPGUI ) within the MESSAGE ENDMESSAGE block as shown.

MESSAGE(MSG_n).

TCD ( X, X)

ENDMESSAGE(MSG_n).

OR

MESSAGE(MSG_n).

SAPGUI ( X)

ENDMESSAGE(MSG_n).

On the first run of the eCATT, the messages thrown will be captured and can be seen in the ENDMESSAGE part of the recording.

Use an local variable / Export parameter ( as the need may be ) and then do the assignment of the values to the variable after the MESSAGE. ENDMESSAGE block as shown in the format.

u2022 Create a parameter of any name and with the parameter reference type u201CETTCD_MSG_TABTYPEu201D with View ( either as I / V/ E) as required. For the example I have used E_MESSAGES

u2022 Assign the (MSG_n) to the table and then access the records as we do to access any table record.

E_MESSAGES = E_MSG_n.

Prominently used data is the message numbers and other contents in the Message variables.

Hope it answers your question.

Thanks and best regards,

Sachin

Former Member
0 Kudos

Hello ,

Once the recorded the transaction is enclosed in the MESSAGE .. ENDMESSAGE block all the messages captured in the execution is stored in the ENDMESSAGE block.

On the other hand you can check in the MESSAGE block as to whether the message expected has appeared during the execution or not.

Hope it answers your question.

Thanks and Best regards,

Ajay

former_member131788
Active Participant
0 Kudos

<b> Thread open since Apr 2008 and hence closing thread as assumed answered.