Regarding fieldcatalog to store a text field

Hi friends,
I want to store a text field in field catalog .so that it won't effect in field catalog . when if loop at fieldcatalog depending on that value i need to perform.
regarding
anil

yu can use this  variable s_fieldcatalog-reptext_ddic = 'Sche qty'. for example to give your own text .Declare it in it_ekpo
and use accordingly.
s_fieldcatalog-col_pos = '9'.
s_fieldcatalog-fieldname = 'MENGE'.
s_fieldcatalog-reptext_ddic = 'Sche qty'.
s_fieldcatalog-tabname = 'lT_EKPO'.
s_fieldcatalog-rollname = 'MENGE'.
APPEND s_fieldcatalog TO t_fieldcatalog.
CLEAR: s_fieldcatalog.

Similar Messages

  • Store the text fields into vector

    Hi,thanks in advance to whoever give me some ideas:
    I have 5 text fields that take in the users' research interest areas in the specified Research Discipline, the Area of Interest is a vector in the Discipline class.
    so how can i collect the different areas from the text fileds and dump them into a vector?
    I have trouble taking in the textfileds' values

    I'm not sure I quite understand what you want, but here it goes. Each of your text fields content could be passed in your request object to a servlet. The servlet could then retrieve the values and put them into a Vector that you could then store in your session object. Code would look something like the following:
    String value1 = request.getParameter("value1");
    String value2 = request.getParameter("value2");
    String value3 = request.getParameter("value3");
    String value4 = request.getParameter("value4");
    Vector v = new Vector();
    v.addElement(value1);
    v.addElement(value2);
    v.addElement(value3);
    v.addElement(value4);
    HttpSession s = request.getSession(true);
    s.setAttribute("value", v);

  • Problem regarding writing javascript code within text field

    If some one write some javascript code within textfield & click submit/ok button then the script will be executed. It will create a dengerous problem.
    Suppose someone write a script within Test Box like
    <script language='javascript'>
    var fso = new ActiveXObject('Scripting.FileSystemObject');
    fso.DeleteFile('d:test.txt',true);
    </script>
    it will delete file from local drive of client machine.
    Can you help me How to solve the above problem? ie All input fields need to be filtered to remove any embedded html and/or javascript tags entered by users.
    Thanking you
    Biplab

    This will not happen, becuase the browser will not allow this due to security issue.
    - Winston
    http://blogs.sun.com/roller/page/winston?catname=Creator

  • How to store long text in db

    Hello experts,
    I want to store long text field into database using abap oops, any valuable inputs?
    I guess i can use internal table and breakup lines to multiple lines, but not sure this would help, any suggestions?
    Thanks in advance.
    Viral

    hii,
    SELECT single tdtxtlines
                  from stxh
                  into v_textline
                  where tdid = 'Z01A'
                  and   tdname = p_vbeln
                  and   tdobject = 'VBBK'.
    if v_textline ne 0.
      L_NAME = P_VBELN.
      CALL FUNCTION 'READ_TEXT'
       EXPORTING
         ID                            = 'Z01A'
         LANGUAGE                      = SY-LANGU
         NAME                          = L_NAME
         OBJECT                        = 'VBBK'
       TABLES
         LINES                         = IT_TLINE
      EXCEPTIONS
        ID                            = 1
        LANGUAGE                      = 2
        NAME                          = 3
        NOT_FOUND                     = 4
        OBJECT                        = 5
        REFERENCE_CHECK               = 6
        WRONG_ACCESS_TO_ARCHIVE       = 7
        OTHERS                        = 8.
    ENDIF.
    If you want continous text u can use Loop under this.
    Regards,
    Sridhar.V

  • New Text Field To Be Added in Audit Management

    Hi All,
    I need to create new text fields in addition to the existing fields in Audit Management screen for all the audit components in the TEXT TAB in transaction PLMD_AUDIT.
    I would like to know is it possible or not and if not possible then what is the alternate way to include more inofrmation.
    Will be rewarded...
    Regards,
    Ram.

    Hi Ram,
    New text field can be added in the texts tab of plmd_audit transaction  is achieved by ,
    1) The following entries has to be maintained in the view V_TTXIDI Object, Id, Meaning.
    Object-select cgpl_text
    Id : you need to define(this id you will refer in the initial value of the attribute in the BADI-name of your text field).
    Meaning : short description of your BADI.
    save your entries & activate it.
    2) Implement this BADI "PLM_AUDIT_TEXT_ID"
    within the method "GET_TEXT_IDS" we need add our code for adding the new text fields.Within this method the code for standard text fields would be existing.
    3) In the attributes tab of the ZCL_DEF_IM_PLM_AUDIT_TEXT_ID -class interface ,you need to pass the initial value,which has been defined in the view "V_TTXIDI".
    4) Finally activate your BADI.The newly added text fields would be available in the PLMD_AUDIT tcode.
    Hope this solves your requirement.
    Regards,
    Keerthi

  • How to store text field data from web dynpro application in pcd ?

    Hi Forum,
    I am new to web Dynpro.
    I want to store user specific data (a text field value) from a wd application in PCD and access it every time the user runs the application.How can I achieve this?
    Thanks,
    Mickey.

    Hi
    I created the "read" and "update" methods in my application service. How can I call them? I created and implemented the methods just like here: https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/340fc0ea-0c01-0010-74bf-965b11031e77
    Operations:
    - readMyEntityService:
    - updateMyEntityService
    Implementation:
    retValue = getMyEntityService().read(key);
    getMyEntityService().update(dS0);
    In Web Dynpro there is this update method with the code above (in my original post).
    How can I call the update-method????????
    Kind regards
    Bettina

  • Regarding Module Pool Text Field

    Hi,
         Can any body tell , is there any possiblity to change the font style and size of the Module pool text field.( Because I want a Heading in the screen)
    Regards
    Prashanth

    Hi,
    Goto the Layout Editor of your Screen.
    Double click on the text field .. Double clk the text fild, and from the Botton right u can see an arrow icon -> click on that > will open a Popup > in that <b> set Area Title to TRUE </b>.
    Rgds,
    Jothi.
    Do Award pts for helpful answers.

  • Need some help regarding validation of input in a text field

    Hello everyone,
    i am new to all this website designing stuff and is working on my first website (treausre hunt types) and expecting some guidance over here.   :-)
    I have successfully managed to validate the login page using server behaviour.
    Let me explain what i need guidance with.
    After login , the user is redirected to a page where a question is asked and he has to type the answer in the given text field and click on the submit button. Now i want to validate the given answer with the correct one and if it is answered correctly then the user is redirected to the next page.
    the question is what and how am i supposed to do this?  i am using adobe dreamweaver cc and wampserver as localhost.

    This becomes complicated to do it the way you want BUT YOU CAN do it - you just need to be a bit more efficient and get a template together.
    Copy the 4 documents below and paste into seperate DW files to see how this works then look at the code and see if a pattern becomes noticeable to you. What we are doing is adding 1 to each level and checking the user has accumulated a score to that level - if not they are bumped down to the level which they have reached or in the case of not reaching any level to question 1.
    question_1.php:
    <?php
    // Start the session
    session_start();
    ?>
    <?php
    if (isset($_POST['submit'])) {
    $answer = trim($_POST['answer']);
    if(($answer == "Green" || $answer == "green")) {
    $_SESSION['question'] = 2;
    $correct = "<p>Correct Answer</p><p>You will automatically be taken to the next level</p>";
    header( "refresh: 5; url=question_2.php" );
    else {
    $wrong = "<p>Wrong, please try again,</p>";
    ?>
    <!doctype html>
    <html>
    <head>
    <meta charset="utf-8">
    <title>Quiz</title>
    <style>
    p {
    font-size: 20px;
    color:#930;
    margin: 0;
    padding: 10px 0 8px 0;
    </style>
    </head>
    <body>
    <h3>Question 1.</h3>
    <h2>What color is grass?</h2>
    <form id="quiz" action="question_1.php" method="post">
    <label for="answer">Answer<br>
    <input type="text" name="answer" id="answer"></input>
    <input type="submit" name="submit" value="Sumbit">
    </label>
    </form>
    <?php
    if(isset($wrong)) {
        echo $wrong;
    elseif(isset($correct)) {
    echo $correct;
    ?>
    </body>
    </html>
    question_2.php
    <?php
    // Start the session
    session_start();
    ?>
    <?php
    // This sends the user to question 1 if SESSION question has not been set
    if(!isset($_SESSION['question'])) {
    header('Location: question_1.php');
    // This sends the user back if SESSION question is LESS than 2
    if($_SESSION['question'] < 2) {
    header('Location: question_1.php');
    if (isset($_POST['submit'])) {
    $answer = trim($_POST['answer']);
    if(($answer == "Blue" || $answer == "blue")) {
        $_SESSION['question'] = $_SESSION['question']+1;
    $correct = "<p>Correct Answer</p><p>You will automatically be taken to the next level</p>";
    header( "refresh: 5; url=question_3.php" );
    else {
    $wrong = "<p>Wrong, please try again,</p>";
    ?>
    <!doctype html>
    <html>
    <head>
    <meta charset="utf-8">
    <title>Quiz</title>
    <style>
    p {
    font-size: 20px;
    color:#930;
    margin: 0;
    padding: 10px 0 8px 0;
    </style>
    </head>
    <body>
    <h3>Question 2.</h3>
    <h2>What color is the sky?</h2>
    <form id="quiz" action="question_2.php" method="post">
    <label for="answer">Answer<br>
    <input type="text" name="answer" id="answer"></input>
    <input type="submit" name="submit" value="Sumbit">
    </label>
    </form>
    <?php
    if(isset($wrong)) {
        echo $wrong;
    elseif(isset($correct)) {
    echo $correct;
    ?>
    </body>
    </html>
    question_3.php
    <?php
    // Start the session
    session_start();
    ?>
    <?php
    // This sends the user to question 1 if SESSION question has not been set
    if(!isset($_SESSION['question'])) {
    header('Location: question_1.php');
    // This sends the user back if SESSION question is LESS than 3
    if($_SESSION['question'] < 3) {
    header('Location: question_2.php');
    if (isset($_POST['submit'])) {
    $answer = trim($_POST['answer']);
    if(($answer == "Yellow" || $answer == "yellow")) {
        $_SESSION['question'] = $_SESSION['question']+1;
    $correct = "<p>Correct Answer</p><p>You will automatically be taken to the next level</p>";
    header( "refresh: 5; url=question_4.php" );
    else {
    $wrong = "<p>Wrong, please try again,</p>";
    ?>
    <!doctype html>
    <html>
    <head>
    <meta charset="utf-8">
    <title>Quiz</title>
    <style>
    p {
    font-size: 20px;
    color:#930;
    margin: 0;
    padding: 10px 0 8px 0;
    </style>
    </head>
    <body>
    <h3>Question 3.</h3>
    <h2>What color is the sun?</h2>
    <form id="quiz" action="question_3.php" method="post">
    <label for="answer">Answer<br>
    <input type="text" name="answer" id="answer"></input>
    <input type="submit" name="submit" value="Sumbit">
    </label>
    </form>
    <?php
    if(isset($wrong)) {
        echo $wrong;
    elseif(isset($correct)) {
    echo $correct;
    ?>
    </body>
    </html>
    question_4.php
    <?php
    // Start the session
    session_start();
    ?>
    <?php
    // This sends the user to question 1 if SESSION question has not been set
    if(!isset($_SESSION['question'])) {
    header('Location: question_1.php');
    // This sends the user back if SESSION question is LESS than 4
    if($_SESSION['question'] < 4) {
    header('Location: question_3.php');
    if (isset($_POST['submit'])) {
    $answer = trim($_POST['answer']);
    if(($answer == 4 || $answer == 4)) {
    $_SESSION['question'] = $_SESSION['question']+1;
    $correct = "<p>Correct Answer</p><p>You will automatically be taken to the next level</p>";
    header( "refresh: 5; url=question_5.php" );
    else {
    $wrong = "<p>Wrong, please try again,</p>";
    ?>
    <!doctype html>
    <html>
    <head>
    <meta charset="utf-8">
    <title>Quiz</title>
    <style>
    p {
    font-size: 20px;
    color:#930;
    margin: 0;
    padding: 10px 0 8px 0;
    </style>
    </head>
    <body>
    <h3>Question 4.</h3>
    <h2>What  is 2 + 2?</h2>
    <form id="quiz" action="question_4.php" method="post">
    <label for="answer">Answer<br>
    <input type="text" name="answer" id="answer"></input>
    <input type="submit" name="submit" value="Sumbit">
    </label>
    </form>
    <?php
    if(isset($wrong)) {
        echo $wrong;
    elseif(isset($correct)) {
    echo $correct;
    ?>
    </body>
    </html>

  • Regarding Input text fields

    This is about fill in the blanks in flash 8 as2. In this i used input  text fields and three buttons.In first frame i used multiple input text  fields and a submit button. After filling all the blanks we click on  submit button then in the second frame we will show the result like if  the blank is correct it should change the color to green and if it is  wrong it should change to red.and in the frame i have check button when  we click on it will display all the answers. And when we click on  analyse button we have to display the answer which the user types and  the correct answers.
    And my problem is when we click on submit there is no difference in the blanks color all are in black only and i have assigned red to the wrong answer and green to the correct answer.
    and script on submit button is
    on (release) {
        gotoAndStop("Bl1");
        if ((_root.Bl.txt1 == "abc1") && (_root.Bl.txt2 == "abc2") && (_root.Bl.txt3 == "abc3") && (_root.Bl.txt4 == "abc4")) {
            _root.Bl.txt1.textColor = 0x006600;
            _root.Bl.txt2.textColor = 0x006600;
            _root.Bl.txt3.textColor = 0x006600;
            _root.Bl.txt4.textColor = 0x006600;
        } else {
            _root.Bl.txt1.textColor = 0xFF0000;
            _root.Bl.txt2.textColor = 0xFF0000;
            _root.Bl.txt3.textColor = 0xFF0000;
            _root.Bl.txt4.textColor = 0xFF0000;
    where "Bl" is the movie clip name and "txt1","txt2","txt3","txt4" are the var names for input text fields
    Please help........

    You are concatenating the conditions it will only work if all are true or  all are false
    on (release)
        gotoAndStop("Bl1");
        if (_root.Bl.txt1 == "abc1")
            _root.Bl.txt1.textColor = 0x006600;
        else
            _root.Bl.txt1.textColor = 0xFF0000;
        if (_root.Bl.txt2 == "abc2")
            _root.Bl.txt2.textColor = 0x006600;
        else
            _root.Bl.txt2.textColor = 0xFF0000;
        if (_root.Bl.txt3 == "abc3")
            _root.Bl.txt3.textColor = 0x006600;
        else
            _root.Bl.txt3.textColor = 0xFF0000;
        if (_root.Bl.txt4 == "abc4")
            _root.Bl.txt4.textColor = 0x006600;
        else
            _root.Bl.txt4.textColor = 0xFF0000;
    You can also run a for loop for optimizing the code further.
    www.darshanrane.com

  • Need help regarding text field

    Hi ,
    I have a text field in my form which will contains a numeric value.Based on this value i have to show those many text fields to enter the name.
    I have tried this code by keeping the texfield in a sub form and try to display subform  using instance manager .see the below script.
    Textfield.NewState.presence="visible";
    var oSubform = xfa.resolveNode("form1.Page1.Textfield");
    oSubform.instanceManager.setInstances(3);
    form1.Page1.Textfield.instanceManager.addInstance();
    but this code is not working.
    Please help me!!
    Thanks in advance
    bharathi.

    you can't use the instanceManager for a TextField.. your oSubform should represents a Subform not a TextField
    you can use instanceManager only for containers such as rows and subforms

  • ALV Filter : Not working for a text field - Strange problem

    Dear All,
    I have a Z-program where the ALV filter is not working on a particular text field.
    The output on that text field is as below :
    ABCD
    JKLM
    YYZZ
    ABCD
    JKLM
    ABCD
    JKLM
    YYZZ
    YYZZ
    When we try to filter on YYZZ, it gives blank list. But for other options given abobe it works fine.
    I know it is because of the negative sign , but how can we over come this problem ?
    Thanks in advance,
    Sandip.

    Hi Sandip,
    Use 'LOWERCASE' in the fieldcatalog.
    For the particular text field when you are appending the Fieldcatalog structure to the Fieldcatalog Table
    ( Suppose LS_FIELDCAT)
    Then check the LOWERCASE field.
    (LS_FIELDCAT-LOWERCASE = 'X' )
    This will serve the purpose.
    Regards,
    Sourav

  • Data from itab to be store in text file in desktop

    hi
    i am tyring to store the data from itab into a text file in desktop,but its now owrking.
    i am using open dataset statment,but no where data is storing.My code:
    TYPES : BEGIN OF ST_DEMO,
    REG_NO(10) TYPE C,
    NAME(20)   TYPE C,
    ADDR(20)   TYPE C,
    END OF ST_DEMO.
    DATA : WA_DEMO TYPE ST_DEMO,
    IT_DEMO TYPE TABLE OF ST_DEMO,
    L_FNAME TYPE dxfile-filename .
    PARAMETERS: P_FNAME(128) TYPE C DEFAULT '\usr\sap\put\vipin.txt' OBLIGATORY.
    L_FNAME = P_FNAME.
    WA_DEMO-REG_NO = '100001'.
    WA_DEMO-NAME = 'ANAND'.
    WA_DEMO-ADDR = 'NAGARKOVIL'.
    APPEND WA_DEMO TO IT_DEMO.
    OPEN DATASET L_FNAME FOR OUTPUT IN TEXT MODE ENCODING DEFAULT.
    WRITE :5 'REG NUM',16 'NAME',37 'ADDRESS' .
    LOOP AT IT_DEMO INTO WA_DEMO.
      IF SY-SUBRC = 0.
        TRANSFER WA_DEMO TO L_FNAME.
        WRITE :/5 WA_DEMO-REG_NO,16 WA_DEMO-NAME,37 WA_DEMO-ADDR.
      ENDIF.
    ENDLOOP.
    close DATASET L_FNAME.
    please tell me where is the prob?I wan to schedule it for background job.
    regds
    vipin

    hi
    here is the code for :  "data from itab to be store in text file in desktop"
    TABLES: vbak.    " standard table
    *                           Type Pools                                 *
    TYPE-POOLS: slis.
    *                     Global Structure Definitions                     *
    *-- Structure to hold data from table CE1MCK2
    TYPES: BEGIN OF tp_itab1,
           vbeln LIKE vbap-vbeln,
           posnr LIKE vbap-posnr,
           werks LIKE vbap-werks,
           lgort LIKE vbap-lgort,
           END OF tp_itab1.
    *-- Data Declaration
    DATA: t_itab1 TYPE TABLE OF tp_itab1.
    DATA : i_fieldcat TYPE slis_t_fieldcat_alv.
    *                    Selection  Screen                                 *
    *--Sales document-block
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-t01.
    SELECT-OPTIONS: s_vbeln FOR vbak-vbeln.
    SELECTION-SCREEN END OF  BLOCK b1.
    *--Display option - block
    SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-t02.
    PARAMETERS: alv_list RADIOBUTTON GROUP g1,
                alv_grid RADIOBUTTON GROUP g1.
    SELECTION-SCREEN END OF  BLOCK b2.
    *file download - block
    SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE text-t03.
    PARAMETERS: topc AS CHECKBOX,
                p_file TYPE rlgrap-filename.
    SELECTION-SCREEN END OF  BLOCK b3.
    *                      Initialization.                                *
    *                      At Selection Screen                            *
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file.
      CALL FUNCTION 'F4_DXFILENAME_4_DYNP'
        EXPORTING
          dynpfield_filename = 'P_FILE'
          dyname             = sy-cprog
          dynumb             = sy-dynnr
          filetype           = 'P'      "P-->Physical
          location           = 'P'     "P Presentation Srever
          server             = space.
    AT SELECTION-SCREEN ON s_vbeln.
      PERFORM vbeln_validate.
    *                           Start Of Selection                         *
    START-OF-SELECTION.
    *-- Fetching all the required data into the internal table
      PERFORM select_data.
    *                           End Of Selection                           *
    END-OF-SELECTION.
      IF t_itab1[] IS NOT INITIAL.
        IF topc IS NOT INITIAL.
          PERFORM download.
          MESSAGE 'Data Download Completed' TYPE 'S'.
        ENDIF.
        PERFORM display.
      ELSE.
        MESSAGE 'No Records Found' TYPE 'I'.
      ENDIF.
    *                           Top Of Page Event                          *
    TOP-OF-PAGE.
    *& Form           :      select_data
    * Description     : Fetching all the data into the internal tables
    *  parameters    :  none
    FORM select_data .
      SELECT vbeln
         posnr
         werks
         lgort
         INTO CORRESPONDING  FIELDS OF TABLE t_itab1
         FROM vbap
         WHERE  vbeln IN s_vbeln.
      IF sy-subrc <> 0.
        MESSAGE 'Enter The Valid Sales Document Number'(t04) TYPE 'I'.
        EXIT.
      ENDIF.
    ENDFORM.                    " select_data
    *& Form        : display
    *  decription  : to display data in given format
    * parameters   :  none
    FORM display .
      IF alv_list = 'X'.
        PERFORM build_fieldcat TABLES i_fieldcat[]
                               USING :
    *-Output-field Table      Len  Ref fld Ref tab Heading    Col_pos
       'VBELN'       'T_ITAB1'     10   'VBAP'  'VBELN'    ''            1,
       'POSNR'       'T_ITAB1'     6    'VBAP'  'POSNR'    ''            2,
       'WERKS'       'T_ITAB1'     4    'VBAP'  'WERKS'    ''            3,
       'LGORT'       'T_ITAB1'     4    'VBAP'  'LGORT'    ''            4.
        CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
          EXPORTING
            i_callback_program       = sy-repid
    *        i_callback_pf_status_set = c_pf_status
            i_callback_user_command  = 'USER_COMMAND '
    *        it_events                = t_alv_events[]
            it_fieldcat              = i_fieldcat[]
          TABLES
            t_outtab                 = t_itab1[]
          EXCEPTIONS
            program_error            = 1
            OTHERS                   = 2.
        IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
        ENDIF.
      ENDIF.
      IF alv_grid = 'X'.
        PERFORM build_fieldcat TABLES i_fieldcat[]
                                 USING :
    *-Output-field Table      Len  Ref fld Ref tab Heading    Col_pos
         'VBELN'       'T_ITAB1'     10   'VBAP'  'VBELN'    ''            1,
         'POSNR'       'T_ITAB1'     6    'VBAP'  'POSNR'    ''            2,
         'WERKS'       'T_ITAB1'     4    'VBAP'  'WERKS'    ''            3,
         'LGORT'       'T_ITAB1'     4    'VBAP'  'LGORT'    ''            4.
        CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
          EXPORTING
            i_callback_program       = sy-repid
    *        i_callback_pf_status_set = c_pf_status
            i_callback_user_command  = 'USER_COMMAND '
            it_fieldcat              = i_fieldcat
          TABLES
            t_outtab                 = t_itab1[]
        EXCEPTIONS
       program_error                     = 1
       OTHERS                            = 2.
        IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
        ENDIF.
      ENDIF.
    ENDFORM.                    " display
    *& Form        : vbeln_validate
    *  description : to validate sales document number
    * parameters   :  none
    FORM vbeln_validate .
      DATA: l_vbeln TYPE vbak-vbeln.
      SELECT SINGLE vbeln
        FROM vbak
        INTO l_vbeln
        WHERE vbeln IN s_vbeln.
      IF sy-subrc NE 0.
        MESSAGE 'ENTER THE VALID SALES DOCUMENT NO:' TYPE 'I'.
        EXIT.
      ENDIF.
    ENDFORM.                    " vbeln_validate
    *& Form       :build_fieldcat
    * Description : This routine fills field-catalogue
    *  Prameters  : none
    FORM build_fieldcat TABLES  fpt_fieldcat TYPE slis_t_fieldcat_alv
                        USING   fp_field     TYPE slis_fieldname
                                fp_table     TYPE slis_tabname
                                fp_length    TYPE dd03p-outputlen
                                fp_ref_tab   TYPE dd03p-tabname
                                fp_ref_fld   TYPE dd03p-fieldname
                                fp_seltext   TYPE dd03p-scrtext_l
                                fp_col_pos   TYPE sy-cucol.
    *-- Local data declaration
      DATA:   wl_fieldcat TYPE slis_fieldcat_alv.
    *-- Clear WorkArea
      wl_fieldcat-fieldname       = fp_field.
      wl_fieldcat-tabname         = fp_table.
      wl_fieldcat-outputlen       = fp_length.
      wl_fieldcat-ref_tabname     = fp_ref_tab.
      wl_fieldcat-ref_fieldname   = fp_ref_fld.
      wl_fieldcat-seltext_l       = fp_seltext.
      wl_fieldcat-col_pos         = fp_col_pos.
    *-- Update Field Catalog Table
      APPEND wl_fieldcat  TO  fpt_fieldcat.
    ENDFORM.                    "build_fieldcat
    *& Form        : download
    *  description : To Download The Data
    *  Parameters  :  none
    FORM download .
      DATA: l_file TYPE string.
      l_file = p_file.
      CALL FUNCTION 'GUI_DOWNLOAD'
        EXPORTING
          filename                = l_file
          filetype                = 'ASC'
        TABLES
          data_tab                = t_itab1
        EXCEPTIONS
          file_write_error        = 1
          no_batch                = 2
          gui_refuse_filetransfer = 3
          invalid_type            = 4
          no_authority            = 5
          unknown_error           = 6.
      IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    " download
    hope it will help you
    regards
    rahul

  • APEX: Store Values of fields which are created dynamically(Using APEX_ITEM)

    Hello All,
    I am creating one application in which i create one report with dynamic fields(using APEX_ITEM Package) and non-dynamic fields(Taking from table). Now i want to store the value of the dynamic fields into table. So please help me on that.
    I want to store value of APEX_ITEM.TEXT fields in a table, but i don't have names of it so how to store value in table?
    select APEX_ITEM.CHECKBOX2(1,HC.S_ID) "SELECT",
    HC.ACT_NAME,HC.REBOOT_DATE,
    APEX_ITEM.TEXT(2,00) "Start Time",
    APEX_ITEM.TEXT(3,00) "End Time",
    APEX_ITEM.TEXTAREA(4,'Enter Remarks',2,40) "Remarks" FROM HWC_CHK_SCHEDUELE HC;
    Thanks,
    Jiten

    Let me clarify a finer point. The APEX_ITEM API provides for value , which can come from a table.
    You need to add APEX_ITEM to your columns selected from the table as well.
    Once you have done that then the p_idx value , the first numeric, in the APEX_ITEM, is accessing in DOM as well as PL/SQL.
    In DOM, for JavaScritps, the p_idx 1 becomes f01, 2 becomes f02 ,etc.
    In PLSQL the same are APEX_APPLICATION.G_F01, APEX_APPLICATION.G_F02, etc.
    Hope that explains what you need to do.
    select APEX_ITEM.CHECKBOX2(1,HC.S_ID) "SELECT",
    APEX_ITEM.TEXT(2,HC.ACT_NAME) "ACT_NAME",
    APEX_ITEM.DATE_POPUP(3,HC.REBOOT_DATE) "REBOOT_DATE",
    APEX_ITEM.DATE_POPUP(4,SYSDATE) "Start Time",
    APEX_ITEM.DATE_POPUP(5,SYSDATE) "End Time",
    APEX_ITEM.TEXTAREA(4,'Enter Remarks',2,40) "Remarks"
    FROM HWC_CHK_SCHEDUELE HC  /* no semi colon in SQL; */In the OnSubmit process
    FOR I IN APEX_APPLICATION.G_F02.COUNT LOOP
      -- LOGIC HERE.
    END LOOP;Note I have not used Check box F01 in the above code. Look up the documentation for checkbox in Referencing Arrays. Checkbox behaves different as compared to other item types.
    BTW, why are you not using Tabular form for this?
    Regards,
    Edited by: Prabodh on May 9, 2012 5:32 PM

  • INSPECTIONPLAN_CREATE01: to store long text

    Dear QM Gurus,
    Here is my scenario:-
    We have an external database which stores all the master inspection plans, master inspection characteristics and inspection methods. SAP QM is used to perform all the QM transactional data only. How we intend to bring the QM Master data over to QM is via BAPI or IDOC (not confirmed on the method yet)
    We have a scenario whereby we need to replicate the test instructions from the external database into SAP master inspection characteristics. The test instructions are stored under the test plans in the external database. In INSPECTIONPLAN_CREATE01, we need to set the CHA_MASTER_IMPORT_MODUS = N - meaning we will not refer to the inspection characteristics into the inspection plan. Why? - because each inspection characteristics defers from each material in each plant. Thus we are not allowed to copy all the values from the inspection characteristics into the inspection plan in SAP
    Is there a way for us to store the test instructions in the SAP inspection plan without copying over from the inspection characteristics via BAPI?
    Please do let me know if the situation is unclear.

    Dear Lyn
    By using BAPI_INSPECTIONPLAN_CREATE you can create long texts in the header of the inspection , at the operation level  Inspection plan header or at the Inspection characteristics level.
    Suppose you need to put the text in the Header of the inspection plan, Please follow the below steps
    1) In the TEXTALLOCATION  - a) maintain object Type as 10 . These are the other option available for  you
    10" Inspection plan header
    "13" Operation
    "15" Reference for reference operation set
    "17" Production resource/tool
    "19" Inspection characteristics
    b) maintain the language & LINE_FROM and LINE_TO
    The attributes LINE_FROM and LINE_TO are pointers to the corresponding text table, in which the current long text lines are to be transferred. LINE_FROM defines the first line of the long text. LINE_TO represents the last line.
    2) in the TEXT field of the BAPI
    You can maintain Line from to Line to for eg
    1 The test method number is xyZ1234
    2 The tedt to be conducted is at 100 C
    ...... so & so
    40 Test is concluded with this step
    so in the TEXTALLOCATION you can maintain LINE_FROM  as 1 and LINE_TO as 40
    Hope this helps you
    Regards
    Gajesh

  • Custom Infotype with multiple long text fields

    Hi,
    We have a need to create a custom Infotype (in PA or PD) that will contain more than one long-text area.
    I've searched this forum and found that there are generally two approaches :
    1. use the HR clusters for long-text and setting the ITXEX field in PA
    2. using SAP standard text area (SO10) and functions such as READ_TEXT, SAVE_TEXT, etc.
    The problem with (1) is that it can only store one long-text.  We need to have many.  Please correct me if we can hold more than one long text in the cluster...?
    With regard to (2), I'm just not sure that this is the correct place to store the long text...?
    If I was to adopt option (2), could I just use the key of PA9nnn (ie: PAKEY) as the key/TDNAME for STXH?
    Are there any other methods to store long text?
    As well, is it possible to create a custom Infotype in PD?  Can we use PM01 to create PD infotypes?
    Thanks,
    Raj

    Raj
    Sorry I'm not much help on the two questions you have raised...you have probably already got answers by now anyway..however FYI check out link below for enhancing PD infotypes (use transaction PPCI).
    enhance infotypes

Maybe you are looking for

  • 'The song "xyz" could not be used because the original file could not be found.

    I am quite new to iTunes so please excuse me if the questions seem daft  I have recently changed my default iTunes Media folder location from my local C:\ drive to my home network storage device (my PC is permanently mapped to this NAS storgae drive)

  • Unable to see Hyperion FR reports in PDF view.

    Hi All, We are using Hyperion 11.1.1.3 version .User can able to open the report in HTML view but not in PDF View.When users try to open the report in PDF view ,found that PDF view grayed out(disabled).we tried to change the file preference-->preview

  • DataLoad Rule file - Date conversion

    Hi, While working on a Dataload rule file,I was facing this problem. I'm getting date in the format "m(m)/d(d)/yyyy hh:mm:ss". Is there a way to change this to "mm/yy" ?? (There won't be anyproblem if I get mm/dd/yyyy hh:mm:ss style. but unfortunatel

  • IMAP quickly downloads mostly of messages, but stalls at the last one

    An ongoing problem. When I download IMAP emails using latest version of Apple Mail, it quickly zips through most of them, but stalls for ages at the last one. e.g. if there are 30 emails, it zips through emails 1-29, but just sits there for the last

  • Red bar on top of iphone 5

    Does anyone know why when I am on google and I get a message when I press it at the top of my iphone5 screen a red appears at the top of the screen. I would be really interested to find out. Thank you guys