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: 

Custom extension Idoc hierarchic - MATMAS

Former Member
0 Kudos

Hi Experts,

I'm facing with big trouble.

I'd created the extension from Idoc MATMAS. I putted 2 segments child of E1MBEWM and E1MARMM.

I'm implement the user-exit to fetch the customs segments, until this point everything OK.

Althrought when I check the Idoc generated by BD10 I got problem. The child segment is shown on the same level that their parents. Like this:

E1MBEWM

ZE1MBEWM

Instead of

E1MBEWM

-


ZE1MBEWM

I thought this problem was about the two field of IDOC_DATA ( PSGNUM and HLEVEL ). Even I fetch them the result keep the same.

Anybody knows how solve this?

Thanks;

Paulo Afonso Cordeiro.

1 ACCEPTED SOLUTION

former_member589029
Active Contributor
0 Kudos

ZE1MBEWM should be on HLEVEL 4 and the parent segment PARSEG should be 'E1MBEWM'. Did you try that?

Regards,

Michael

7 REPLIES 7

former_member589029
Active Contributor
0 Kudos

ZE1MBEWM should be on HLEVEL 4 and the parent segment PARSEG should be 'E1MBEWM'. Did you try that?

Regards,

Michael

0 Kudos

I created using WE30 transaction for extension.

ZMBEWEXT Extension

-


E1MARAM Master material data (MARA)

(...)

-


E1MBEWM

-


E1MBEWM

0 Kudos

I was talking about the userexit, you need to make sure that the parent segment number (PSGNUM) or the parent segment name (PARSEG) are filled with E1MARAM (or corresponding number) and that the level is set to 4. That should resolve the issue.

Regards,

Michael

0 Kudos

hi Michel,

That's the point.

The idoc_data comes with fields PSGNUM and HLEVEL initials.

I make the check on the segment_name:

 if segment_name eq 'E1MBEWM'.

And then I create the new child segment (ZE1MBEWM) and I fiiled HLEVEL with 4 and PSGNUM = 5 But this value is never used, I mean doesn't make diference.

I'm implementing the EXIT_SAPLMV01_002.

Thanks for advice.

Paulo Afonso Cordeiro.

Edited by: Paulo Afonso Cordeiro on Apr 23, 2009 5:00 PM

0 Kudos

Hi Paulo,



zsegments must insert into internall table..if you append it will append yo last line..

in the coding read the above segment of the Zsegment and catch the index and insert(not append) the Zsegment at the index captured then only your seegment appears under the parent segemnt.

regards,

Prabhuds

0 Kudos

Hi,

I used INSERT the zsegment instead of APPEND. The efect was the same.

Why the fields PSGNUM and HLEVEL come empty in IDOC_DATA if IDOC_DATA has filled?

I can't understand.

Any tips else?

Thanks.

Paulo Afonso Cordeiro

0 Kudos

Hi, Prabhuds

I tried what u said but didn't work.And then I deleted all things I've done and do all again.

I don't know explain exactly what solve my prob. Now It's working fine.

Thanks everyone.

Paulo Afonso Cordeiro