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: 

To add fields form ztable to VA01

Former Member
0 Kudos

Hi All,

I need to add some fields from ZTABLE to transaction va01 and i want to store

data entered in that fields.

So that dat should be saved in ztable or stadard table by doing Append structure .

And wt code shall i write for saving that data and where it should be added.

Thanks in advance.

Aniket

5 REPLIES 5

Jelena
Active Contributor
0 Kudos

You need a screen user exit to add a Z field and a user exit to manipulate the data.

See SPRO > Sales & Distribution -> System Modifications -> User Exits -> User Exits in Sales

Former Member
0 Kudos

HI,

Hi,

You can do this by implementing one screen exit and couple of usr-exit. For all of the exits given describing below you will need access key.

1. Field you want in VA01 line item, add them to table VBAP using append strucutre.

2. You can not show additional fields to the in VA01 where all the lines are display, instead you add the fields on "Additional data B" tab at line item level. To see the Additional data B screen, you can either double-click any line item and go to the very last tab OR use the menu path "Goto -> Item -> More functions -> Addition data B"

The screen for "Additional data B" is SAPMV45A 8459. Use transaction SE51 to implement this screen. Add these fields as a dictionary fields ( with reference to VBAP custom fields you have defined ).

3. To implement PBO logic of this screen, you will have to use include MV45AOZZ. This will require access key.

4. To implement PBI logic of this screen, you will have to use include MV45AIZZ. This will also require access key.

Please refer to following link for more information on "User-exit in sales document processing"

http://help.sap.com/saphelp_46c/helpdata/en/1c/f62c7dd435d1118b3f0060b03ca329/frameset.htm

Regards

Sudheer

0 Kudos

Thanks Sudheer,

I m new to User Exits. So can u tell me wt code shall i write in PBO and PAI module so that data entered in that fields will be saved in VBAP custom fields?

0 Kudos

Hi,

When yuo create field on screen "SAPMV45A 8459", create them directly with reference to the Z fields you have create in VBAP. So let's say the field you created in VBAP is ZFIELD1. The when you create a field on "SAPMV45A 8459", create it as input/output field, give a name "VBAP-ZFIELD1", select "dict" tab on attributes and select the checkbox "from dict".

This way, if this field has any value in VBAP, it will automatically display on the screen and if you change this value it will be automatically saved into database.

Let me know if you have any question.

Regards,

RS

Former Member
0 Kudos

Hi,

Please refer to following link:

It basically what "Sudheer Junnuthula" has written in his reply.

Regards,

RS