Problem with at line-selection

hi mates
i have written a interactive report program, when i click the hotspot in the basic list the event at line-selection is not getting triggered insead my at user-command is geting executed. is there a sequence that i need to follow?. below is my code. thanks in advance.
tables: vbak.
selection-screen begin of block b1 with frame title t1.
  select-options: salesdoc for vbak-vbeln.
selection-screen end of block b1.
types: begin of vbak_ty,
       vbeln type vbak-vbeln,
       erdat type vbak-erdat,
       ernam type vbak-ernam,
       end of vbak_ty.
types: begin of vbap_type,
       vbeln type vbap-vbeln,
       posnr type vbap-posnr,
       matnr type vbap-matnr,
       charg type vbap-charg,
       end of vbap_type.
types: begin of vbap_ty,
       posnr type vbap-posnr,
       matwa type vbap-matwa,
       arktx type vbap-arktx,
       end of vbap_ty.
data: vbap_wa type vbap_type,
      vbap_it type table of vbap_type,
      vbak_wa type vbak_ty,
      vbak_it type table of vbak_ty,
      vbap_wa1 type vbap_ty,
      vbap_it1 type table of vbap_type,
      fname(20),fvalue(10).
initialization.
       t1 = 'enter sales doc header'.
start-of-selection.
  set pf-status 'VA01'.
  SELECT vbeln
         erdat
         ernam
         from vbak into table vbak_it
         where vbeln in salesdoc.
   if sy-subrc = 0.
   loop at vbak_it into vbak_wa.
     write: /25 vbak_wa-vbeln hotspot,
             50 vbak_wa-erdat,
             75 vbak_wa-ernam.
     hide vbak_wa-vbeln.
     clear vbak_wa-vbeln.
     endloop.
     ELSE.
       message e000(01) with 'no records found '.
       endif.
    at line-selection.
      case sy-lsind.
        when '1'.
          perform headerdata.
        when '2'.
          perform itemdata.
       endcase.
  at user-command.
    case sy-ucomm.
      when 'ITEMDATA'.
      get cursor  field fname value fvalue.
      if fvalue = 'vbap_wa-vbeln'.
         perform itemdata.
       else.
         message e000(03) with 'click only on hotspots'.
       endif.
      when 'SALEOR'.
       get cursor field fname value fvalue.
       if fvalue = 'vbak_wa-vbeln'.
        set parameter id 'AUN' field fvalue.
        call transaction 'VA01' and skip first screen.
       else.
         message e000(04) with 'click only on hotspots'.
       endif.
    endcase.
    form headerdata.
    set pf-status 'HEADER'.
    select vbeln
           posnr
           matnr
           charg
           from vbap into table vbap_it
           where vbeln = vbak_wa-vbeln.
      if sy-subrc = 0.
   loop at vbap_it into vbap_wa.
     write: /25 vbap_wa-vbeln hotspot,
             50 vbap_wa-posnr,
             75 vbap_wa-matnr,
             90 vbap_wa-charg.
     hide vbap_wa-vbeln.
     clear vbap_wa-vbeln.
     endloop.
     else.
       message e000(02) with ' no data found'.
       endif.
       endform.
    form itemdata.
         select vbeln
           posnr
           matwa
           arktx
           from vbap into table vbap_it1
           where vbeln = vbap_wa-vbeln.
  if sy-subrc = 0.
   loop at vbap_it1 into vbap_wa1.
     write: /25 vbap_wa1-posnr,
             75 vbap_wa1-matwa,
             90 vbap_wa1-arktx.
      endloop.
       else.
       message e000(02) with ' no data found'.
       endif.
       endform.
REGARDS
MANO

AT LINE-SELECTION.
Effect
This statement defines an event block whose event is triggered by the ABAP runtime environment during the display of a screen list - provided the scren cursor is on a list line and you select a function using the function code PICK. Through the definition of this event block, the standard list status is automatically enhanced in such a way that the function code F2 and, with it, the double-click mouse function is linked up to the function code PICK.
Note
If the function key F2 is linked with a function code different than PICK, each double click will trigger its even, usually AT USER-COMMAND, and not AT LINE-SELECTION.
Example
This program works with the standard list status. A line selection with the left mouse key causes the event AT LINE-SELECTION and creates details lists.
REPORT demo_at_line_selection.
START-OF-SELECTION.
  WRITE 'Click me!' COLOR = 5 HOTSPOT.
