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: SU01: Maintain Address Data Window: 500 on record/ 0200 on playback.

Former Member
0 Kudos

Though not a novice to programming or scripting, I am a novice to ECATT scripting. With that, I hope that someone can help me with this situation.

I need to create a script to create user accounts. On Some "new" accounts, the system will pop up a window titled "Maintain Office Data" with the question "Old SAPoffice data found for this user name. Do

you want to copy this data to the new user?"

I want my script to press the button only when this window appears. My script is:

SAPGUI ( SU01_50_1 ).

IF (SY-DYNNR = 500).

SAPGUI ( SU01_500_1 ).

ENDIF.

SAPGUI ( SU01_100_1 ).

SAPGUI ( SU01_50_2 ).

My problem is that the system appears to present screen 500 to ask the question when I record the script, but presents screen 0200 when I run my script. I receive a log entry showing SY-DYNNR = 0200.

I cannot change the screen number within the sapgui command interfaces, nor do I really want to. I also cannot find a way to get the system to give me screen 0200 during a recording session.

If anyone can provide a better script, or explain why SAP presents two screens, I would greatly appreciate it.

5 REPLIES 5

uwe_schieferstein
Active Contributor
0 Kudos

Hello Michael

I would debug the SU01 transaction and find out under which old SAP office data are found. There must be some function module around or entries existing in certain tables.

Next step is to create two recordings: one recording without the popup, and one with the popup.

Finally, depending on whether you expect the popup to appear or not you execute either the one or the other recording.

Alternatively, you may look for a customizing switch which might allow you to suppress the check for old SAP office data. If you find such a switch you could run the following logic:

1. Set the switch OFF.
2. Run recording without popup.
3. Set the switch ON.  " If you do not want to turn it off permanently.

Regards

Uwe

Former Member
0 Kudos

I did find a solution. Though a bit messy, here is what I did:

MESSAGE ( MSG_1 ).

TCD ( SU01, SU01_1_NEW ).

ENDMESSAGE ( E_MSG_1 ).

V_MESSAGES = E_MSG_1[1]-MIDX.

ACT_CREATED = E_MSG_1[V_MESSAGES]-MSGV1.

LOG ( ACT_CREATED ).

IF ( &MSI = '00' AND &MSN = '344' ).

MESSAGE ( MSG_1 ).

TCD ( SU01 , SU01_1_EXISTING ).

ENDMESSAGE ( E_MSG_1 ).

V_MESSAGES = E_MSG_1[1]-MIDX.

ACT_CREATED = E_MSG_1[V_MESSAGES]-MSGV1.

LOG ( ACT_CREATED ).

ENDIF.

Thank you for your help.

0 Kudos

Hi Gurus,

Sorry to reply to such an old posting.

However, I'm having a similar issue with my ECATT scripting as shown below.

My ECATT script to mass create user account:

TCD ( SU01 , SU01_1 ).

Error messages: 

Error in eCATT command TCD SU01

Control data is obsolete, rerecord (VERBS-NAME: CreateObject CATT: <none>

Callno: 000001)

I've also tried to use solution provided by Michael, but it's not working.

When I tried to simulate creating the same user account manually, I noticed the following error messages:

Old SAPoffice data found for this user name. Do you want to copy this data to the new user?

Appreciate if you could advise on how to fix this error.

Thank you.

- Jack

0 Kudos

there's note 162108 - but careful with that one!

depending on the release you are running, 129010 might help.

 

If you are using SAPGUI recording, you can make the screen as optional by opening up the SAPGUI command interface (double-click in code editor), expanding the tree display for the relevant ProcessedScreen node and changing the "Active" flag from 'X' (compulsory) to 'O' (optional).

Hope it helps!!!!


0 Kudos

Hi Laxman,

Thanks for your reply and advise.

Will it be possible to fix the problem using ECATT scripting just like what Michael Fretheim has posted earlier?

FYI, I'm using SECATT to create ECATT scripting.

Thanks.

- Jack