How to maintain default values to the screen fields.

hi,
i m creating screen in se51.
when i press New button the screen is filled with default values
nrart = 'h' and proz1 = '100' .
how can i set default values.
plz give me a response

HI,
          You can set default values on to screen fields using SET and GET PARAMETER command, You need to assign a PARAMETER ID for that screen field and then use SET PARAMETER before the screen is called or in the PBO of the screen, you can set default values direcly in PBO of the screen but then you have hard code those value or read the data from database.
You need to have a TABLES statement to create a strucutre that you used to create your screen fields, then when you set value to these strucutre fields these values will get tranported to the screen fields automatically.
Regards,
Sesh

Similar Messages

  • How to set default values on the screen painter parameters?

    Hello ABAP Gurus,
    I would just want to ask how to set default values on the screen painter parameters.
    Thank you for your replies.

    Hi,
    To set default values for screen painter parameters initialize the field names with default values in the PBO module....
    say u have the field name as f_field1....
    in the PBO of that screen initialize it....
    f_field1 = '100'  "here 100 is the default value.
    <b>reward points if useful.</b>
    regards,
    Vinod Samuel.

  • How to maintain default values for custom table fields --  Urgent

    Hi all,
    I've a requirement wherein i need to create a Z table (with maintainence view) in which i'll have date and time as two of its field which should have current date and current time as default value. Can somebody suggest as how am i to maintain the date and time fields defaulting to current date and current time.
    Incase if someone is unable to intrepret what i'm trying to say, please query me, i'll elaborate it further.
    Please give in your quick inputs which is highly valuable to me and also will be highly appreciated.
    Thanks in advance,
    Vaishnavi Varadarajan

    We have a following custom table which contains the fields “Date on which record was created” and “Name of the person who created the object”. We would like to have these to be filled up with SY-DATUM and SY-UNAME respectively.
    Using the events, we can achieve this.
    Please refer the following link:
    http://abapliveinfo.blogspot.com/2007/12/events-in-table-maintenance-in-sap.html
    Also,
    Write a form routine in table maintanance generator.
    1. SE11 > utilities > table maintenance generator
    2. environment > modification > event
    define the event and form routine to make use of the tigger. in the form routine define an object for the class and call the relevant method.
    Or u can do it as:
    Table maintenance generator is basically used to do table operations like (insert, delete, modify...).
    if you create table maintenance for your table it will build a module pool program, by using you do the above operations.
    below is the procedure to create table maintenance generator.
    1) Create one function group.
    2) after activating your Ztable, choose 'Utilities'----> 'Table maintenance genrator'.
    3) then give the authorization group and function group created abobe in the next screen.
    4) Then choose the "create" button in your application tool bar, which will creates the module pool program.
    5) then create one Tcode by chosing "Transaction with parameters( parameter transaction)".
    6) in transaction field give "SM30", select the check box "Skip initial screen".
    7) in the below of that screen you can find the "Default values" frame.
    8) there under the "name of screen field" select the "View name' and 'update".
    9) in value column against to "view name" give you table name, and against to "Update" put 'X' in capital letters.
    save it then you can straight away use this newly created Tcode to maintain your table.
    Note:- 1) make the modification while saving the data into your table using this newly generated program to carry out your validation (even though it looks like standard program; no need to enter the access key).
    2) if you do any changes to your table and press the activate button automatically the table maintenace generator will be goes off, you need to create this again.
    cheers,

  • How to get default values on selection screen(multiple ranges)?

    i want to know how to maintain default ranges in selection screen...like 2000 to 3000 and 7000 to 8000 and 11000 to 15000
    all the above ranges must get by default how to provide those to selection screen by default...please give me idea...with example...

    Hi Suresh,
    You can either use select-options or Ranges. If you want the selection screen to be displayed with allwoing user to enter values apart for the default ones use select options else use ranges. With ranges what ever values use hard code would be set and the end user will not be able to add any more values (or range of values).
    Simply write the following code
    tables : <name of the table from which the field belongs>
    select-options <fieldname> for <tablename>-<fieldname>.
    <fieldname>-sign = 'I'.
    <fieldname>-option = 'BT'.
    <fieldname>-low = '7000'.
    <fieldname>-high = '8000'.
    append <fieldname>..
    similiarly add all the ranges that you need to include as default and in your select statement use the IN operator inthe where clause to include the range.
    If using range replacethe select-option with the range statement.
    Thanks.

  • URM How to set default value in the "New Check-in" - "Folder" field

    Hello everyone,
    I'm trying to find out how to set the default value for the "folder" field in a check-in profile created using the Configuration Manager. If I browse to the folder in the "Browse Content -> Folders" menu and check-in a file inside the folder, it will fill this field automatically. I need to replicate this behavior using the "New Check-in" drop-down menu and selecting a profile, in other words, associate a Folder with a check-in profile.
    I know it was possible to do so in previous versions using the folders_g component, but I'm unable to figure out how to accomplish it with the new FrameworkFolders component.
    Any help is greatly appreciated.
    Thank you.

    Hello,
    It is working fine try this.
    PARAMETERS :
    y_p_list TYPE char32  AS LISTBOX VISIBLE LENGTH 22
                                  MODIF ID rsg. .
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR y_p_list.
      MOVE: text-200 TO y_wa_listbox-field.
      APPEND y_wa_listbox TO y_i_listbox.
      CLEAR y_wa_listbox.
      MOVE  text-203 TO y_wa_listbox-field.
      APPEND y_wa_listbox TO y_i_listbox.
      CLEAR y_wa_listbox.
      MOVE  text-210 TO y_wa_listbox-field.
      APPEND y_wa_listbox TO y_i_listbox.
      CLEAR y_wa_listbox.
      MOVE  text-211 TO y_wa_listbox-field.
      APPEND y_wa_listbox TO y_i_listbox.
      CLEAR y_wa_listbox.
      MOVE  text-204 TO y_wa_listbox-field.
      APPEND y_wa_listbox TO y_i_listbox.
      CLEAR y_wa_listbox.
      MOVE text-205 TO y_wa_listbox-field.
      APPEND y_wa_listbox TO y_i_listbox.
      CLEAR y_wa_listbox.
      MOVE text-206 TO y_wa_listbox-field.
      APPEND y_wa_listbox TO y_i_listbox.
      CLEAR y_wa_listbox.
      MOVE text-207 TO y_wa_listbox-field.
      APPEND y_wa_listbox TO y_i_listbox.
      CLEAR y_wa_listbox.
      MOVE text-208 TO y_wa_listbox-field.
      APPEND y_wa_listbox TO y_i_listbox.
      CLEAR y_wa_listbox.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
          retfield        = 'FIELD'
          dynpprog        = sy-repid
          stepl           = 1
          value           = ' '
          value_org       = 'S'
          display         = ' '
        TABLES
          value_tab       = y_i_listbox[]
        EXCEPTIONS
          parameter_error = 1
          no_values_found = 2
          OTHERS          = 3.
      IF sy-subrc <> 0.
      ENDIF.
      REFRESH y_i_listbox.

  • Default value for selection screen field

    Hi all,
      I am using LDB PNPCE. I want to give default value for field Personnel area on selection screen.
    How can I do it?
    Thanks
    Rahul

    Hi Rahul,
    In the INITIALIZATION event we can set the default values for selection screen fields.
    INITIALIZATION.
    loop at screen.
    if screen-name = 'S_MATNR-LOW'.
    CLEAR S_MATNR.
    s_matnr-low = '1234'.
    s_matnr-option = 'EQ'.
    s_matnr-sign = 'I'.
    append s_matnr.
    CLEAR S_MATNR.
    s_matnr-high = '5678'.
    s_matnr-option = 'EQ'.
    s_matnr-sign = 'I'.
    append s_matnr
    clear s_matnr.
    endif.
    endloop.
    Hope it helps.
    Mark if useful
    Regards,
    Saumya

  • How to display negative values in a screen field of a screen

    Hi All,
    Please let me know how to display negative values in a screen field of a screen.
    thanks

    Hi Kishore,
    You can do this method. In the screen , create a text field of CHAR instead fo creating an INT4 field.
    I have created a field of CHAR of name say TEXT.
    In the main program,
    declare a variable of the same name ie. TEXT.
    data: TEXT(5) TYPE C.
    In PBO, just assign the negative values.
    It will work.Since there is automatic conversion between character and integer data types, it will work for positive values as well.
    Regards,
    Sylendra.

  • BDC-How to get the value of the screen field

    Hi All,
    I am facing a problem while writing the BDC code for the XK02 transaction.
    Recording:
    We have recorded like this :after giving the values in the initial screen(vendor no and purchase group and selecting the purchasing data check box) and enter into the second screen and then click on alternative data icon.There we ll have set of plants we have to check auto ordering (by selecting the plant and click purchasing icon)for the plants which are in the given file.
    Problem:
    Suppose there are five plants(like 1,2,3,4,5) for a particular vendor but we are having only three plants in the file for which auto ordering check has to be done.The problem is that its doing auto ordering check for the first three plants(1,2,3) in the transaction.But  in the file we are having Plants like (1,3,5).How to get the screen field value directly or is there any other way to resolve the problem?

    Dear Raja,
    You cannot get hold of screen values while running through the BDC Operation.
    Only way you can get the value --> populating an Internal Table from the Database Table.
    Regards,
    Abir
    Don't forget to award Points *

  • Setting Default Value to the Quantity Field in ML81n

    Hi Gurus,
    I have an assignment to set a default value of 1 to the quantity value when creating entry sheet. This is the process we go through before the point of setting the 1:
    1. Go ML81n and click on "Other Purchase Order" input some PO number and click enter.
    2. On the Menu --> Entry Sheet --> Create --> Empty Page
    3. At the bottom of the screen Click on "Service Sel", and click enter if a pop-up shows
    4. Now on the line item, select any row (1 or 2 or many). and Click on Services on top.
    So at this point when the new screen shows with the new Entry Sheet number, the line Items that comes up should all have a quantity of 1, and should be editable by the user before saving.
    How can i go about this. Which UserExit will do this or Enhancement Point. The screen field for this quantity is ESLL-MENGE.
    Thanks guys.
    Rewards, will be greatly reward.
    Edited by: Basil Balogun on Jul 7, 2008 11:03 PM

    Hi,
    Pls check out this Exit-
    package name ML-
    SRVESSR->EXIT_SAPLMLSR_010->Set Entry Sheet Header Data.
    For this in importing paramertes
    I _EKPO type EKPO in this we have MENGE field try to asign value 1 to this.
    First check the screen number of the popup screen for which you need to enter the MENGE valuein GUI status. Chck if this screen exit can be used by puting a break-point.
    And also try this screen exit for SRVEUSCR-
    EXIT_SAPLMLSR_020-Transfer of Data to Entry Sheet User Screen
    EXIT_SAPLMLSR_021-Adoption of Data from Entry Sheet User Screen
    SAPLMLSR-Screen exit at 0400 subscreen.
    Reward if helpful.
    Best Wishes,
    Chandralekha
    Edited by: Chandralekha on Jul 8, 2008 6:41 AM
    Edited by: Chandralekha on Jul 8, 2008 6:43 AM

  • How to set default value in Profit Center field of Tcode F-02.

    Hi!
    Is it possible to set a default value for 'Profit Center' field in t.code F-02? Is there a way wherein the value will be copied in reference to the entered Business Area?
    For example, if during parking/posting of document, user input a value of 300 in the Business Area field, the system will automatically put 300 in the Profit Center field. Is there a way to do this?
    Hoping for your feedback.
    Thanks,
    April

    Hi
    Using the substitution this can be achieved.
    TC:GGB1
    Step-1: Prerequiste select the Company code for which this requirement is needed
    Step-2: In Substitution field, select the the "Profit center" field on selection of the field - system'll asks you -  How would you like to substfield BSEG-PRCTR ? with the 3 options
      i.constant value
      ii.exit
      iii.Field-Field assignment
    Select the 3rd option on selecting 3rd option before going to save that substitution it'll ask you to input which field should input the field BSEG-GSBER:Business area
    Step-3: activate the above substitution in TC:OBBH
    With the above settings whenever any value inputs in Business are field then the same value will be substituted in the Profit center field.
    Note: Make sure in all FSG - business area & profit center having the field status optional
    Can you tell me onething why this requirement has came ? Is business area and profit center are same in number and prupose
    regards
    Ramana
    Edited by: Ramana on Jan 8, 2008 9:33 AM

  • How can i assign value to the certain field in dynmic table ?

    i have created a dynmic table .now i want to assign value to the certain field,how can i do that?
    for eg,
    <dyn_table> contains fields of  name age ,now i want assign 'jack' to this internal talbe's field name ,

    Hi,
    try this:
    FIELD-SYMBOLS: <GT_ITAB>      TYPE TABLE,
                   <GS_ITAB>,
                   <FS>, <FS1>.
    DATA: GT_DATA   TYPE REF TO DATA.
    DATA: GS_DATA   TYPE REF TO DATA.
    START-OF-SELECTION.
      CREATE DATA GT_DATA TYPE TABLE OF PA0002.
      ASSIGN GT_DATA->*   TO <GT_ITAB>.
      CREATE DATA GS_DATA    LIKE LINE OF <GT_ITAB>.
      ASSIGN GS_DATA->*      TO <GS_ITAB>.
      ASSIGN COMPONENT 'NACHN' OF STRUCTURE <GS_ITAB> TO <FS>.
      <FS> = 'Smith'.
      ASSIGN COMPONENT 'VORNA' OF STRUCTURE <GS_ITAB> TO <FS>.
      <FS> = 'Paul'.
      APPEND <GS_ITAB> TO <GT_ITAB>.
      ASSIGN COMPONENT 'NACHN' OF STRUCTURE <GS_ITAB> TO <FS>.
      <FS> = 'Jones'.
      ASSIGN COMPONENT 'VORNA' OF STRUCTURE <GS_ITAB> TO <FS>.
      <FS> = 'Martin'.
      APPEND <GS_ITAB> TO <GT_ITAB>.
      LOOP AT <GT_ITAB> INTO <GS_ITAB>.
        ASSIGN COMPONENT 'NACHN' OF STRUCTURE <GS_ITAB> TO <FS>.
        ASSIGN COMPONENT 'VORNA' OF STRUCTURE <GS_ITAB> TO <FS1>.
        WRITE: / <FS>, <FS1>.
      ENDLOOP.
    Regards, Dieter

  • How to add default value to the Exclude single value in selection screen..

    Hi Experts,
    i have searched in sdn, but not able to get proper results,
    in my report i have a selection screen, in that there is a Select-option like status, for this status i need to exclude '02'
    for this i need to add the default value under exclude singale values option, not in lower and upper limit.
    can anyone help me...
    Regards,
    Sudha.
    Moderator message: please search for available information/documentation before asking, don't just claim you did.
    Edited by: Thomas Zloch on Oct 27, 2010 2:50 PM

    Hi,
    you can use the function module SELECT_OPTIONS_RESTRICT .
    This function module simplifies the handling of SELECT-OPTIONS on the selection screen by restricting possible selection options and signs.
    By calling this function module, you can restrict the number of selectio options available for the chosen selection field. You can also disable the function allowing users to enter values to be excluded from the selection (SIGN = 'E').
    Regards,
    S.Velsankar

  • How to set default value to the variable !!!

    Experts,
    I have created a variable ZDATE, which is in variable entry screen of the query. and this variable is mendatory .
    Now, i want to put default value of this variable ( Which can be done from the Variable Properties screen , on the Default Values Tab )
    But , thru there i can only put selected value. my requirement is to show system date - 1 ( Previous date )
    how do i get that ?
    Thanks

    Hi,
    You would need to write a variable exit under I_STEP = 1 to get the previous day populated on your variable screen.
    Regards,
    Murali.

  • How to set default values in the PO feilds

    Hello,
    Can please somone let me know how can I default a particular tax code "X" on a Purchase Order at the item level in the invoice tab..
    Any help would be greatly appreciated....
    Thanks

    Dear ,
    You can set it in the info record > Purchasing Organization data 1. In standard customizing,the default value for tax exist for LIV module in SPRO-Materials ManagementLogistics Invoice VerificationIncoming InvoiceMaintain Default Values for Tax Codes
    Regards,
    w1n

  • How to have default value in an output field?

    Hi,
    I am working on module pool program and want the initial value for a numeric data to appear by default in an Input/Output field.
    How do I achieve the same?
    Thanks.

    Hi,
    You have to write the code in PBO module.
    or In the field attributes if check the from dictionary option it will display initial value by default.

Maybe you are looking for

  • My Character Report don't send printer codes to the printer

    Hi every one ! I am developing an ASCII report, I made my own prt file for my printer, I defined my width ... etc. I want to print bold characters in the printer and configured the printers code in the report (before and after), I put the "codes" in

  • No weblogic server was found running on the specific port.

    Hello, While trying to target/connect to the weblogic server from Grid control 10.2.0.5,I'm getting the below error. 1.Added the connection filter in the weblogic console to allow connections only from the grid control's host 2.But while trying to co

  • Is it possible to have an Infinite canvas drawing program

    Hi Is it possible to have an Infinite canvas in a drawing program? The sort of Features that make sense would be Zoom In and out All other basic drawing tool capabilities

  • Tolerance limit for physical inventory

    hai In physical inventory there a option for tolerance limit setting for A.. document level B. item level 1. my question is this tolerance limit setting is for "QUANTIY BASED"  (OR) "VALUE BASED " 2.in my problem  the count is exceed the tolerance li

  • Problem with disappearing apps from i touch

    We have 3 i-touches and 1 i-pad running from one i-mac computer, and all via the same Apple ID.  I the past few months several apps that we downloaded (CAMRA Good Beer Guide and KIK) have disappeared from one of the i touches without explaination (no