AT LINE-SELECTION.
  WRITE: / 'You clicked list', sy-listi,
         / 'You are on list',  sy-lsind.
  IF sy-lsind < 20.
    SKIP.
    WRITE: 'More ...' COLOR = 5 HOTSPOT.
  ENDIF.
The above sample program works with the standard list status Since your program has the PF-status set, i think AT LINE-SELECTION will not work. So do use AT USER-COMMAND to capture the "PICK" event.
Hope this helps.
Thanks
Balaji

Similar Messages

  • Problem in AT LINE SELECTION event

    Hi All,
    I have a problem in AT LINE SELECTION event.
    I have an interactive report.
    In the report after selection on Selection Screen
    i have to show some totals.
    Now when I click on the no wgich is shown against the total
    the report should further drill down on the details
    like showing Order No,Material Description etc.
    Breakdown totaling qty of ASOu2019s against u2018Kit delivery areau2019 column
       = 100
    Breakdown totaling qty of ASOu2019s against u2018Kit req timeu2019 column  = 100
    Breakdown totaling qty of ASOu2019s against u2018delivered byu2019 column  
      KSINGH    1.
      BJALLOS  5.
    Breakdown totaling qty of ASOu2019s against u2018Kit req dateu2019 column
    Now my problem is that first    two breakdowns of total are constant.
    But as you can see afainst Delivered By and against Date it can be dynamic.
    In first two cases since i Knew there positioning in the screen i show them using sy-lilli.
    But how to show for other two totals.
    Please help me on this with some code example if you have.
    Thanks in Advance,
    Saket.

    hello saket,
    i m not really clear with ur problem,
    still i can tell u hide the all the fields in
    start-of-selection,that u gonna required in at line selection,
    and then u can use them to total or for displaying corresponding data.

  • F-32 : Problem with Open Item selection

    Hi,
    We have a strange problem with open Item selection for customer clearing in t-code F-32
    In My QA system
    if I input spl GL indicator ="*" and uncheck Normal OI tick,
    the system selects all open items,
    (those with spl GL indicator and those without spl GL indicator)
    In My Dev system
    If I input spl GL indicator ="*" and uncheck Normal OI tick
    the system does not select any open items,
    Please let me know which setting controls this behaviour ?
    Regards
    Sachin

    Hello,
    Check your data in FBL5N for the option "Special GL Transactions". There could be that there is no data in the system with SPECIAL GL TRANSACTIONS.
    In F-32, there is no value like *
    You need to input right Special GL Indicator. "*" will not work here.
    I am sure in both the systems if you put "*" and UNTICK your normal transaction, you will NOT get any items to clear.
    Please DOUBLE CHECK whether you have unticked normal transaction.
    Regards,
    Ravi

  • WRT160N - problem with on-line games and downloading

    Hi,
    Several months ago I bought a WRT160N router and I have a strange problem.
    When I play online games, such as QL, and someone else will start downloading from the Internet, from time to time about 10 sec I have 999 ping
    I turned on in the background ping to the router, and from time to time about 10 sec there are 2-3 ansewers with 1900-2000 ms.
    I tought that when I buy router with N-mode everything will work better, and there will be no problems with on-line gaming.
    Is there any way to fix this problem??

    I checked now and even no one is downloading there is the same problem.
    I checked on other router and it works fine.
    Next problem is when I browse youtube and play several films simultaneously, suddenly there are no responses from router, when I close them, and wait for a moment the responses are back.
    Whether anyone had similar problem??

  • Getting error of Defining an internal table with header line, SELECT-OPTIO

    Hi all,
    i have a coding for my smart form,In this coding i have define an structure which being used,but when i execute it it give me
    error of Defining an internal table with header line, SELECT-OPTIONS, and RANGES is not allowed within a structure.Even tough you can see that in  my coding im not using SELECT-OPTION or RANGES,but can't understand why it gives me this error.
    Following are the code:
      DATA: BEGIN OF traptab OCCURS 50.
            INCLUDE STRUCTURE mseg.
      DATA: vgart LIKE mkpf-vgart,
            blart LIKE mkpf-blart,
            blaum LIKE mkpf-blaum,
            bldat LIKE mkpf-bldat,
            budat LIKE mkpf-budat,
            cpudt LIKE mkpf-cpudt,
            cputm LIKE mkpf-cputm,
            aedat LIKE mkpf-aedat,
            usnam LIKE mkpf-usnam,
            tcode LIKE mkpf-tcode,
            xblnr LIKE mkpf-xblnr,
            bktxt LIKE mkpf-bktxt,
            frath LIKE mkpf-frath,
            frbnr LIKE mkpf-frbnr,
            wever LIKE mkpf-wever,
          END OF traptab. 
    Thanks & Regards,
    sappk25

    thanks

  • HT1338 Problem with MAIL, when select names that start with "E" the mail freeze. Can't fix it.

    Problem with MAIL, when select names that start with "E" the mail freeze. Can't fix it.

    Now I checked the materials that I got from AT&T Yahoo and
    port 25 is used as the outgoing mail port, 110 for incoming.
    This is for the POP type account provided by AT&T, not necessarily for an email account and SMTP server not provided by AT&T.
    Sounds like AT&T blocks using an SMTP server that is outside of their network or not provided by AT&T on Port 25.
    Try the following first.
    Go to Mail > Preferences > Accounts and under the Account Information tab for your .Mac account preferences at the SMTP server selection, select the Server Settings button below for the .Mac SMTP server.
    Enter 587 in place of 25 in the Server Port field and when finished, select OK to save the changed setting.
    If this doesn't work, we will go to plan B.

  • Intermittent problem with the line

    I have an intermittent problem with my line which crackles or you miss parts of a conversation because voices spoken or listened to keep coming and going all the time or the phone cuts out altogether
    Telephone the help line which said that the line was OK at that moment as they did the other time I called keeps on happening on a daily basis every time we get a call.
    Next door neighbour and other neighbours around this close all linked to the same local bt or open reach cabinet all tell me they have the same problem.
    Neighbours called their own phone company who rent the line off of BT who got an open reach engineer out the next day and found that the local exchange or cabinet next to the house across the road from me all the phone line coverings have corroded away and that the wires are all damaged and corroding away or rotting away.
    So the local road (culdisack) has to be dug up and the exchange and wires have to be replaced from that junction box to the next junction box or exchange, what i want to know is when will this be done as all the neighbours and i have been reporting it to BT for ages but it was not till next door got their company to investigate was the problem found.
    How long till we have to wait for a repair and better lines back to a good service, Months, years. when?
    It would not be so bad but i have a lifeline connected to my phone so if i am in trouble it calls for help but with the fault with the line half the time it cannot get a single message or call out and before now i have been left on the floor for ages before someone came back home to get me off the floor as the box just said the phone line was disconected and could not get a dial tone or call out.
    Tim

    If you would like to contact one of the UK based BT Care Team who moderate this forum, they should be able to find out what is going on.
    They can be contacted using this link BT Care Team
    They normally respond by phone or e-mail, within three working days, however you should get an immediate confirmation, with a tracking number.
    There are some useful help pages here, for BT Broadband customers only, on my personal website.
    BT Broadband customers - help with broadband, WiFi, networking, e-mail and phones.

  • X-Fi Notebook has a problem with headset/line-in

    0X-Fi Notebook has a problem with headset/line-in` First the basics:
    -HP Pavillion dv6000
    -Intel Core 2 Duo @ .83 GHz
    -Windows Vista Home and Student (SP) 32 bit
    -3 GB RAM
    Ok, now the problem:
    -Ever since I got my Sound Blaster X-Fi card for this past christmas, I've had a problem with using the headset/lin-in port on it. Its only now that it's gotten to be a big enough irritation for me to need to fix it. I went to play some BF2 and hook up my earphone/microphone combo. The problem is, that the default recording device "Line-in" doesn't detect any sound when I have it plugged in. Further more, when I change it to "SB X-Fi micropone" it does detect my voice, but its on some kind of feedback loop, because it then transmits whatever the mic picks up onto my speakers/headphones/whatever I have plugged into it as an output. Its almost like they have the "line-in" and "microphone" functions either switched or blended into one. I did a complete reinstall of the drivers and software, but no luck. Any suggestions would be much appreciated.
    Thanks guys

    Hi,
    What I mean is the microphone jack on your x-fi notebook. since you are saying you can hear yourself when you switch the recording source to microphone, I would assume that you have plugged in a microphone into your x-fi notebook. You should check if there is a microphone control on your volume mixer and whether it is unmuted if there is one. There are many sound card which allows for the microphone audio to be heard on the speaker output if the microphone source is unmuted.
    Message Edited by flipflop on 03-29-2009 09:03 [email protected]

  • Problems with horizontal lines on the iMac. Someone knows the solution?

    For several months my Imac has horizontal lines have been growing. Problems with horizontal lines on the iMac. Someone knows the solution?

    You have 14 days to return the computer w/no questions asked.  Plus you have 90 days of FREE phone tech support on top of your standard 1 year warranty unless you also purchased AppleCare which gives you an additional 2 years of coverage plus FREE phone support.
    Strongly suggest that you take FULL advantage of the above before it runs out.  Let Apple deal w/the problems.
    That being said, no new Mac comes w/Snow Leopard which your profile confirms you have.
    Mac OS X (10.6.8)

  • Problem with align and Selection Tool.

    This is a weird problem which I cannot explain at all.
    I am using AI CS3 with Windows XP.
    I am having this completely random problem with the selection tool and align pallette I cannot explain.
    I have a group of objects and groups of objects I am trying to use the align pallette on.
    Sometimes when I select all of the items I want to align, either by shift-clicking each one, or by drag-selecting them I am getting a random behavior where sometimes the align button will move all of the objects COMPLETELY off of the artboard, all the way to the edge of the working area and beyond into the grey area you cannot see.
    Normally, this would be caused by a stray point somewhere way off-screen or some other cleanup oriented thing on my part. However in this case, the behavior is random and does not happen every time I hit the align button.
    Sometimes it takes items within my grouped objects (lines of text) and moves THEM completely off the work area, leaving the other items in the groups in place. Sometimes the bounding box when I drag-select the items will stretch extremely far off of the work area.
    I have even dragged the extra large bounding box, bringing the edge that was once way off screen onto the work area, in outline view, in hopes of finding the stray point or object that could be causing this. However NOTHING appears that can be causing the align to throw all of my objects off-screen.
    The random nature of this behavior and the way it sometimes affects my text objects inside of groups leads me to believe it is a program bug and nothing I am doing.
    The behavior takes place regardless if I select by dragging or by shift-clicking, and is happening in more than one file, also randomly.
    Also, choosing "align to art board" vs. "align to crop area" does nothing to change this behavior.
    It is quite irritating. I've been using illustrator since v.88 so I have enough experience to know this is not normal.
    Any help with this one would be greatly appreciated.

    When this behaviour occurs, are perhaps guides included in your selection?

  • Problems with PreparedStatement when select restrict are byte params

    Hi,
    i have a problem trying to select information when the "select" has a byte restrict.
    The table in database is:
    CREATE TABLE `positions` (
    `PKID` int(10) unsigned NOT NULL auto_increment,
    `POSCODE` varbinary(30) NOT NULL,
    `ISWTURN` binary(1) NOT NULL,
    `QTT_GAMES` int(10) unsigned NOT NULL default '1',
    PRIMARY KEY (`PKID`),
    UNIQUE KEY `UNIQ_POS` (`POSCODE`,`ISWTURN`)
    ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
    And the test code to get the qtt_games is :
    conn = DriverManager.getConnection (url,user,pwd);
    byte bcode[] = poscode.getByteArrayCode();
    // bcode is inserted ok in another preparedstatement...
    String query = "SELECT qtt_games FROM positions "+
    "WHERE poscode=? and iswturn=?";
    PreparedStatement pstmt = conn.prepareStatement(query);
    pstmt.setBytes (1,bcode);
    pstmt.setByte (2,poscode.getIsWhiteTurn()); //it returns a byte
    ResultSet rs = pstmt.executeQuery (query);
    When pstmt.executeQuery is reached, it's thrown the exception:
    com.mysql.jdbc.exceptions.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '=? and iswturn=?' at line 1
    at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:936)
    at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2870)
    at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1573)
    at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1665)
    at com.mysql.jdbc.Connection.execSQL(Connection.java:3170)
    at com.mysql.jdbc.Connection.execSQL(Connection.java:3099)
    at com.mysql.jdbc.Statement.execute(Statement.java:695)
    at app.server.bbdd.MYSQLBDManager.getGamesBasicInfo(MYSQLBDManager.java:942)
    at app.server.bbdd.MYSQLBDManager.main(MYSQLBDManager.java:1068)
    Can anybody tell me what's wrong?? I think the query is ok, but don't know what's happening with this...
    Lots of thanks.

    Hi,
    sorry, i know i've post this same message by error in "new to java" thread.... (i'm new in the forum... can i delete the wrong comment??)
    The SQLState is 42000 (syntax error), but it doesn't give me much information because i had already searched in google why can be the cause of it, but there are only a few comments about problems like this, without a solution...
    The column poscode in the table positions contains an array of bytes that codify a position in a chess board. I've to use this in the WHERE clause because i'm developing a chess game consulting project where there are millions of different positions and i've to get the games that have the same position in it's position history.
    The code to insert the positions is:
    query = "INSERT INTO positions VALUES "+
         "(null,?,?,default) "+
         "ON DUPLICATE KEY UPDATE qtt_games=qtt_games+1";
    pstmt = conn.prepareStatement(query,Statement.RETURN_GENERATED_KEYS);
    pstmt.setBytes(1,bcode);
    pstmt.setByte(2,poscode.getIsWhiteTurn());
    pstmt.executeUpdate();
    which works ok and positions can be seen from mysql browser, but i can't select them using the PreparedStatement..
    I have been searching a lot of information about this problem with no results... this is the why i posted this...
    Any help will be useful, thanks.

  • Problem with the default selection screen condition

    hi guys,
    I have got some problem with the default screen given by the PNP logical database, P0000 infotype automatically populated according to the condition given in default screen.
    Reg,
    Hariharan

    Don know what u r trying to acheive.
    1) when u have specified PNP in the logical databse field of attributes of program, the SAP wil proivde u default PNP screen and here u can also add ur paramters if u want.
    2) in the program u have to declare like
    INFOTYPES: 0000,0001. "Etc
    for all the infotypes u want to use in the program.
    3) it is the GET PERNR event which wil fil all the p0000 and p0001 (internal tables for al the infotypes declared via INFOTYPES syntax as shown above)
    4) after tht get pernr, u now have data in P tables and u can use it for further reporting.
    5) refer below dummy code -
    REPORT  ZPPL_PREVEMPLOYERS   message-id rp
                                 line-size 250
                                 line-count 65.
    *Program logic :- This Report is used to Download all the Previous
    * Employer (IT0023) records of the employees
    *eject
    *& Tables and Infotypes                                                *
    tables: pernr.
    infotypes: 0000,
               0001,
               0002,
               0023.
    *eject
    *& Constants                                                           *
    constants: c_1(1)       type c               value '1'   ,
               c_3(1)       type c               value '3'   ,
               c_i(1)       type c               value 'I'   ,
               c_x(1)       type c               value 'X'   ,
               c_eq(2)      type c               value 'EQ'  ,
               c_pl03       like p0001-werks     value 'PL03'.
    *eject
    *& Selection-Screen                                                    *
    parameters: p_file  like rlgrap-filename default 'C:TempABC.xls',
                p_test  as checkbox default c_x               .
    *eject
    *& Internal tables                                                     *
    * Internal Table for Output
    data: begin of t_output occurs 0    ,
           pernr like pernr-pernr       ,
           nachn like p0002-nachn       ,
           vorna like p0002-vorna       ,
           orgeh_stext like p1000-stext ,
           plans_stext like p1000-stext ,
           begda like p0023-begda       ,
           endda like p0023-endda       ,
           land1 like p0023-land1       ,
           arbgb like p0023-arbgb       ,
           ort01 like p0023-ort01   .
    data: end of t_output           .
    *eject
    *& Variables                                                           *
    data: o_stext like p1000-stext,
          p_stext like p1000-stext.
    *eject
    *& Initialization                                                      *
    Initialization.
    * Initialize Selection-Screen values
      perform init_selction_screen.
    *eject
    *& AT Selection-screen                                                 *
    at selection-screen .
    * Check if Test run selected, download file name should be entered
      if p_test is initial.  "
        if p_file is initial.
          message e016 with 'Please enter file name'
                            'specifying complete path'.
        endif.
      endif.
    *eject
    *& Start-of Selection                                                  *
    Start-of-selection.
    get pernr.
      clear t_output.
    * Read Infotype 0
      rp-provide-from-last p0000 space pn-begda pn-endda.
      check pnp-sw-found eq c_1.
    * Check if employee is active
      check p0000-stat2 in pnpstat2.      "pernr Active
    * Read Infotype 1
      rp-provide-from-last p0001 space pn-begda pn-endda.
      check pnp-sw-found eq c_1.
    * check if employee belongs to PL03
      check p0001-werks in pnpwerks.  "belongs to PL03
    * Check if emp belongs to Active Group
      check p0001-persg in pnppersg.
    * Read Infotype 2
      rp-provide-from-last p0002 space pn-begda pn-endda.
      check pnp-sw-found eq c_1.
    * Read Org Unit Text.
    CALL FUNCTION 'HR_READ_FOREIGN_OBJECT_TEXT'
         EXPORTING
              OTYPE                   = 'O'
              objid                   = p0001-orgeh
              begda                   = p0001-begda
              endda                   = p0001-endda
              reference_date          = p0001-begda
         IMPORTING
              object_text             = o_stext
          EXCEPTIONS
              nothing_found           = 1
              wrong_objecttype        = 2
              missing_costcenter_data = 3
              missing_object_id       = 4
              OTHERS                  = 5.
    *Read Position Text.
    CALL FUNCTION 'HR_READ_FOREIGN_OBJECT_TEXT'
         EXPORTING
              OTYPE                   = 'S'
              objid                   = p0001-plans
              begda                   = p0001-begda
              endda                   = p0001-endda
              reference_date          = p0001-begda
         IMPORTING
              object_text             = p_stext
         EXCEPTIONS
              nothing_found           = 1
              wrong_objecttype        = 2
              missing_costcenter_data = 3
              missing_object_id       = 4
              OTHERS                  = 5.
    * Gather all the required information related to the emp
      move: pernr-pernr to t_output-pernr,
            o_stext to t_output-orgeh_stext,
            p_stext to t_output-plans_stext,
            p0002-nachn to t_output-nachn,
            p0002-vorna to t_output-vorna.
    * Gather previous Employee details
      loop at p0023.
        move-corresponding p0023 to t_output.
        append t_output.
      endloop.
    *eject
    *& End-of Selection                                                    *
    end-of-selection.
      perform print_report.
    * Downlaod the file
      if not t_output[] is initial.
        if p_test eq space.
          perform download_file.
        endif.
      else.
        write: 'No records selected' color col_negative.
      endif.
    *eject
    *& Top-of-page                                                         *
    Top-of-page.
    * Print Header
      perform print_header.
    *eject
    *&      Form  download_file
    * Description :
    FORM download_file .
      DATA: full_file_name    TYPE string,
            z_akt_filesize    TYPE i     .
      full_file_name = p_file.
    *  download table into file on presentation server
      CALL METHOD cl_gui_frontend_services=>gui_download
        EXPORTING
          filename                = full_file_name
          filetype                = 'DAT'
          NO_AUTH_CHECK           = c_x
          codepage                = '1160'
        IMPORTING
          FILELENGTH              = z_akt_filesize
        CHANGING
          data_tab                = t_output[]
        EXCEPTIONS
          file_write_error        = 1
          no_batch                = 2
          gui_refuse_filetransfer = 3
          invalid_type            = 4
          no_authority            = 5
          unknown_error           = 6
          header_not_allowed      = 7
          separator_not_allowed   = 8
          filesize_not_allowed    = 9
          header_too_long         = 10
          dp_error_create         = 11
          dp_error_send           = 12
          dp_error_write          = 13
          unknown_dp_error        = 14
          access_denied           = 15
          dp_out_of_memory        = 16
          disk_full               = 17
          dp_timeout              = 18
          file_not_found          = 19
          dataprovider_exception  = 20
          control_flush_error     = 21
          not_supported_by_gui    = 22
          error_no_gui            = 23
          OTHERS                  = 24.
      IF  sy-subrc               NE        0.
        MESSAGE e016 WITH 'Download-Error; RC:' sy-subrc.
      ENDIF.
    ENDFORM.                    " download_file
    *eject
    *&      Form  print_report
    *Description:
    FORM print_report .
      data: i       type i,
            w_count type i.
      sort t_output.
    * Print the report
      loop at t_output.
        i = sy-tabix mod 2.
        if i eq 0.
          format color col_normal intensified on.
        else.
          format color col_normal intensified off.
        endif.
        write:/1     t_output-pernr          ,
               10     t_output-vorna(25)     ,
               35    t_output-nachn(25)      ,
               61   t_output-orgeh_stext     ,
               102  t_output-plans_stext     ,
               143  t_output-begda           ,
               154   t_output-endda          ,
               168   t_output-land1          ,
               178   t_output-arbgb(40)      ,
               219   t_output-ort01          ,
               249   space              .
      endloop.
      uline.
      Describe table t_output lines w_count.
      Skip 2.
      Write:/ 'Total No of Records Downloaded: ' color col_total,
              w_count.
    ENDFORM.                    " print_report
    *eject
    *&      Form  print_header
    *Description:
    FORM print_header .
      skip 1.
      Uline.
      format Intensified on color col_heading.
      write:/1   'Pers. #'        ,
             10   'Last Name'     ,
             35   'First Name'    ,
             61   'Org Unit'      ,
             102  'Position'      ,
             143  'Beg Date'      ,
            154   'End Date'      ,
            168   'Cntry Key'     ,
            178   'Prev Employer' ,
            219  'City'           ,
            249   space          .
      format intensified off color off.
      uline.
    ENDFORM.                    " print_header
    *eject
    *&      Form  init_selction_screen
    *Description:
    FORM init_selction_screen .
      refresh: pnpwerks,
               pnppersg,
               pnpstat2.
      clear:   pnpwerks,
               pnppersg,
               pnpstat2.
      pnpwerks-sign   = c_i.
      pnpwerks-option = c_EQ.
      pnpwerks-low    = c_pl03.
      append pnpwerks.
      pnppersg-sign   = c_i.
      pnppersg-option = c_EQ.
      pnppersg-low    = c_1.
      append pnppersg.
      pnpstat2-sign   = c_i.
      pnpstat2-option = c_EQ.
      pnpstat2-low    = c_3.
      append pnpstat2.
    ENDFORM.                    " init_selction_screen

  • Help with at-line selection event...

    Hello experts,
    I am currently modifying my report to let the users click on either the asset number or
    the equipment number and go to its respective transaction. If he clicks the asset number,
    it would take him to transaction AW01N and if he otherwise clicks on the equipment number,
    it would take him to transaction IE03. But there are couple of problems that I am facing.
    First is, I have hotspotted my field which is named asset_subnum which contains the asset and
    the asset subnumber. So it would look like this:
    1234567879-0000
    Now, can I split it at '-' then put those in 2 variables lets say lv_asset and lv_asset_sub
    then I will hide those 2 variables?
    Also, I am using field-symbols as my 'work area' of my internal table. How can I declare it in at
    line-selection?
    Anyway, below is my code guys:
    LOOP AT it_output ASSIGNING <fs_output>.
    IF <fs_output>-parent IS INITIAL.
            WRITE: (17) <fs_output>-asset_subnum    CENTERED.
          ELSE.
            WRITE: (17) <fs_output>-asset_subnum    RIGHT-JUSTIFIED.
          ENDIF.
          FORMAT HOTSPOT OFF.
          WRITE: (17) <fs_output>-parent_subnum     CENTERED,
                 (30) <fs_output>-funcloc           CENTERED,
                 (40) <fs_output>-description       CENTERED.
          IF p_equip = 'X'.
            FORMAT HOTSPOT ON.
            WRITE: (18) <fs_output>-equip_num       CENTERED.
            FORMAT HOTSPOT OFF.
          ENDIF.
          WRITE: (15) <fs_output>-asset_sub         CENTERED,
                 (40) <fs_output>-location          CENTERED,
                 (15) <fs_output>-accq_cost         CENTERED,
                 (20) <fs_output>-acc_dep           CENTERED,
                 (20) <fs_output>-asset_book_val    CENTERED,
                 sy-vline.
    endloop.
    When I try to hide my fields like:
    HIDE <fs_output>-equip_num.
    it is giving me a dump saying:
    HIDE is not allowed for lines of internal tables.
    Help would be greatly appreciated.Thanks a lot guys and take care!

    Hi viraylab,
    Minor Problem.
    1. U are using field-symbols,
       and the definition must be of this type
    FIELD-SYMBOLS : <fs> <b>STRUCTURE</b> T001 DEFAULT T001.
      (so that u are able to directly use the field names
      <FS>-fieldname
    2.  Hence,
    3.  instead of
      LOOP AT it_output ASSIGNING <fs_output>.
      just use
    LOOP AT it_output .
    (The problem is coming bcos of ASSIGNING)
    4. the field symbol will automatically have
      the data of the internal table in the loop.
    5. To verify this point,
       just copy paste my small code.
    6.
    report abc.
    data : t001 like t001 occurs 0 with header line.
    FIELD-SYMBOLS : <fs> STRUCTURE T001 DEFAULT T001.
    START-OF-SELECTION.
      select * from t001 into table t001.
    *------ UNCOMMENT TO GET ERROR / COMMENT 2ND LINE THEN
    *loop at t001 ASSIGNING <fs>.
        loop at t001 .
          write :/ <fs>-bukrs.
          hide <fs>-bukrs.
        endloop.
    AT LINE-SELECTION.
      WRITE T001-BUKRS.
    regards,
    amit m.

  • Problem with focus and selecting text in jtextfield

    I have problem with jtexfield. I know that solution will be very simple but I can't figure it out.
    This is simplified version of situation:
    I have a jframe, jtextfield and jbutton. User can put numbers (0-10000) separated with commas to textfield and save those numbers by pressing jbutton.
    When jbutton is pressed I have a validator which checks that jtextfield contains only numbers and commas. If validator sees that there are invalid characters, a messagebox is launched which tells to user whats wrong.
    Now comes the tricky part.
    When user presses ok from messagebox, jtextfield should select the character which validator said was invalid so that user can replace it by pressing a number or comma.
    I have the invalid character, but how can you get the focus to jtextfield and select only the character which was invalid?
    I tried requestFocus(), but it selected whole text in jtextfield and after that command I couldn't set selected text. I tried with commands setSelectionStart(int), setSelectionEnd(int) and select(int,int).
    Then I tried to use Caret and select text with that. It selected the character I wanted, but the focus wasn't really there because it didn't have keyFocus (or something like that).
    Is there a simple way of doing this?

    textField.requestFocusInWindow();
    textField.select(...);The above should work, although read the API on the select(...) method for the newer recommended approach on how to do selection.
    If you need further help then you need to create a "Short, Self Contained, Compilable and Executable, Example Program (SSCCE)",
    see http://homepage1.nifty.com/algafield/sscce.html,
    that demonstrates the incorrect behaviour, because I can't guess exactly what you are doing based on the information provided.
    Don't forget to use the "Code Formatting Tags",
    see http://forum.java.sun.com/help.jspa?sec=formatting,
    so the posted code retains its original formatting.

  • Problem with phone line not ringing

    Hi, I have a problem with my landline, it appears to ring out but isnt, no one can ring me as it says Im busy and bt cant check my line because it says Im busy..
    My phoneline died in my bedroom ages ago, so now rely on the main socket only..
    Can you pls advise me on what to do?
    Im disabled, so cannot plug and unplug but my daughter or grandson will be up later this afternoon if that needs to be done..
    Many thanks Ann

    Please ask them to follow the instructions on this site http://bt.custhelp.com/app/answers/detail/a_id/981​2/c/345,353
    If they think the fault is outside of your house, then they can report the fault here.
    https://www.bt.com/consumerFaultTracking/public/fa​ults/tracking.do?pageId=2&s_cid=con_FURL_faults
    There are some useful help pages here, for BT Broadband customers only, on my personal website.
    BT Broadband customers - help with broadband, WiFi, networking, e-mail and phones.

Maybe you are looking for

  • There is no SIM card installed after IOS update on 3GS

    Hey! I just upgraded my iPhone 3GS to iOS 5. All went well, then at the end, it asks me a few set ups (like language, Location, and WiFi settings). After that, it attempts to activate, and fails, giving me the following error in iTunes: "There is no

  • Cannot ping inside IP behind sonicwall from Cisco ASA 5500

    I have a sonicwall at site B and the cisco asa5500 at the main office. (site A) The site to site VPN is working, but I can not ping the inside ip (10.1.5.2) of the sonic wall from Site A. I need this only to access the computers behind the sonicwall

  • ALBPM - Batch events and Load Balancing

    Hi, We are planning to design a BPM solution for one of our current applications. The need we have is that the BPM solution should be able to start process instances in a batch mode. We receive about 25,000 to 30,000 events in a batch file and we nee

  • How do I put an image on my podcast in the itunes store?

    How do I put an image on my podcast in the itunes store?

  • Data visibility-Manager visibility

    hi I need some clarification on the following: In which context i go for manager visibility? In which context i go for book of business? How to compare manager visibilty with book of business? regards sowm