Skip to Content
author's profile photo Former Member
Former Member

Table maintainance generator for view-masking the field and inserting value

Hi

I created the table maintainance generator for maintaince view. it consists of 7 filelds.i.e.absent type,sequence no,enddate,start date,points ,scale,weightage,higher limit. Now my problem is i want to mask the field sequence no. to avoid the user entries in this field and i have to insert numbers 1,2.3....Based up on entries and it has to increment. for this i have to add the code in the screen.can anyone suggest on this and what code and where exactly i have to write??

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Dec 14, 2011 at 06:17 AM

    Hi,

    In sm30 hide the field which you dont want to see by clicking on Configuration button in that check hide option and save it.

    In table maintenance click on environment->modification->events.

    In T give value 21 to fill the hiding value form name should be any and press enter in third column you will find abap editor button.

    In that place this code you need to place Form and endform between your code.

    FORM HIDE.

    data a type i .

    data wa type ztest_11.

    SELECT * from ztest_11 into wa.

    endselect.

    a = wa-sno.

    Ztest_11-sno = a + 1.

    ENDFORM.

    Hope this will be useful.

    Regards,

    G.Aditya

    Edited by: Aditya.G on Dec 14, 2011 11:47 AM

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 14, 2011 at 04:50 AM

    Hi,

    Check the modification events.

    Table maintenance generator -> Environment -> Modification -> events - Create a form routine and write the code.

    Try using event 01 as per your requirement to generate sequence numbers.

    Regards,

    Sharin.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 14, 2011 at 05:38 AM

    Hi,

    In sm30 hide the field which you dont want to see by clicking on Configuration button in that check hide option and save it.

    In table maintenance click on environment->modification->events.

    In T give value 21 to fill the hiding value form name should be any and press enter in third column you will find abap editor button.

    In that place this code you need to place Form and endform between your code.

    FORM HIDE.

    data a type i.

    Zempindex-insert = a + 1.

    ENDFORM.

    While creating entries no need to give uname it will automatically saved.

    Hope this will be useful.

    Regards,

    G.Aditya

    Edited by: Aditya.G on Dec 14, 2011 11:15 AM

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.