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: 

Customer Exit

Former Member
0 Kudos

Hi everyone. I'm new at this community and this is my first question.

I’m working on a customer exit for first time. Soon, I noticed how newbie I am, when I met this problem:

I’ve created the following function:

<b>FUNCTION EXIT_SAPMV13A_001.

*"----


""Interfase local

*" IMPORTING

*" VALUE(I_KOMG) LIKE KOMG STRUCTURE KOMG

*"----


INCLUDE ZZGF_EXIT_SAPMV13AU01 .

ENDFUNCTION.</b>

The problem occurs when I try to work with the structure I_KOMG (within ZZGF_EXIT_SAPMV13AU01). If I try to activate the include, the system indicates that the structure is not defined. However, when I delete all lines referring to I_KOMG in the include, (so I could activate it), I can see its content in debugging mode (from within the include). O_o.

What am I doing wrong?

Thanks in advance for any suggestion or comment.

Many greetings,

Andres Vidal

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi,

As you haved defined your own include with the given importing parameters, this include will not be a part of your actual program includes so you need to define the i_komg in your global data.

later you can activate the same.

Regards,

Jagath

3 REPLIES 3

former_member355937
Participant
0 Kudos

Hi Andres,

It's alright. That's normal. You're still doing fine.

The structure that you are referring to has already been declared in the main include (normally, TOP Include) of the corresponding function group of the function module (EXIT_SAPMV13A_001) you are using.

You need to find the portion where the structure has been populated. You can check the other function modules in the function group.

As another thing, since you are a new SDN member, you are welcome and let me introduce you the SDN forums pointing system: You can assign points to posts you find while helpful solving your question. You can reward points by clicking the yellow star icon at header of each reply post. You can reward;

- one 10 points (solved)

- two 6 points (very helpful answer)

- many 2 points (helpful answer)

Regards,

Jeffrey

Message was edited by: Jeffrey Prado

Former Member
0 Kudos

Hi,

As you haved defined your own include with the given importing parameters, this include will not be a part of your actual program includes so you need to define the i_komg in your global data.

later you can activate the same.

Regards,

Jagath

0 Kudos

Thank you very much, pals. I took a look at the TOP include of the function pool, but I found no definition there. So I wrote the declaration and then everything worked fine.

For a strange reason, I had the idea that the function parameters were declared automatically in the top include when creating the function, but obviously I was wrong.

Regards,

Andres Vidal