Hotspot in excel

I am sending a mail with excel attachement.In this excel there are POs .User wants hotspot like as in alv or double click which leads to transaction me23n with clicked PO.Is there any way to do this.

Hi Oldun,
     I suppose your requirement is to double click or hotspot event upon your Excel file and not ALV report. Is this how it is supposed to be? Correct me if I am wrong.
     This is possible but requires Object Link Enabling (OLE) programming. You will have to open the file using OLE-OPEN at runtime , read the file and the get the purchase order number selected by the user at runtime, set the parameter-id of that PO number and close the file at runtime.
     This is gonna be difficult though. Just check. This requirement seems to be a bit weird though. I mean how much effort does it take to just select a particular PO number from the excel go to ME23 and paste it.??
Regards,
Dnyanesh.

Similar Messages

  • My iOS 6.1.4 is updated. i have other devices connected to wifi hotspot of my iphone5. Though my other devices appeared to be connected and shows an excellent cignal strength, i cannot access internet. hope this will be fixed.

    my iOS 6.1.4 is updated. i have other devices connected to wifi hotspot of my iphone5. Though my other devices appeared to be connected and shows an excellent cignal strength, i cannot access internet. hope this will be fixed.

    I hope so too.  So what have you actually done to fix your issue?

  • MS Excel document as attachment to a PDF document does not open with a hot spot/link in the PDF

    Hi, I have attached an excel file to a pdf document. I need to open this document in a new window by clicking an icon/hotspot in the pdf document to which it it attached.
    I am using the Link Tool to create a hot spot around the icon in the pdf. In the next window I am using the Go to Page view option, opening the attachment to its first page and clicking the "set link" button.
    For some reason, clicking the hotspot does not open the excel document as it does another pdf document.
    Need help resolving this issue with attached documents.

    Select a particular download file. Press COMMAND-I to open the Get Info window.  In the Open With section choose the desired default application from the dropdown menu then click on the Change All button.
    For .dmg files use DiskImageMounter (System/Library/CoreServices/ folder.)
    For .zip files use Archiver - same folder as above - or download TheArchiver - MacUpdate or CNET Downloads.

  • Export To Excel In Visual Composer 7.0

    Hi ,
    i need Exprot Excel Functionality in Visual  Composer7.0  EP7.0 & SP17 . we are getting the data from BI 7 Version Queries in Portal .
    As We Know there is No Direct Open of Export to Excel Functionality
    After Folliowing the Great Link
    Using Web Design API .with Hyperlink  .
    When im trying click on Export To Excel Button It throws Error .
    Im Using Compiler Flash Flex2 Compiler.
    When i am using Flash Compiler it Throws An Error in VC .
    please give me valuehble inputs
    500 Internal Server Error
      BEx Web Application
    Failed to process request; contact your system administrator
    Information for Administrator
    To avoid this exception see the steps below. To help SAP better investigate this issue, you will need to provide the diagnostic information from these steps.
    1. Most likely, the issue you are experiencing has already been corrected. Please make sure that the most recent patch level is deployed on your system according to notes 1033246 and 1011241. Starting with Support Package Stack 16 patch level 30, BI Java is delivered according to the synchronized delivery process described in the note 1033246.
    2. Please ensure that NetWeaver Business Intelligence Diagnostics & Support Desktop Tool  does not report any issues on your server according to note 937697. You can start it by clicking here (administrator permissions are required).
    3. When opening any customer message on this issue, please attach:
    Support Desktop Tool support info ZIP  file according to note 937697,
    Required information for reproduction  according to note 948490.
    Error Summary
    Exception occured while processing the current request; this exception cannot be handled by the application or framework
    If the information on this page does not help you locate and correct the cause of the problem, contact your system administrator
    To facilitate analysis of the problem, keep a copy of this error page Hint: Most Web browsers allow you to select all content, and copy and paste it into an empty document (such as in an email or simple text file)
    Root Cause
    The initial exception that caused the request to fail was:
    Parameter object with the name "BI_COMMAND_TYPE" and the index "0" still does not exist in the parameter list:
    <parameterList>
      <param name=" BI_COMMAND_TYPE" value="EXPORT"/>
      <param name=" NULL" value=""/>
      <param name=" SHOW_EXPORT_DIALOG" value="X"/>
    </parameterList>
    com.sap.ip.bi.base.exception.BIBaseRuntimeException: Parameter object with the name "BI_COMMAND_TYPE" and the index "0" still does not exist in the parameter list:
    <parameterList>
      <param name=" BI_COMMAND_TYPE" value="EXPORT"/>
      <param name=" NULL" value=""/>
      <param name=" SHOW_EXPORT_DIALOG" value="X"/>
    </parameterList>
    Log ID 001517B2186400780000039E00003F0400047C7C752D75EE
    Details: Full Exception Chain
    System Environment
    Server
    BI Java Release: 7 - Patch level: 0000000016 - Description: BI Web Applications Java - Additional info:  - Production mode: true
    BI ABAP Release: 700 - Patch level: 0019 - Description: SAP NetWeaver BI 7.0 (PB1CLNT451) - Additional info:  - Production mode: true
    Java Virtual Machine Java HotSpot(TM) 64-Bit Server VM - Sun Microsystems Inc. - 1.4.2_21-b03
    Operating System SunOS - sparcv9 - 5.10
    Context
    ACCESSIBLE false
    CACHE true
    CONTENT_PADDING true
    COUNTRY US
    DEBUG false
    DEBUG_LEVEL 0
    DEBUG_MESSAGES false
    DEBUG_TEXTS false
    DEFAULT_FONT 
    DISPLAY_STACK_TRACE_IN_ERROR_PAGES true
    LANGUAGE EN
    Master System Alias PB1CLNT451
    NAVIGATION_NODE_ACTIVE_IVIEW pcd:portal_content/com.sap.pct/platform_add_ons/com.sap.ip.bi/iViews/com.sap.ip.bi.bex
    PROFILING false
    Query String (Initial Browser Request) BI_COMMAND_1-BI_COMMAND_TYPE=EXPORT&BI_COMMAND_1-NULL=&BI_COMMAND_1-SHOW_EXPORT_DIALOG=X&BI_COMMAND_1-EXPORT_FORMAT=PDF&QUERY=
    RTL false
    Request URL http://d03pp1.saildsp.co.in:50300
    SAP_BW_IVIEW_ID pcd:portal_content/com.sap.pct/platform_add_ons/com.sap.ip.bi/iViews/com.sap.ip.bi.bex
    SERVER_URL_PREFIX http://d03PP1.saildsp.co.in:50300
    THEME_NAME sap_tradeshow
    TRACE false
    TRAY_TYPE PLAIN
    Time Wed Jan 06 16:01:30 IST 2010
    USE_HTTPS_FOR_ADS false
    USE_SAP_EXPORT_LIB false
    User CEP_SIVA (USER.R3_DATASOURCE.CEP_SIVA)
    VALIDATION_DATA false
    Deployed SCAs
    SCA Version SP Patch Compiled Deployed
    ADSSAP 7.00 17 0 2008-09-17 22:26:43 IST 2009-08-29 10:51:50 IST
    BASETABLES 7.00 17 0 2008-09-17 22:41:38 IST 2009-08-29 10:37:16 IST
    BI-BASE-S 7.00 17 20 2008-12-04 07:47:32 IST 2009-08-29 11:55:31 IST
    BI-IBC 7.00 17 0 2008-09-18 06:07:59 IST 2009-08-29 11:45:17 IST
    BI-REPPLAN 7.00 17 0 2008-09-18 07:38:15 IST 2009-08-29 11:56:13 IST
    BI-WDALV 7.00 17 0 2008-09-18 07:38:21 IST 2009-08-29 11:56:24 IST
    BIWEBAPP 7.00 17 20 2008-12-04 07:48:29 IST 2009-08-29 11:47:27 IST
    BI_MMR 7.00 17 0 2008-09-17 22:42:29 IST 2009-08-29 10:52:19 IST
    BI_UDI 7.00 17 0 2008-09-17 22:42:49 IST 2009-08-29 10:53:28 IST
    CAF 7.00 17 0 2008-09-18 08:09:40 IST 2009-08-29 11:30:07 IST
    CAF-KM 7.00 17 0 2008-09-18 07:42:37 IST 2009-08-29 12:06:47 IST
    CAF-UM 7.00 17 0 2008-09-18 08:09:46 IST 2009-08-29 10:47:54 IST
    CORE-TOOLS 7.00 17 0 2008-09-17 22:45:03 IST 2009-08-29 10:37:32 IST
    EP-PSERV 7.00 17 0 2008-09-18 06:14:35 IST 2009-08-29 11:57:13 IST
    EP-WDC 7.00 17 0 2008-09-18 01:31:00 IST 2009-08-29 11:59:04 IST
    EPBC 7.00 17 0 2008-09-18 06:13:01 IST 2009-08-29 11:09:46 IST
    EPBC2 7.00 17 0 2008-09-18 06:13:12 IST 2009-08-29 11:49:55 IST
    JLOGVIEW 7.00 17 0 2008-09-17 21:40:00 IST 2009-08-29 10:37:52 IST
    JSPM 7.00 17 1 2008-12-10 12:16:00 IST 2009-08-28 22:07:33 IST
    KM-KW_JIKS 7.00 17 0 2008-09-17 22:47:53 IST 2009-08-29 11:10:10 IST
    KMC-BC 7.00 17 0 2008-09-18 06:15:00 IST 2009-08-29 11:59:39 IST
    KMC-CM 7.00 17 0 2008-09-18 06:15:52 IST 2009-08-29 12:00:05 IST
    KMC-COLL 7.00 17 0 2008-09-18 06:16:17 IST 2009-08-29 11:51:27 IST
    LM-PORTAL 7.00 17 0 2008-09-18 07:45:59 IST 2009-08-29 11:45:18 IST
    LM-TOOLS 7.00 17 0 2008-10-08 12:18:34 IST 2009-08-29 11:37:41 IST
    NET-PDK 7.00 17 0 2008-09-18 06:16:25 IST 2009-08-29 11:51:29 IST
    RTC 7.00 17 0 2008-09-18 06:16:39 IST 2009-08-29 11:51:31 IST
    RTC-STREAM 7.00 17 0 2008-09-18 06:16:39 IST 2009-08-29 11:45:19 IST
    SAP-EU 7.00 17 0 2008-09-18 07:47:22 IST 2009-08-29 12:05:04 IST
    SAP-JEE 7.00 17 0 2008-09-17 22:52:28 IST 2009-08-29 10:38:17 IST
    SAP-JEECOR 7.00 17 0 2008-09-17 22:53:35 IST 2009-08-29 10:38:52 IST
    SAP_JTECHF 7.00 17 0 2008-09-17 22:54:39 IST 2009-08-29 10:39:08 IST
    SAP_JTECHS 7.00 17 0 2008-09-17 22:57:28 IST 2009-08-29 11:24:36 IST
    UMEADMIN 7.00 17 0 2008-09-18 08:19:28 IST 2009-08-29 11:38:09 IST
    UWLJWF 7.00 17 0 2008-09-18 06:17:26 IST 2009-08-29 12:07:22 IST
    VCBASE 7.00 17 0 2008-09-18 06:17:33 IST 2009-08-29 12:08:19 IST
    VCFLEX 7.00 17 0 2008-09-18 06:18:04 IST 2009-08-29 11:52:19 IST
    VCFRAMEWORK 7.00 17 0 2008-09-18 06:18:13 IST 2009-08-29 11:52:24 IST
    VCKITBI 7.00 17 0 2008-09-18 06:11:41 IST 2009-08-29 11:45:20 IST
    VCKITGP 7.00 17 0 2008-09-18 06:18:13 IST 2009-08-29 11:45:21 IST
    VCKITXX 7.00 17 0 2008-09-18 06:18:13 IST 2009-08-29 11:45:22 IST
    WDEXTENSIONS 7.00 17 0 2008-09-18 07:49:02 IST 2009-08-29 12:08:46 IST
    Full Exception Chain
    Log ID 001517B2186400780000039E00003F0400047C7C752D75EE
    com.sap.ip.bi.base.exception.BIBaseRuntimeException: Parameter object with the name "BI_COMMAND_TYPE" and the index "0" still does not exist in the parameter list: <parameterList>  <param name=" BI_COMMAND_TYPE" value="EXPORT"/>  <param name=" NULL" value=""/>  <param name=" SHOW_EXPORT_DIALOG" value="X"/></parameterList>     at com.sap.ip.bi.base.parameter.impl.ParameterList.getParameterWithUpperCaseName(ParameterList.java:682)     at com.sap.ip.bi.base.parameter.impl.ParameterList.getValueWithUpperCaseName(ParameterList.java:748)     at com.sap.ip.bi.base.parameter.impl.ParameterList.getValue(ParameterList.java:742)     at com.sap.ip.bi.base.parameter.impl.ParameterList.getValue(ParameterList.java:732)     at com.sap.ip.bi.webapplications.runtime.impl.Page.resolvePageCommandDialogs(Page.java:4471)     at com.sap.ip.bi.webapplications.runtime.impl.Page.normalizeCommands(Page.java:4422)     at com.sap.ip.bi.webapplications.runtime.impl.Page.doProcessRequest(Page.java:3974)     at com.sap.ip.bi.webapplications.runtime.impl.Page._processRequest(Page.java:3021)     at com.sap.ip.bi.webapplications.runtime.impl.Page.processRequest(Page.java:2864)     at com.sap.ip.bi.webapplications.runtime.controller.impl.Controller.doProcessRequest(Controller.java:994)     at com.sap.ip.bi.webapplications.runtime.controller.impl.Controller._processRequest(Controller.java:883)     at com.sap.ip.bi.webapplications.runtime.controller.impl.Controller.processRequest(Controller.java:860)     at com.sap.ip.bi.webapplications.runtime.jsp.portal.services.BIRuntimeService._handleRequest(BIRuntimeService.java:362)     at com.sap.ip.bi.webapplications.runtime.jsp.portal.services.BIRuntimeService.handleRequest(BIRuntimeService.java:279)     at com.sap.ip.bi.webapplications.runtime.jsp.portal.components.LauncherComponent.doContent(LauncherComponent.java:24)     at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:209)     at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalComponent.java:114)     at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:328)     at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:136)     at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:189)     at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:215)     at com.sapportals.portal.prt.pom.PortalNode.service(PortalNode.java:645)     at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:328)     at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:136)     at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:189)     at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:753)     at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:240)     at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:524)     at java.security.AccessController.doPrivileged(Native Method)     at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:407)     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)     at com.sap.engine.services.servlets_jsp.server.servlet.InvokerServlet.service(InvokerServlet.java:156)     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)     at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)     at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)     at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:386)     at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:364)     at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:1039)     at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:265)     at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)     at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175)     at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)     at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)     at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)     at java.security.AccessController.doPrivileged(Native Method)     at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:102)     at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:172)
    Regards ,
    venkat p

    Hi Apurva ,
    Now I got Variable Id  and Varibale Value i have give From Data Fields of VC  .
    When i click on Button Export To  Excel it gives
    SET_VARIABLES_STATE is Correctly placed For
    VARIABLE_VALUES VARIABLE_VALUE
    if give 
    VARIABLE_VALUES VARIABLE_VALUE instead of SET_VARIABLES_STATE it is giving  No MetaData  is available for VARIABLE_VALUES VARIABLE_VALUE
    it throws like .
    please help in this regard.
    I Have given The Formuls AS Below
    "pcd!3aportal_content!2fcom.sap.pct!2fplatform_add_ons!2fcom.sap.ip.bi!2fiViews!2fcom.sap.ip.bi.bex?QUERY=zmp_prodn_mtef_ccp_1&BI_COMMAND_1-BI_COMMAND_TYPE=VARIABLE_VALUES VARIABLE_VALUE&BI_COMMAND_1-VARIABLE_VALUES VARIABLE_VALUE_1-VARIABLE_TYPE=VARIABLE_INPUT_STRING&BI_COMMAND_1-VARIABLE_VALUES-VARIABLE_VALUE_1-VARIABLE_TYPE-VARIABLE_INPUT_STRING="&2009&"&BI_COMMAND_1-VARIABLE_VALUES-VARIABLE_VALUE_1-VARIABLE=0P_FYEAR&BI_COMMAND_3-BI_COMMAND_TYPE=EXPORT&BI_COMMAND_3-EXPORT_FORMAT=XLS&BI_COMMAND_3-null="
    Regards ,
    venkat p

  • Airport Extreme - creating a wired local network from a cellular hotspot without ethernet ports?

    Forgive the book I've written below, please. I generally think too much info is better than not enough... I'm looking for assistance and/or suggestions since I have been unable to locate solutions on my own so far. Searching this forum has found a great number of "sort-of" related things, but all of them so far appear to involve apple-only hardware or upstream network devices which have ethernet ports. Nothing that seems to match my situation enough to extrapolate out. Maybe I'm just using the wrong keywords. Anyway....
    I've recently moved to a particularly rural area with no wired internet access to speak of (well, I suppose there is dial-up, but... yeah). I've tried several different wireless varieties including satellite, the AT&T Elevate 4G hotspot and a service that used an EVDO-cellular solution(a sprint-based reseller).  The former had serious latency issues which I had predicted and so was right-out. The last had signal coverage problems which their maps did not accurately reveal. Their potential mitigation was to have me invest even more money into a super-mega antenna to be roof-mounted. And even that was an uncertain fix. The AT&T solution with the 4G hotspot has been AMAZING so far and I love it. Coverage is great, latency and bandwidth fantastic.
    I love it but for one exception, that is. Connectivity options.
    There is a particularly limited number of WiFi connections available and only a USB network adapter for a single computer. None of my wired-only network devices can connect directly and I have significantly more WiFi connected devices in general use than the device supports.
    I have an Airport Extreme that I was using as my primary connection point through a FiOS router at my previous home(and both the satellite and EVDO modems at the new place). Never had any problems with it when feeding its WAN port with one of the various routers' LAN ports. However, as has been evident by reading all sorts of posts here and elsewhere, having it connect via WiFi to the Elevate means that the ethernet ports are disabled. Not terribly useful.
    The Elevate has no ethernet ports. Only WiFi and USB network connectivity.
    The Elevate does not appear to have settings available to create a WDS network-- so it cannot be "Extended" via those methods, either, as far as I am able to tell.
    So these are some thoughts I've had. Before I invest the time and money into them(both of which are in extremely short supply lately), I'd like to know if anyone else has already solved the issue or can tell me definitively whether these ideas, or some I haven't thought of, will or won't work. Any helpful feedback or thoughts would be sincerely appreciated.
    Options I've considered, but are uncertain:
    -A Wifi/Ethernet or even ethernet-only router which has a USB WAN uplink(I've had a few bites on searching, but nobody seems 100% clear on the capability for the models I've located). I could plug the Elevate into that USB port and then from there I'm golden. If this is the best option, then can someone recommend a brand/model that they know will work in this way?
    -WiFi Access Point (Airport Express, maybe?) that will connect to the elevate via WiFi, and then use its single Ethernet port to serve as the APExtreme's WAN uplink. (I don't know if this will work at all, actually...)
    -Connect to the computer via USB, run some kind of network bridging software (which I don't know what the heck that would be) to bridge between the USB Network and the Ethernet port, then run a hard wire from there to the APExtreme's standard ethernet WAN uplink. This is going to be a "last resort" option since it involves software I'm unfamiliar with, even unsure of availability for Mac, and requires the computer to be running and configured properly at all times. Given the way my kids abuse a computer, I can't be certain of anything involving this option.
    -Some secret method of turning on WDS capabilities in the Elevate which would then allow my existing base station to become a second node in the chain. I really wish someone could tell me this is possible if only I'd push the right buttons. I see this is as the absolute best option, if it can be done. Cheapest, anyway.
    Current set-up:
    AT&T Elevate 4G hotspot
    WiFi connected devices(rotating since Wifi connection count is limited): Mac PC, 2 iPads, 3 iPhones, Apple TV, a Nokia mini-tablet, a Kindle fire, Wii, XBox 360, an old dell laptop issued by my office.
    Apple Aiport Extreme base station
    Wired connections: blueray player, television, satellite TV pay-per-view uplinky device thing.
    Please, tell me your thoughts?

    Had the same issue here.  Here is the best solution I have found so far:
    Hotspot + Pepwave Max On-The-Go (w/ Load Balancing) + Airport Extreme
    I have a VZW MiFi, but I believe this set-up will work with other hotspot devices.  I actually have 2 MiFi Hotspots with a monthly allowance of 20G each.  They are plugged directly into the Pepwave router (aka, tethered).  (Note:  you have to have the right cable to do this.  The one that came with my Hotspot was only for charging.)  If, for some reason, you cannot tether with your Hotspot device, you want a router that offers WiFi as WAN.  The Pepwave will do this.  The Pepwave is connected to my Airport Extreme via ethernet cable.  I have the WiFi on the MiFis and the Pepwave turned off.  So the only visible network is my Airport Extreme.  The Pepwave is essentially just functioning as a modem.
    I used to have a Cradlepoint, but I did not find it very user friendly--too complex for home use.  The Pepwave Max OTG is awesome.  I got the one with Load Balancing so it allows you to connect up to 4 cellular devices.  If you only need the one Hotspot, you can just get the cheaper Pepwave Max OTG.  The Pepwave allows me to run off one of the MiFis until I hit my 20G/month allowance, then it automatically switches to the other one.  That way I never max-out on my monthly data allowance.  Additionally, it gives you a real-time, hourly, daily and monthly running tally on data usage.
    The guys at the 3Gstore are excellent and can help you figure out the best solution for your situation.

  • Need help in exporting data in to Excel by integrating XML publisher in OAF

    Hi All,
    I am facing issue while exporting data into Excel by integrating XML publisher in OAF. Everything is working fine except that the report is not uploaded in the Excel sheet. Excel sheet is opening empty.
    In OC4J server log an getting the below Exception while exporting the data:
    13/06/21 14:31:17 in try b4 creating DT
    [062113_023118734][][STATEMENT] debug_mode=on
    [062113_023118750][][STATEMENT] xml_tag_case=upper
    [062113_023118750][][STATEMENT] Inside parameterParser...
    [062113_023118750][][STATEMENT] Parameter:p_last_rev  Default value:
    [062113_023118750][][STATEMENT] Inside dataQueryParser...
    [062113_023118750][][STATEMENT] Inside dataStructureParser...
    [062113_023118765][][STATEMENT] Group ...report
    [062113_023118765][][STATEMENT] Group ...G_DISPUTE
    [062113_023118765][][STATEMENT] Template parsing completed...
    [062113_023118765][][STATEMENT] Setting Data Template
    [062113_023118765][][STATEMENT] Setting JDBC Connection
    13/06/21 14:31:18 after datatemplate
    [062113_023118765][][STATEMENT] ***Paramter :p_last_rev Value :419947
    [062113_023118765][][STATEMENT] Setting Parameters
    [062113_023118765][][STATEMENT] Setting Parameters
    13/06/21 14:31:18 after set params
    13/06/21 14:31:18 after setOutput
    [062113_023118781][][STATEMENT] Start process Data
    [062113_023118781][][STATEMENT] Process Data ...
    [062113_023118781][][STATEMENT] p_last_rev
    [062113_023118812][][STATEMENT] Writing Data ...
    [062113_023118843][][STATEMENT] Sql Query :Q_DISPUTE: select f.description "Current_Reviewer",
           p.trx_date "Original_Transaction_Date",
           h.discr_dt "Create_Date",
           h.custid "Customer_Number",
           h.cusname "Customer_Name",
           h.discr_no "Dispute_Number",
           p.amount_due_remaining "Remaining_Amount",
           h.last_rev,
           a.name
      from seacds.ar_payment_schedules_all_sv p,
           seaar.seaar_ddt_header             h,
           seacds.fnd_user_nv                 f,
           seacds.ar_collectors_nv            a
    where p.trx_number = h.discr_no
       and f.user_name = h.last_rev
       and nvl(a.employee_id, -999) = nvl(f.employee_id, -987)
       and a.attribute1 = 'AR'
       and p.class != 'PMT'
       and h.clsd_flag = 'N'
       and p.org_id = 22
       and p.amount_due_remaining > 0
       and h.last_rev = decode(:p_last_rev,'ALL',last_rev,:p_last_rev)
    order by f.description,h.last_rev
    [062113_023118843][][STATEMENT] 1: p_last_rev:419947
    [062113_023118843][][STATEMENT] 2: p_last_rev:419947
    [062113_023119546][][EVENT] Data Generation Completed...
    [062113_023119546][][EVENT] Total Data Generation Time 1.0 seconds
    13/06/21 14:31:19 after processData
    13/06/21 14:31:19 blobDomain Value :<?xml version="1.0" encoding="UTF-8"?>
    <IDIS_OPENEDBYUSER_RPT>
    <p_last_rev>419947</p_last_rev>
    <LIST_G_DISPUTE>
    <G_DISPUTE>
    <CURRENT_REVIEWER>NUMFON KIMWANGTAGO</CURRENT_REVIEWER>
    <ORIGINAL_TRANSACTION_DATE>2010-10-02T00:00:00.000+05:30</ORIGINAL_TRANSACTION_DATE>
    <CREATE_DATE>2011-04-20T00:00:00.000+05:30</CREATE_DATE>
    <CUSTOMER_NUMBER>45356000</CUSTOMER_NUMBER>
    <CUSTOMER_NAME>HEWLETT PACKARD GMBH</CUSTOMER_NAME>
    <DISPUTE_NUMBER>1CZ155358</DISPUTE_NUMBER>
    <REMAINING_AMOUNT>945</REMAINING_AMOUNT>
    </G_DISPUTE>
    </LIST_G_DISPUTE>
    </IDIS_OPENEDBYUSER_RPT>
    [062113_023120390][oracle.apps.xdo.oa.schema.server.TemplateInputStream][STATEMENT] initStream(): oa-date-validation: null
    [062113_023120390][oracle.apps.xdo.oa.schema.server.TemplateInputStream][STATEMENT] initStream(): xdo.TemplateValidation: null
    [062113_023120390][oracle.apps.xdo.oa.schema.server.TemplateInputStream][STATEMENT] initStream(): template validation is on
    [062113_023121046][][STATEMENT] TemplateHelper.runProcessTemplate() called
    [062113_023121062][][EXCEPTION] [DEBUG] ------- Preferences defined PreferenceStore -------
    [062113_023121062][][EXCEPTION] [DEBUG] ------- Environment variables stored in EnvironmentStore -------
    [062113_023121062][][EXCEPTION] [DEBUG]  [ICX_COOKIE_NAME]:[dcap1]
    [062113_023121062][][EXCEPTION] [DEBUG]  [JDBC:processEscapes]:[true]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_JDBC_IDLE_THRESHOLD.LOW]:[-1]
    [062113_023121062][][EXCEPTION] [DEBUG]  [APPL_SERVER_ID]:[C1ACC302F183004AE0430A0990B773BA35529272341851546077251405344914]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_JDBC_STMT_CACHE_SIZE]:[100]
    [062113_023121062][][EXCEPTION] [DEBUG]  [NLS_DATE_LANGUAGE]:[AMERICAN]
    [062113_023121062][][EXCEPTION] [DEBUG]  [ICX_SESSION_COOKIE_VALUE]:[v1CUM5yeRe9st6ePp4QEmgJhEW]
    [062113_023121062][][EXCEPTION] [DEBUG]  [ICX_TRANSACTION_ID]:[-1]
    [062113_023121062][][EXCEPTION] [DEBUG]  [NLS_DATE_FORMAT]:[DD-MON-RRRR]
    [062113_023121062][][EXCEPTION] [DEBUG]  [RESP_APPL_ID]:[20084]
    [062113_023121062][][EXCEPTION] [DEBUG]  [LOGIN_ID]:[4444238]
    [062113_023121062][][EXCEPTION] [DEBUG]  [DB_PORT]:[1533]
    [062113_023121062][][EXCEPTION] [DEBUG]  [USER_ID]:[2318]
    [062113_023121062][][EXCEPTION] [DEBUG]  [DISPLAY_LANGUAGE]:[US]
    [062113_023121062][][EXCEPTION] [DEBUG]  [APPLICATION_ID]:[seagate.oracle.apps.seaar.idispute.report.server.iDisputeOpenedByUserAM]
    [062113_023121062][][EXCEPTION] [DEBUG]  [NLS_NUMERIC_CHARACTERS]:[.,]
    [062113_023121062][][EXCEPTION] [DEBUG]  [NLS_LANGUAGE]:[AMERICAN]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_JDBC_BUFFER_MIN]:[1]
    [062113_023121062][][EXCEPTION] [DEBUG]  [GUEST_USER_PWD]:[GUEST/ORACLE]
    [062113_023121062][][EXCEPTION] [DEBUG]  [RESP_ID]:[53350]
    [062113_023121062][][EXCEPTION] [DEBUG]  [NLS_SORT]:[BINARY]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_JDBC_PLSQL_RESET]:[false]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_PROFILE_VALIDATION_ENABLED]:[null]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FUNCTION_ID]:[-1]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_JDBC_BUFFER_DECAY_SIZE]:[5]
    [062113_023121062][][EXCEPTION] [DEBUG]  [ICX_PV_SESSION_MODE]:[115J]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_JDBC_CONTEXT_CHECK]:[true]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_JDBC_USABLE_CHECK]:[false]
    [062113_023121062][][EXCEPTION] [DEBUG]  [APPS_JDBC_URL]:[jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS_LIST=(LOAD_BALANCE=YES)(FAILOVER=YES)(ADDRESS=(PROTOCOL=tcp)(HOST=okdevcl1012b.okla.seagate.com)(PORT=1533))(ADDRESS=(PROTOCOL=tcp)(HOST=okdevcl1012a.okla.seagate.com)(PORT=1533)))(CONNECT_DATA=(SERVICE_NAME=dcap1)))]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FNDNAM]:[APPS]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_PROXY_USER]:[null]
    [062113_023121062][][EXCEPTION] [DEBUG]  [TWO_TASK]:[dcap1_balance]
    [062113_023121062][][EXCEPTION] [DEBUG]  [APPS_JDBC_DRIVER_TYPE]:[THIN]
    [062113_023121062][][EXCEPTION] [DEBUG]  [DB_HOST]:[okdevcl1012a.okla.seagate.com]
    [062113_023121062][][EXCEPTION] [DEBUG]  [DBC_FILE_PATH]:[C:\JDEV\jdevhome\jdev\dbc_files\secure\dcap1.dbc]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_JDBC_IDLE_THRESHOLD.HIGH]:[-1]
    [062113_023121062][][EXCEPTION] [DEBUG]  [SECURITY_GROUP_ID]:[0]
    [062113_023121062][][EXCEPTION] [DEBUG]  [LANG_CODE]:[US]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_MAX_JDBC_CONNECTIONS]:[500]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_JDBC_BUFFER_DECAY_INTERVAL]:[300]
    [062113_023121062][][EXCEPTION] [DEBUG]  [USER_NAME]:[505543]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_JDBC_BUFFER_MAX]:[5]
    [062113_023121062][][EXCEPTION] [DEBUG]  [DB_NAME]:[null]
    [062113_023121062][][EXCEPTION] [DEBUG]  [NLS_CHARACTERSET]:[AL32UTF8]
    [062113_023121062][][EXCEPTION] [DEBUG]  [ORG_ID]:[22]
    [062113_023121062][][EXCEPTION] [DEBUG]  [DB_ID]:[dcap1]
    [062113_023121062][][EXCEPTION] [DEBUG]  [GWYUID]:[APPLSYSPUB/PUB]
    [062113_023121062][][EXCEPTION] [DEBUG]  [NLS_TERRITORY]:[AMERICA]
    [062113_023121062][][EXCEPTION] [DEBUG]  [ICX_SESSION_ID]:[1231277285]
    [062113_023121062][][EXCEPTION] [DEBUG]  [JDBC:oracle.jdbc.maxCachedBufferSize]:[358400]
    [062113_023121062][][EXCEPTION] [DEBUG] ------- Properties stored in Java System Properties -------
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.vendor]:[Sun Microsystems Inc.]
    [062113_023121062][][EXCEPTION] [DEBUG]  [ajp.connection.listener.state]:[down]
    [062113_023121062][][EXCEPTION] [DEBUG]  [sun.management.compiler]:[HotSpot Client Compiler]
    [062113_023121062][][EXCEPTION] [DEBUG]  [oracle.j2ee.container.version]:[10.1.3.3.0]
    [062113_023121062][][EXCEPTION] [DEBUG]  [os.name]:[Windows XP]
    [062113_023121062][][EXCEPTION] [DEBUG]  [sun.boot.class.path]:[C:\JDEV\jdevbin\jdk\jre\lib\rt.jar;C:\JDEV\jdevbin\jdk\jre\lib\i18n.jar;C:\JDEV\jdevbin\jdk\jre\lib\sunrsasign.jar;C:\JDEV\jdevbin\jdk\jre\lib\jsse.jar;C:\JDEV\jdevbin\jdk\jre\lib\jce.jar;C:\JDEV\jdevbin\jdk\jre\lib\charsets.jar;C:\JDEV\jdevbin\jdk\jre\classes]
    [062113_023121062][][EXCEPTION] [DEBUG]  [sun.desktop]:[windows]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.vm.specification.vendor]:[Sun Microsystems Inc.]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.runtime.version]:[1.5.0_05-b05]
    [062113_023121062][][EXCEPTION] [DEBUG]  [com.oracle.corba.ee.security.trusted.clients]:[*]
    [062113_023121062][][EXCEPTION] [DEBUG]  [oracle.security.jazn.config]:[C:\JDEV\jdevhome\jdev\system\oracle.j2ee.10.1.3.41.57\embedded-oc4j\config\jazn.xml]
    [062113_023121062][][EXCEPTION] [DEBUG]  [user.name]:[mysub]
    [062113_023121062][][EXCEPTION] [DEBUG]  [user.language]:[en]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.naming.factory.initial]:[com.evermind.server.ApplicationInitialContextFactory]
    [062113_023121062][][EXCEPTION] [DEBUG]  [sun.boot.library.path]:[C:\JDEV\jdevbin\jdk\jre\bin]
    [062113_023121062][][EXCEPTION] [DEBUG]  [oc4j.jms.usePersistenceLockFiles]:[false]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.version]:[1.5.0_05]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.util.logging.manager]:[oracle.classloader.util.ApplicationLogManager]
    [062113_023121062][][EXCEPTION] [DEBUG]  [user.timezone]:[Asia/Calcutta]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.net.preferIPv4Stack]:[true]
    [062113_023121062][][EXCEPTION] [DEBUG]  [sun.arch.data.model]:[32]
    [062113_023121062][][EXCEPTION] [DEBUG]  [javax.rmi.CORBA.UtilClass]:[com.sun.corba.ee.impl.javax.rmi.CORBA.Util]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.endorsed.dirs]:[C:\JDEV\jdevbin\jdk\jre\lib\endorsed]
    [062113_023121062][][EXCEPTION] [DEBUG]  [sun.cpu.isalist]:[]
    [062113_023121062][][EXCEPTION] [DEBUG]  [sun.jnu.encoding]:[Cp1252]
    [062113_023121062][][EXCEPTION] [DEBUG]  [file.encoding.pkg]:[sun.io]
    [062113_023121062][][EXCEPTION] [DEBUG]  [DBCFILE]:[C:\JDEV\jdevhome\jdev\dbc_files\secure\dcap1.dbc]
    [062113_023121062][][EXCEPTION] [DEBUG]  [file.separator]:[\]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.specification.name]:[Java Platform API Specification]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.class.version]:[49.0]
    [062113_023121062][][EXCEPTION] [DEBUG]  [user.country]:[US]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.home]:[C:\JDEV\jdevbin\jdk\jre]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.vm.info]:[mixed mode]
    [062113_023121062][][EXCEPTION] [DEBUG]  [os.version]:[5.1]
    [062113_023121062][][EXCEPTION] [DEBUG]  [org.omg.CORBA.ORBSingletonClass]:[com.sun.corba.ee.impl.orb.ORBImpl]
    [062113_023121062][][EXCEPTION] [DEBUG]  [path.separator]:[;]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.vm.version]:[1.5.0_05-b05]
    [062113_023121062][][EXCEPTION] [DEBUG]  [user.variant]:[]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.protocol.handler.pkgs]:[com.evermind.protocol]
    [062113_023121062][][EXCEPTION] [DEBUG]  [checkForUpdates]:[adminClientOnly]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.awt.printerjob]:[sun.awt.windows.WPrinterJob]
    [062113_023121062][][EXCEPTION] [DEBUG]  [RUN_FROM_JDEV]:[true]
    [062113_023121062][][EXCEPTION] [DEBUG]  [sun.io.unicode.encoding]:[UnicodeLittle]
    [062113_023121062][][EXCEPTION] [DEBUG]  [com.sun.jts.pi.INTEROP_MODE]:[false]
    [062113_023121062][][EXCEPTION] [DEBUG]  [awt.toolkit]:[sun.awt.windows.WToolkit]
    [062113_023121062][][EXCEPTION] [DEBUG]  [MetaObjectContext]:[oracle.adf.mds.jbo.JBODefManager]
    [062113_023121062][][EXCEPTION] [DEBUG]  [FND_TOP]:[C:\JDEV\jdevhome\jdev\dbc_files\]
    [062113_023121062][][EXCEPTION] [DEBUG]  [oracle.j2ee.http.socket.timeout]:[500]
    [062113_023121062][][EXCEPTION] [DEBUG]  [com.oracle.corba.ee.security.ssl.port]:[5659]
    [062113_023121062][][EXCEPTION] [DEBUG]  [JRAD_ELEMENT_LIST_PATH]:[C:\JDEV\jdevhome\jdev\myhtml\OA_HTML\jrad\]
    [062113_023121062][][EXCEPTION] [DEBUG]  [JTFDBCFILE]:[C:\JDEV\jdevhome\jdev\dbc_files\secure\dcap1.dbc]
    [062113_023121062][][EXCEPTION] [DEBUG]  [com.sun.CORBA.POA.ORBServerId]:[1000000]
    [062113_023121062][][EXCEPTION] [DEBUG]  [java.naming.factory.url.pkgs]:[oracle.oc4j.naming.url]
    [062113_023121078][][EXCEPTION] [DEBUG]  [user.home]:[C:\Documents and Settings\mysub]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.specification.vendor]:[Sun Microsystems Inc.]
    [062113_023121078][][EXCEPTION] [DEBUG]  [oracle.home]:[C:\JDEV\jdevbin]
    [062113_023121078][][EXCEPTION] [DEBUG]  [oracle.dms.sensors]:[5]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.library.path]:[C:\JDEV\jdevbin\jdk\bin;.;C:\WINNT\system32;C:\WINNT;D:\oracle\product\10.1.0\Db_1\bin;D:\oracle\product\10.1.0\Db_1\jre\1.4.2\bin\client;D:\oracle\product\10.1.0\Db_1\jre\1.4.2\bin;C:\WINNT\system32;C:\WINNT;C:\WINNT\System32\Wbem;C:\Program Files\Windows Imaging\;D:\oracle\product\10.1.0\Db_1\jdk\jre\bin;D:\oracle\product\10.1.0\Db_1\jdk\jre\bin\client;D:\oracle\product\10.1.0\Db_1\jlib;]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.vendor.url]:[http://java.sun.com/]
    [062113_023121078][][EXCEPTION] [DEBUG]  [javax.rmi.CORBA.StubClass]:[com.sun.corba.ee.impl.javax.rmi.CORBA.StubDelegateImpl]
    [062113_023121078][][EXCEPTION] [DEBUG]  [oracle.j2ee.dont.use.memory.archive]:[true]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.vm.vendor]:[Sun Microsystems Inc.]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.runtime.name]:[Java(TM) 2 Runtime Environment, Standard Edition]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.class.path]:[C:\JDEV\jdevbin\jdk\jre\lib\rt.jar;C:\JDEV\jdevbin\jdk\jre\lib\jsse.jar;C:\JDEV\jdevbin\jdk\jre\lib\jce.jar;C:\JDEV\jdevbin\jdk\jre\lib\charsets.jar;C:\JDEV\jdevbin\jdk\jre\lib\ext\dnsns.jar;C:\JDEV\jdevbin\jdk\jre\lib\ext\localedata.jar;C:\JDEV\jdevbin\jdk\jre\lib\ext\sunjce_provider.jar;C:\JDEV\jdevbin\jdk\jre\lib\ext\sunpkcs11.jar;C:\JDEV\jdevbin\j2ee\home\oc4j-api.jar;C:\JDEV\jdevbin\j2ee\home\lib\oc4j-unsupported-api.jar;C:\JDEV\jdevbin\j2ee\home\lib\activation.jar;C:\JDEV\jdevbin\j2ee\home\lib\mail.jar;C:\JDEV\jdevbin\j2ee\home\lib\persistence.jar;C:\JDEV\jdevbin\j2ee\home\lib\ejb30.jar;C:\JDEV\jdevbin\j2ee\home\lib\ejb.jar;C:\JDEV\jdevbin\j2ee\home\lib\javax77.jar;C:\JDEV\jdevbin\j2ee\home\lib\javax88.jar;C:\JDEV\jdevbin\j2ee\home\lib\servlet.jar;C:\JDEV\jdevbin\j2ee\home\lib\jms.jar;C:\JDEV\jdevbin\j2ee\home\lib\jta.jar;C:\JDEV\jdevbin\j2ee\home\lib\jacc-api.jar;C:\JDEV\jdevbin\j2ee\home\lib\connector.jar;C:\JDEV\jdevbin\j2ee\home\lib\jmx_remote_api.jar;C:\JDEV\jdevbin\j2ee\home\lib\jax-qname-namespace.jar;C:\JDEV\jdevbin\webservices\lib\jaxr-api.jar;C:\JDEV\jdevbin\webservices\lib\jaxrpc-api.jar;C:\JDEV\jdevbin\webservices\lib\saaj-api.jar;C:\JDEV\jdevbin\webservices\lib\jws-api.jar;C:\JDEV\jdevbin\j2ee\home\lib\oc4j-internal.jar;C:\JDEV\jdevbin\j2ee\home\lib\oems-jms-oc4j.jar;C:\JDEV\jdevbin\j2ee\home\lib\oems-jms-client.jar;C:\JDEV\jdevbin\j2ee\home\lib\oems-jms-server.jar;C:\JDEV\jdevbin\j2ee\home\lib\oc4j-schemas.jar;C:\JDEV\jdevbin\j2ee\home\lib\ojsp.jar;C:\JDEV\jdevbin\j2ee\home\lib\oc4j_orb.jar;C:\JDEV\jdevbin\j2ee\home\lib\iiop_support.jar;C:\JDEV\jdevbin\j2ee\home\lib\orbbase.jar;C:\JDEV\jdevbin\j2ee\home\iiop_gen_bin.jar;C:\JDEV\jdevbin\j2ee\home\lib\jmxcluster.jar;C:\JDEV\jdevbin\j2ee\home\jaccprovider.jar;C:\JDEV\jdevbin\javavm\lib\jasper.zip;C:\JDEV\jdevbin\j2ee\home\lib\adminclient.jar;C:\JDEV\jdevbin\opmn\lib\optic.jar;C:\JDEV\jdevbin\j2ee\home\jacc-spi.jar;C:\JDEV\jdevbin\j2ee\home\jazncore.jar;C:\JDEV\jdevbin\j2ee\home\jazn.jar;C:\JDEV\jdevbin\jlib\ospnego.jar;C:\JDEV\jdevbin\jlib\ldapjclnt10.jar;C:\JDEV\jdevbin\webservices\lib\wsserver.jar;C:\JDEV\jdevbin\webservices\lib\wsif.jar;C:\JDEV\jdevbin\webservices\lib\orawsmetadata.jar;C:\JDEV\jdevbin\webservices\lib\orajaxr.jar;C:\JDEV\jdevbin\jlib\jssl-1_1.jar;C:\JDEV\jdevbin\jlib\ojmisc.jar;C:\JDEV\jdevbin\toplink\jlib\toplink-oc4j.jar;C:\JDEV\jdevbin\diagnostics\lib\ojdl2.jar;C:\JDEV\jdevbin\xqs\lib\xqs-api.jar;C:\JDEV\jdevbin\xqs\lib\xds.jar;C:\JDEV\jdevbin\jdev\lib\jdev-oc4j-embedded.jar;C:\JDEV\jdevbin\j2ee\home\lib\pcl.jar;C:\JDEV\jdevbin\j2ee\home\lib\ext;C:\JDEV\jdevbin\lib\dmsapp.jar;C:\JDEV\jdevhome\jdev\system\oracle.j2ee.10.1.3.41.57\embedded-oc4j\applications\admin_ejb.jar;C:\JDEV\jdevbin\BC4J\lib\bc4jdomorcl.jar;C:\JDEV\jdevbin\jlib\jsp-el-api.jar;C:\JDEV\jdevbin\jlib\commons-el.jar;C:\JDEV\jdevbin\jlib\oracle-el.jar;C:\JDEV\jdevbin\jlib\jewt4.jar;C:\JDEV\jdevbin\jdev\appslibrt\regexp.jar;C:\JDEV\jdevbin\jdev\appslibrt\share.jar;C:\JDEV\jdevbin\jdev\appslibrt\uix2.jar;C:\JDEV\jdevbin\oaext\mds\lib\mdsrt.jar;C:\JDEV\jdevbin\oaext\lib\mdsdt.jar;C:\JDEV\jdevbin\oaext\lib\oamdsdt.jar;C:\JDEV\jdevbin\javacache\lib\cache.jar;C:\JDEV\jdevbin\lib\xschema.jar;C:\JDEV\jdevbin\BC4J\lib;C:\JDEV\jdevbin\BC4J\lib\adfbinding.jar;C:\JDEV\jdevbin\BC4J\lib\adfcm.jar;C:\JDEV\jdevbin\BC4J\lib\adfm.jar;C:\JDEV\jdevbin\BC4J\lib\adfmweb.jar;C:\JDEV\jdevbin\BC4J\lib\adfs-jazn.jar;C:\JDEV\jdevbin\BC4J\lib\adfs.jar;C:\JDEV\jdevbin\BC4J\lib\adfshare.jar;C:\JDEV\jdevbin\BC4J\lib\bc4jct.jar;C:\JDEV\jdevbin\BC4J\lib\bc4jctejb.jar;C:\JDEV\jdevbin\BC4J\lib\bc4jimdomains.jar;C:\JDEV\jdevbin\BC4J\lib\bc4jmt.jar;C:\JDEV\jdevbin\BC4J\lib\bc4jmtejb.jar;C:\JDEV\jdevbin\BC4J\lib\bc4jsyscat.jar;C:\JDEV\jdevbin\BC4J\lib\collections.jar;C:\JDEV\jdevbin\jdev\appslibrt\fwkjbo.zip;C:\JDEV\jdevbin\jdev\appslibrt\fwk.zip;C:\JDEV\jdevbin\jdev\appslibrt\atg.zip;C:\JDEV\jdevbin\jdev\appslibrt\collections.zip;C:\JDEV\jdevbin\jdev\appslibrt\iasjoc.zip;C:\JDEV\jdevbin\jdev\appslibrt\rosettaRt.zip;C:\JDEV\jdevbin\jdev\appslibrt\portalFlexComps.jar;C:\JDEV\jdevbin\jdev\appslibrt\svc.zip;C:\JDEV\jdevbin\jdev\appslibrt\pat.zip;C:\JDEV\jdevbin\jdev\appslibrt\concurrent.zip;C:\JDEV\jdevbin\jdev\appslibrt\oamMaintMode.zip;C:\JDEV\jdevbin\jdev\appslibrt\fwkCabo.zip;C:\JDEV\jdevbin\jdev\appslibrt\wsrp-container.jar;C:\JDEV\jdevbin\jdev\appslibrt\pdkjava.jar;C:\JDEV\jdevbin\jdev\appslibrt\ptlshare.jar;C:\JDEV\jdevbin\jdev\appslibrt\xml.jar;C:\JDEV\jdevbin\jdev\appslibrt\wsrp-container-types.jar;C:\JDEV\jdevbin\jdev\appslibrt\jaxb-impl.jar;C:\JDEV\jdevbin\jdev\appslibrt\jaxb-libs.jar;C:\JDEV\jdevbin\jdev\appslibrt\jazn.jar;C:\JDEV\jdevbin\jdev\appslibrt\jazncore.jar;C:\JDEV\jdevbin\bibeans\lib\biamlocal.jar;C:\JDEV\jdevbin\bibeans\lib\bipres.jar;C:\JDEV\jdevbin\bibeans\lib\bicmn.jar;C:\JDEV\jdevbin\bibeans\lib\bidatasvr.jar;C:\JDEV\jdevbin\bibeans\lib\bidataclt.jar;C:\JDEV\jdevbin\bibeans\lib\bidatacmn.jar;C:\JDEV\jdevbin\bibeans\lib\biext.jar;C:\JDEV\jdevbin\bibeans\lib\bicmn-nls.zip;C:\JDEV\jdevbin\bibeans\lib\bipres-nls.zip;C:\JDEV\jdevbin\bibeans\lib\bidata-nls.zip;C:\JDEV\jdevbin\oaext\config\oac\oacfilter.jar;C:\JDEV\jdevbin\j2ee\home\lib\scheduler.jar;C:\JDEV\jdevbin\jdev\lib\jdev-rt.jar;C:\JDEV\jdevbin\jdev\lib\ojc.jar;C:\JDEV\jdevhome\jdev\system\oracle.j2ee.10.1.3.41.57\embedded-oc4j\connectors\datasources\datasources\datasources.jar;C:\JDEV\jdevbin\diagnostics\lib\ojdl.jar;C:\JDEV\jdevbin\lib\dms.jar;C:\JDEV\jdevbin\jdbc\lib\ojdbc14dms.jar;C:\JDEV\jdevbin\opmn\lib\ons.jar;C:\JDEV\jdevbin\jdbc\lib\ocrs12.jar;C:\JDEV\jdevbin\rdbms\jlib\aqapi.jar;C:\JDEV\jdevbin\j2ee\home\lib\ojms-provider.jar;C:\JDEV\jdevbin\jdbc\lib\orai18n.jar;C:\JDEV\jdevbin\lib\xmlparserv2.jar;C:\JDEV\jdevbin\lib\xml.jar;C:\JDEV\jdevbin\lib\xmlmesg.jar;C:\JDEV\jdevbin\lib\xsu12.jar;C:\JDEV\jdevbin\lib\xquery.jar;C:\JDEV\jdevbin\jlib\osdt_core.jar;C:\JDEV\jdevbin\jlib\osdt_cert.jar;C:\JDEV\jdevbin\jlib\osdt_xmlsec.jar;C:\JDEV\jdevbin\jlib\osdt_wss.jar;C:\JDEV\jdevbin\jlib\osdt_saml.jar;C:\JDEV\jdevbin\jlib\ojpse.jar;C:\JDEV\jdevbin\jlib\oraclepki.jar;C:\JDEV\jdevbin\toplink\jlib\toplink.jar;C:\JDEV\jdevbin\toplink\jlib\antlr.jar;C:\JDEV\jdevbin\toplink\jlib\toplink-essentials.jar;C:\JDEV\jdevbin\webservices\lib\wsclient.jar;C:\JDEV\jdevbin\webservices\lib\orasaaj.jar;C:\JDEV\jdevbin\webservices\lib\xsdlib.jar;C:\JDEV\jdevbin\webservices\lib\mdds.jar;C:\JDEV\jdevbin\webservices\lib\relaxngDatatype.jar;C:\JDEV\jdevbin\webservices\lib\soap.jar;C:\JDEV\jdevbin\sqlj\lib\runtime12.jar;C:\JDEV\jdevbin\sqlj\lib\translator.jar;C:\JDEV\jdevbin\webservices\lib\orawsdl.jar;C:\JDEV\jdevbin\j2ee\home\applib;C:\JDEV\jdevbin\j2ee\home\jsp\lib\taglib;C:\JDEV\jdevbin\j2ee\home\jsp\lib\taglib\ojsputil.jar;C:\JDEV\jdevbin\lib\dsv2.jar;C:\JDEV\jdevbin\j2ee\home\lib\http_client.jar;C:\JDEV\jdevbin\j2ee\home\lib\jgroups-core.jar;C:\JDEV\jdevhome\jdev\myhtml\OA_HTML;C:\JDEV\jdevhome\jdev\myclasses;C:\JDEV\jdevbin\jlib\jdev-cm.jar;C:\JDEV\jdevbin\BC4J\jlib\bc4jhtml.jar;C:\JDEV\jdevbin\BC4J\jlib\datatags.jar;C:\JDEV\jdevbin\BC4J\jlib\bc4juixtags.jar;C:\JDEV\jdevbin\BC4J\jlib\graphtags.jar;C:\JDEV\jdevbin\jdev\appslibrt\wsp.zip;C:\JDEV\jdevbin\jdev\appslibrt\diagnostics.jar;C:\JDEV\jdevbin\jdev\appslibrt\svctester.jar]
    [062113_023121078][][EXCEPTION] [DEBUG]  [oracle.j2ee.home]:[C:\JDEV\jdevhome\jdev\system\oracle.j2ee.10.1.3.41.57\embedded-oc4j]
    [062113_023121078][][EXCEPTION] [DEBUG]  [oracle.application.environment]:[development]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.vm.specification.name]:[Java Virtual Machine Specification]
    [062113_023121078][][EXCEPTION] [DEBUG]  [JRAD_XML_PATH]:[C:\JDEV\jdevhome\jdev\myclasses\JRADXML;C:\JDEV\jdevhome\jdev\myprojects;C:\JDEV\jdevbin\jdev\oamdsxml\fwk]
    [062113_023121078][][EXCEPTION] [DEBUG]  [javax.rmi.CORBA.PortableRemoteObjectClass]:[com.sun.corba.ee.impl.javax.rmi.PortableRemoteObject]
    [062113_023121078][][EXCEPTION] [DEBUG]  [org.omg.PortableInterceptor.ORBInitializerClass.oracle.oc4j.corba.iiop.server.IIOPInitializer]:[NO_VALUE]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.vm.specification.version]:[1.0]
    [062113_023121078][][EXCEPTION] [DEBUG]  [sun.cpu.endian]:[little]
    [062113_023121078][][EXCEPTION] [DEBUG]  [oracle.j2ee.container.name]:[Oracle Containers for J2EE 10g (10.1.3.3.0) ]
    [062113_023121078][][EXCEPTION] [DEBUG]  [sun.os.patch.level]:[Service Pack 3]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.io.tmpdir]:[C:\DOCUME~1\mysub\Local Settings\Temp\]
    [062113_023121078][][EXCEPTION] [DEBUG]  [com.sun.jts.pi.CLIENT_POLICY_CHECKING]:[false]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.vendor.url.bug]:[http://java.sun.com/cgi-bin/bugreport.cgi]
    [062113_023121078][][EXCEPTION] [DEBUG]  [com.oracle.corba.ee.security.ssl.mutual.auth.port]:[5657]
    [062113_023121078][][EXCEPTION] [DEBUG]  [FND_JDBC_STMT_CACHE_SIZE]:[200]
    [062113_023121078][][EXCEPTION] [DEBUG]  [os.arch]:[x86]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.awt.graphicsenv]:[sun.awt.Win32GraphicsEnvironment]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.ext.dirs]:[C:\JDEV\jdevbin\jdk\jre\lib\ext]
    [062113_023121078][][EXCEPTION] [DEBUG]  [user.dir]:[C:\JDEV\jdevhome\jdev\system\oracle.j2ee.10.1.3.41.57\embedded-oc4j\config]
    [062113_023121078][][EXCEPTION] [DEBUG]  [CACHENODBINIT]:[true]
    [062113_023121078][][EXCEPTION] [DEBUG]  [line.separator]:[
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.vm.name]:[Java HotSpot(TM) Client VM]
    [062113_023121078][][EXCEPTION] [DEBUG]  [com.sun.CORBA.connection.ORBSocketFactoryClass]:[oracle.oc4j.corba.iiop.IIOPSSLSocketFactory]
    [062113_023121078][][EXCEPTION] [DEBUG]  [javax.management.builder.initial]:[oracle.oc4j.admin.jmx.server.Oc4jMBeanServerBuilder]
    [062113_023121078][][EXCEPTION] [DEBUG]  [com.oracle.corba.ee.security.use.ssl]:[false]
    [062113_023121078][][EXCEPTION] [DEBUG]  [org.omg.CORBA.ORBClass]:[com.sun.corba.ee.impl.orb.ORBImpl]
    [062113_023121078][][EXCEPTION] [DEBUG]  [file.encoding]:[Cp1252]
    [062113_023121078][][EXCEPTION] [DEBUG]  [java.specification.version]:[1.5]
    13/06/21 14:31:33 After exporting into excel sheet
    Here is my code which i have used to integrate the XML publisher:
    Code in AMImpl:
    public BlobDomain getXMLData(String user) {
    System.out.println("*** in getXMLData *** ");
    this.getOADBTransaction().writeDiagnostics(this, "*** in getXMLData ***",1);
    BlobDomain blobDomain = new BlobDomain();
    String dataDefCode = null;
    dataDefCode ="IDIS_OPENEDBYUSER_RPT";
    String dataDefApp = "SEAAR";
    try {
    System.out.println("in try b4 creating DT");
    this.getOADBTransaction().writeDiagnostics(this, "*** in try b4 creating DT ***",1);
    DataTemplate datatemplate = new DataTemplate(((OADBTransactionImpl)getOADBTransaction()).getAppsContext(),
    dataDefApp,
    dataDefCode);
    this.getOADBTransaction().writeDiagnostics(this, "*** after datatemplate ***",1);                                                   
    System.out.println("after datatemplate");
    Hashtable parameters = new Hashtable();
    parameters.put("p_last_rev", user);
    datatemplate.setParameters(parameters);   
    System.out.println("after set params");
    this.getOADBTransaction().writeDiagnostics(this, "*** after set params ***",1);
    datatemplate.setOutput(blobDomain.getOutputStream());
    System.out.println("after setOutput");
    this.getOADBTransaction().writeDiagnostics(this, "*** after setOutput***",1);
    datatemplate.processData();
    System.out.println("after processData" ); 
    this.getOADBTransaction().writeDiagnostics(this, "*** after processData***",1);
    System.out.println("blobDomain Value :"+blobDomain); 
    this.getOADBTransaction().writeDiagnostics(this,"blobDomain :: "+blobDomain,1 );
    return blobDomain;
    } catch (XDOException xdoe) {
    System.out.println("Exception in XDO :");
    throw new OAException("Exception in XDO : "+xdoe.getMessage());
    catch (SQLException sqle) {
    System.out.println("Exception in SQL :");
    throw new OAException("SQL Exception : "+sqle.getMessage());
    catch (OAException e) {
    System.out.println("Exception in OA :");
    throw new OAException("Unexpected Error :: " +e.getMessage());
    Code in Controller file:
    if (pageContext.getParameter("Export") != null)
    BlobDomain amBlobDomain ;
    String user = (String)pageContext.getTransientSessionValue("userName");
    System.out.println("User name before passing parameter to report"+user);
    Serializable[] param = { user};
    amBlobDomain = (BlobDomain)am.invokeMethod("getXMLData", param);
    Properties pdfproperties = new Properties();
    try
    DocumentHelper.exportDocument(pageContext,
    "SEAAR",
    "IDISPUTE_OPENEDBYUSER_RPT_TP",
    "en",
    "US",
    amBlobDomain.getInputStream(),
    "EXCEL",
    pdfproperties);  
    catch(Exception e) {
    System.out.println("Exception found in Document Helper");
    throw new OAException("Exception" + e.getMessage(),OAException.ERROR);
    System.out.println("After exporting into excel sheet");
    Thanks and Regards,
    Myvizhi

    Hi Peddi,
    I gave TRUNC to both of the dates. But still the same issue. I think the problem is in returning the BolbDomain.
    return blobDomain;
    } catch (XDOException xdoe) {
    System.out.println("Exception in XDO :");
    throw new OAException("Exception in XDO : "+xdoe.getMessage());
    catch (SQLException sqle) {
    System.out.println("Exception in SQL :");
    throw new OAException("SQL Exception : "+sqle.getMessage());
    catch (OAException e) {
    System.out.println("Exception in OA :");
    throw new OAException("Unexpected Error :: " +e.getMessage());
    Thanks and Regards,
    Myvizhi

  • Excel File read using WebUtil does not work. Gives java.lang.NoSuchMethodEr

    We have a form which reads from an Excel File. The form works in development env., but in the live env when we deployed the form it does not work. Form fails @ the 1st call to Client_OLE2 where we set the Excel file to read.
    For both the envs. the values are given here:
    (1.) Client Forms Version : Forms [32 Bit] Version 10.1.2.0.2 (Production)
    (2.) Application Server Version : 10.1.2.0.2
    (3.) AS Linux Version : (Live) RHEL 5.7 Tikanga / (Dev) Red Hat Enterprise Linux AS release 4 (Nahant Update 4)
    (4.) Client Sun JRE Version :Version 1.5.0 (build 1.5.0_10)
    (5.) Client Web Browser & Version: I.E 8.0.6001 or Mozilla  3.0.15
    (6.) WebUtil Version: 1.0.6Both envs. are the same except the Linux version.
    Works fine in Dev but does not work in Live. Other Webutil functions like file open dialog box works fine in live, only this Excel read is not working.
    Full Error message
    Java Plug-in 1.5.0_10
    Using JRE version 1.5.0_10 Java HotSpot(TM) Client VM
    User home directory = C:\Documents and Settings\dinesha.IIL
    c:   clear console window
    f:   finalize objects on finalization queue
    g:   garbage collect
    h:   display this help message
    l:   dump classloader list
    m:   print memory usage
    o:   trigger logging
    p:   reload proxy configuration
    q:   hide console
    r:   reload policy configuration
    s:   dump system and deployment properties
    t:   dump thread list
    v:   dump thread stack
    x:   clear classloader cache
    0-5: set trace level to <n>
    RegisterWebUtil - Loading WebUtil Version 1.0.6
    proxyHost=null
    proxyPort=0
    connectMode=HTTP, native.
    Forms Applet version is : 10.1.2.0
    Exception in thread "AWT-EventQueue-3" java.lang.NoSuchMethodError:
    com.jacob.com.Dispatch.put(Ljava/lang/Object;Ljava/lang/String;Ljava/lang/Object;)V
         at
    oracle.forms.webutil.ole.OleFunctions.set_obj_property(OleFunctions.java:1216)
         at
    oracle.forms.webutil.ole.OleFunctions.setProperty(OleFunctions.java:333)
         at oracle.forms.handler.ComponentItem.setCustomProperty(Unknown Source)
         at oracle.forms.handler.ComponentItem.onUpdate(Unknown Source)
         at oracle.forms.handler.JavaContainer.onUpdate(Unknown Source)
         at oracle.forms.handler.UICommon.onUpdate(Unknown Source)
         at oracle.forms.engine.Runform.onUpdateHandler(Unknown Source)
         at oracle.forms.engine.Runform.processMessage(Unknown Source)
         at oracle.forms.engine.Runform.processSet(Unknown Source)
         at oracle.forms.engine.Runform.onMessageReal(Unknown Source)
         at oracle.forms.engine.Runform.onMessage(Unknown Source)
         at oracle.forms.engine.Runform.processEventEnd(Unknown Source)
         at oracle.ewt.lwAWT.LWComponent.redispatchEvent(Unknown Source)
         at oracle.ewt.lwAWT.LWComponent.processEvent(Unknown Source)
         at java.awt.Component.dispatchEventImpl(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.EventQueue.dispatchEvent(Unknown Source)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown
    Source)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.run(Unknown Source)We connected to Live AS server via VPN and ran the Form in a client machine (where the Dev. is working) but same problem.
    Any help would be greatly appreciated.

    Channa,
    I sounds like you might have missed a configuration step on your Linux application server (AS). I recommend you go back through the configuration of your AS and verify each step of the WebUtil Runtime Setup Checklist was completed correctly. Seach the Forms Help system on "Runtime Setup Checklist" for a copy of the checklist.
    Hope this helps,
    Craig B-)
    If someone's response is helpful or correct, please mark it accordingly.

  • Buyer Beware!! No data plan when using Droid X as a hotspot!!

    I purchased the Droid X right when it came out and got the "unlimited" data and hotspot options.  I just received my first bill and it has $250 worth of data charges on it.  I called customer support and learned that hotspot data is not in the unlimited plan.  In fact, they do not offer a data plan for using the phone as a wifi hotspot  - it's pay as you go. 
    This was the whole reason I bought this phone - to get the hotspot.  I even turned in a wifi card I had with Sprint.  Even the customer support supervisor admitted it does not make any sense.  What a disaster..... #fail

    CaboWaboMan wrote:
    Yes, I am beginning to understand this now, they would not want someone selling mobile hotspot space.  Can someone give me some idea of what 2 gigs of data represents, I am having a bit of trouble wrapping my head around this.  This is going to be a pure convenience thing for me.  Example i'm on the road with my laptop and need to mod an excel, word or access doc on the fly and send it off...am I good to do this several times or do I wait till i'm home or in the hotel?
    Very interesting conversation all, I appreciate the input
    short but sweet....do not play wow thru your phone while driving
    CaboWaboMan> nice name btw.
    It's hard to fully judge how much data is used.  just surfing and sending emails would ammount to thousands of pages and text only emails before you hit 2 gigs.  But, once you start adding in attachments you will have to figure in the size of those attachements.  If you send 10 x 200MB files in a month, you've hit your limit on the attachments alone.
    I stream pandora 5 days a week for hours upon hours a day and I use about 2.5 gigs of data per month, plus web surfing.  If i download a bunch of files on my phone that number will bounce up tremendously. 
    So...likely the excel files ammount to a matter of Kbs so it shouldnt be a problem to stay WELL within that 2gb limit.  I personally don't think it is worth the extra 20 bucks a month for 2 extra gigs.  I would transfer my excel sheet to my phone via USB and then send it direct from the droid to my recipient.
    Dj 

  • ALV to Excel Sheet Problem

    Hello all,
    I am transferring the ALV output from SAP to Excel sheet using the standard button i.e. To Local FIle.... but i am not getting the text of the last column in the excel sheet. the last column is being displayed empty where as its heading is being displayed....
    Regards.
    Sabah...

    Go through the code and Execute it on your system, I think this will do for you.
    In this code I used 3 radio buttons in my selection screen:
    If u selects the first radio button your out put shows into to the Excel sheet.
    If u selects the second radio button your out put shows the in the Editor screen.
    If u clicks the third radio button your output shows into the Excel as well as in the Editor.
    *& DATA DECLARATION *
    TABLES: MARA, "GENERAL MASTER DATA
    MARC, "PLANT DATA FOR MATERIAL
    MARD, "STORAGE LOCATION DATA FOR MATERIAL
    MBEW, "MATERIAL VALUATION
    MVKE, "SALES DATA FOR MATERIAL
    MAKT, "MATERIAL DESCRIPTION
    EKKO, "PURCHASING DOCUMENT HEADER
    EKPO, "PURCHASING DOCUMENT ITEM
    VBAK, "SALES DOCUMENT HEADER DATA
    VBAP. "SALES DOCUMENT ITEM DATA
    TYPE-POOLS : SLIS.
    DATA: VT_FIELDCAT1 TYPE SLIS_T_FIELDCAT_ALV,
    V_FIELDCAT TYPE SLIS_FIELDCAT_ALV,
    V_LAYOUT TYPE SLIS_LAYOUT_ALV,
    BDCDATA LIKE BDCDATA OCCURS 0 WITH HEADER LINE,
    BEGIN OF I_MARA OCCURS 0,
    MATNR LIKE MARA-MATNR, "MATERIAL NUMBER
    MBRSH LIKE MARA-MBRSH, "INDUSTRY SECTOR
    MEINS LIKE MARA-MEINS, "BASE UNIT OF MEASURE
    MATKL LIKE MARA-MATKL, "MATERIAL GROUP
    END OF I_MARA,
    BEGIN OF I_MARC OCCURS 0,
    MATNR LIKE MARC-MATNR, "MATERIAL NUMBER
    WERKS LIKE MARC-WERKS, "PLANT
    LVORM LIKE MARC-LVORM, "FLAG MATERIAL FOR DELETION AT PLANT
    "LEVEL
    DISPO LIKE MARC-DISPO, "MRP CONTROLLER
    END OF I_MARC,
    BEGIN OF I_MAKT OCCURS 0,
    MATNR LIKE MAKT-MATNR, "MATERIAL NUMBER
    MAKTX LIKE MAKT-MAKTX, "MATERIAL DESCRIPTION
    SPRAS LIKE MAKT-SPRAS, "LANGUAGE KEY
    END OF I_MAKT,
    BEGIN OF I_MVKE OCCURS 0,
    MATNR LIKE MVKE-MATNR, "MATERIAL NUMBER
    VKORG LIKE MVKE-VKORG, "SALES ORGANIZATION
    VTWEG LIKE MVKE-VTWEG, "DISTRIBUTION CHANNEL
    END OF I_MVKE,
    BEGIN OF I_MARD OCCURS 0,
    MATNR LIKE MARD-MATNR, "MATERIAL NUMBER
    LGORT LIKE MARD-LGORT, "STORAGE LOCATION
    LABST LIKE MARD-LABST, "VALUATED STOCK WITH UNRESTRICTED USE
    END OF I_MARD,
    BEGIN OF I_EKPO OCCURS 0,
    EBELN LIKE EKPO-EBELN, "PURCHASING DOCUMENT NUMBER
    EBELP LIKE EKPO-EBELP, "ITEM NUMBER OF PURCHASING DOCUMENT
    MATNR LIKE EKPO-MATNR, "MATERIAL NUMBER
    END OF I_EKPO,
    BEGIN OF I_VBAP OCCURS 0,
    VBELN LIKE VBAP-VBELN, "SALES DOCUMENT
    POSNR LIKE VBAP-POSNR, "SALES DOCUMENT ITEM
    MATNR LIKE VBAP-MATNR, "MATERIAL NUMBER
    END OF I_VBAP,
    BEGIN OF I_OUT OCCURS 0,
    MATNR LIKE MARC-MATNR,
    WERKS LIKE MARC-WERKS,
    LVORM LIKE MARC-LVORM,
    DISPO LIKE MARC-DISPO,
    MBRSH LIKE MARA-MBRSH,
    MEINS LIKE MARA-MEINS,
    MATKL LIKE MARA-MATKL,
    VKORG LIKE MVKE-VKORG,
    VTWEG LIKE MVKE-VTWEG,
    SPRAS LIKE MAKT-SPRAS,
    MAKTX LIKE MAKT-MAKTX,
    LGORT LIKE MARD-LGORT,
    LABST LIKE MARD-LABST,
    EBELN LIKE EKPO-EBELN,
    EBELP LIKE EKPO-EBELP,
    VBELN LIKE VBAP-VBELN,
    POSNR LIKE VBAP-POSNR,
    END OF I_OUT,
    BEGIN OF I_HEADING OCCURS 0,
    TEXT1(20),
    TEXT2(20),
    TEXT3(20),
    TEXT4(20),
    TEXT5(20),
    TEXT6(20),
    TEXT7(20),
    TEXT8(20),
    TEXT9(20),
    TEXT10(20),
    TEXT11(40),
    TEXT12(20),
    TEXT13(20),
    TEXT14(20),
    TEXT15(20),
    TEXT16(20),
    TEXT17(20),
    END OF I_HEADING.
    *& S E L E C T I O N - S C R E E N *
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-100.
    SELECT-OPTIONS: S_MATNR FOR MARA-MATNR. "OBLIGATORY.
    PARAMETERS: P_WERKS LIKE MARC-WERKS. "OBLIGATORY.
    SELECT-OPTIONS: S_LGORT FOR MARD-LGORT,
    S_DISPO FOR MARC-DISPO,
    S_EBELN FOR EKPO-EBELN .
    SELECTION-SCREEN END OF BLOCK B1.
    SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-101.
    PARAMETERS : RB1 RADIOBUTTON GROUP G1,
    RB2 RADIOBUTTON GROUP G1,
    RB3 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN END OF BLOCK B2.
    *& S T A R T - O F - S E L E C T I O N *
    START-OF-SELECTION.
    SELECT MATNR WERKS LVORM DISPO FROM MARC
    INTO CORRESPONDING FIELDS OF TABLE I_MARC
    WHERE MATNR IN S_MATNR
    AND DISPO IN S_DISPO
    AND WERKS = P_WERKS.
    IF I_MARC[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA AVAILABLE FROM MARC'.
    EXIT.
    ENDIF.
    PERFORM PURCHASEDATA_VALIDATION.
    PERFORM SALESDATA_VALIDATION.
    SELECT MATNR LGORT LABST FROM MARD INTO TABLE I_MARD
    FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR
    AND WERKS EQ P_WERKS
    AND LGORT IN S_LGORT.
    IF I_MARD[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA AVAILABLE FROM MARD'.
    EXIT.
    ENDIF.
    SELECT MATNR VKORG VTWEG FROM MVKE INTO TABLE I_MVKE
    FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR.
    IF I_MVKE[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA AVAILABLE FROM MVKE'.
    EXIT.
    ENDIF.
    LOOP AT I_MARC.
    MOVE-CORRESPONDING I_MARC TO I_OUT.
    CLEAR MARC.
    SELECT SINGLE MATNR MBRSH MEINS MATKL FROM MARA
    INTO CORRESPONDING FIELDS OF MARA
    WHERE MATNR = I_OUT-MATNR.
    IF SY-SUBRC = 0.
    MOVE: MARA-MBRSH TO I_OUT-MBRSH,
    MARA-MEINS TO I_OUT-MEINS,
    MARA-MATKL TO I_OUT-MATKL.
    ELSE.
    CONTINUE.
    ENDIF.
    SELECT SINGLE MATNR MAKTX SPRAS FROM MAKT
    INTO CORRESPONDING FIELDS OF MAKT
    WHERE MATNR = I_OUT-MATNR.
    IF SY-SUBRC = 0.
    MOVE: MAKT-MAKTX TO I_OUT-MAKTX,
    MAKT-SPRAS TO I_OUT-SPRAS.
    ELSE.
    CONTINUE.
    ENDIF.
    LOOP AT I_EKPO WHERE MATNR = I_MARC-MATNR.
    MOVE: I_EKPO-EBELN TO I_OUT-EBELN,
    I_EKPO-EBELP TO I_OUT-EBELP.
    ENDLOOP.
    LOOP AT I_VBAP WHERE MATNR = I_MARC-MATNR.
    MOVE: I_VBAP-VBELN TO I_OUT-VBELN,
    I_VBAP-POSNR TO I_OUT-POSNR.
    ENDLOOP.
    LOOP AT I_MARD WHERE MATNR = I_MARC-MATNR.
    MOVE: I_MARD-LABST TO I_OUT-LABST,
    I_MARD-LGORT TO I_OUT-LGORT.
    ENDLOOP.
    LOOP AT I_MVKE WHERE MATNR = I_MARC-MATNR.
    MOVE: I_MVKE-VKORG TO I_OUT-VKORG,
    I_MVKE-VTWEG TO I_OUT-VTWEG.
    APPEND I_OUT.
    ENDLOOP.
    CLEAR I_OUT.
    ENDLOOP.
    PERFORM OPTIONS.
    FORM OPTIONS *
    FORM OPTIONS.
    IF RB2 = 'X'.
    PERFORM FIELDCAT.
    PERFORM OUTPUT.
    ELSE.
    IF RB1 = 'X'.
    PERFORM HEADINGS.
    PERFORM DLOAD.
    ELSE.
    IF RB3 = 'X'.
    PERFORM HEADINGS.
    PERFORM DLOAD.
    PERFORM FIELDCAT.
    PERFORM OUTPUT.
    ENDIF.
    ENDIF.
    ENDIF.
    ENDFORM. "OPTIONS
    FORM HEADINGS *
    FORM HEADINGS.
    I_HEADING-TEXT1 = 'MATNR'.
    I_HEADING-TEXT2 = 'WERKS'.
    I_HEADING-TEXT3 = 'LVORM'.
    I_HEADING-TEXT4 = 'DISPO'.
    I_HEADING-TEXT5 = 'MBRSH'.
    I_HEADING-TEXT6 = 'MEINS'.
    I_HEADING-TEXT7 = 'MATKL'.
    I_HEADING-TEXT8 = 'VKORG'.
    I_HEADING-TEXT9 = 'VTWEG'.
    I_HEADING-TEXT10 = 'SPRAS'.
    I_HEADING-TEXT11 = 'MAKTX'.
    I_HEADING-TEXT12 = 'LGORT'.
    I_HEADING-TEXT13 = 'LABST'.
    I_HEADING-TEXT14 = 'EBELN'.
    I_HEADING-TEXT15 = 'EBELP'.
    I_HEADING-TEXT16 = 'VBELN'.
    I_HEADING-TEXT17 = 'POSNR'.
    APPEND I_HEADING.
    ENDFORM. "HEADINGS
    FORM DLOAD *
    FORM DLOAD.
    CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
    FILENAME = 'C:\MATSTK.XLS'
    FILETYPE = 'DAT'
    WRITE_FIELD_SEPARATOR = 'X'
    TABLES
    DATA_TAB = I_HEADING
    EXCEPTIONS
    FILE_WRITE_ERROR = 1.
    CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
    FILENAME = 'C:\MATSTK.XLS'
    FILETYPE = 'DAT'
    APPEND = 'X'
    WRITE_FIELD_SEPARATOR = 'X'
    TABLES
    DATA_TAB = I_OUT.
    ENDFORM. "DLOAD
    FORM FIELDCAT *
    FORM FIELDCAT.
    V_FIELDCAT-COL_POS = '1'.
    V_FIELDCAT-FIELDNAME = 'MATNR'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-HOTSPOT = 'X'.
    V_FIELDCAT-REF_FIELDNAME = 'MATNR'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '2'.
    V_FIELDCAT-FIELDNAME = 'WERKS'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'WERKS'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '3'.
    V_FIELDCAT-FIELDNAME = 'LVORM'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'LVORM'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '4'.
    V_FIELDCAT-FIELDNAME = 'DISPO'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'DISPO'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '5'.
    V_FIELDCAT-FIELDNAME = 'MBRSH'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MBRSH'.
    V_FIELDCAT-REF_TABNAME = 'MARA'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '6'.
    V_FIELDCAT-FIELDNAME = 'MEINS'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MEINS'.
    V_FIELDCAT-REF_TABNAME = 'MARA'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '7'.
    V_FIELDCAT-FIELDNAME = 'MATKL'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MATKL'.
    V_FIELDCAT-REF_TABNAME = 'MARA'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '8'.
    V_FIELDCAT-FIELDNAME = 'VKORG'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'VKORG'.
    V_FIELDCAT-REF_TABNAME = 'MVKE'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '9'.
    V_FIELDCAT-FIELDNAME = 'VTWEG'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'VTWEG'.
    V_FIELDCAT-REF_TABNAME = 'MVKE'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '10'.
    V_FIELDCAT-FIELDNAME = 'SPRAS'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'SPRAS'.
    V_FIELDCAT-REF_TABNAME = 'MAKT'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '11'.
    V_FIELDCAT-FIELDNAME = 'MAKTX'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MAKTX'.
    V_FIELDCAT-REF_TABNAME = 'MAKT'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '12'.
    V_FIELDCAT-FIELDNAME = 'LGORT'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'LGORT'.
    V_FIELDCAT-REF_TABNAME = 'MARD'.
    V_FIELDCAT-SELTEXT_L = 'STRG LOCT'.
    V_FIELDCAT-OUTPUTLEN = 10.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '13'.
    V_FIELDCAT-FIELDNAME = 'LABST'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-SELTEXT_M = 'STOCK'.
    V_FIELDCAT-OUTPUTLEN = 15.
    V_FIELDCAT-REF_FIELDNAME = 'LABST'.
    V_FIELDCAT-REF_TABNAME = 'MARD'.
    V_FIELDCAT-DO_SUM = 'X'.
    V_LAYOUT-TOTALS_TEXT = 'TOTAL STOCK:'.
    V_FIELDCAT-HOTSPOT = 'X'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '14'.
    V_FIELDCAT-FIELDNAME = 'EBELN'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-HOTSPOT = 'X'.
    V_FIELDCAT-REF_FIELDNAME = 'EBELN'.
    V_FIELDCAT-REF_TABNAME = 'EKPO'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '15'.
    V_FIELDCAT-FIELDNAME = 'EBELP'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'EBELP'.
    V_FIELDCAT-REF_TABNAME = 'EKPO'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '16'.
    V_FIELDCAT-FIELDNAME = 'VBELN'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-HOTSPOT = 'X'.
    V_FIELDCAT-REF_FIELDNAME = 'VBELN'.
    V_FIELDCAT-REF_TABNAME = 'VBAP'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '17'.
    V_FIELDCAT-FIELDNAME = 'POSNR'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'POSNR'.
    V_FIELDCAT-REF_TABNAME = 'VBAP'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    ENDFORM. "FIELDCAT
    FORM OUTPUT *
    FORM OUTPUT.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
    I_CALLBACK_PROGRAM = SY-REPID
    I_CALLBACK_TOP_OF_PAGE = 'TOP-OF-PAGE'
    I_GRID_TITLE = 'CLICK ON MATERIAL/PURDOC/SALESDOC FOR DETAILS'
    I_CALLBACK_USER_COMMAND = 'DISPLAYDETAILS'
    IS_LAYOUT = V_LAYOUT
    IT_FIELDCAT = VT_FIELDCAT1
    TABLES
    T_OUTTAB = I_OUT.
    IF SY-SUBRC 0.
    ENDIF.
    ENDFORM. "OUTPUT
    FORM TOP-OF-PAGE *
    FORM TOP-OF-PAGE.
    DATA: T_HEADER TYPE SLIS_T_LISTHEADER,
    WA_HEADER TYPE SLIS_LISTHEADER.
    WA_HEADER-TYP = 'H'.
    WA_HEADER-INFO = 'REPORT FOR : '.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    WA_HEADER-TYP = 'S'.
    WA_HEADER-INFO = 'MATERIAL DETAILS'.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    WA_HEADER-TYP = 'S'.
    WA_HEADER-INFO = 'PURCHASE ORDER DETAILS'.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    WA_HEADER-TYP = 'S'.
    WA_HEADER-INFO = 'SALES ORDER DETAILS'.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
    EXPORTING
    I_LOGO = 'GEAR'
    IT_LIST_COMMENTARY = T_HEADER.
    ENDFORM. "TOP-OF-PAGE
    *& FORM PURCHASEDATA_VALIDATION *
    FORM PURCHASEDATA_VALIDATION.
    SELECT EBELN EBELP MATNR
    FROM EKPO
    INTO TABLE I_EKPO
    FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR
    AND EBELN IN S_EBELN
    AND WERKS EQ P_WERKS.
    IF I_EKPO[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA IS SELECTED FROM TABLE EKPO'.
    EXIT.
    ENDIF.
    DATA: T_EKPO LIKE I_EKPO OCCURS 0 WITH HEADER LINE.
    T_EKPO] = I_EKPO[.
    REFRESH I_EKPO.
    FREE I_EKPO.
    LOOP AT T_EKPO.
    SELECT SINGLE EBELN FROM EKKO INTO EKPO-EBELN
    WHERE EBELN = T_EKPO-EBELN.
    IF SY-SUBRC = 0.
    MOVE-CORRESPONDING T_EKPO TO I_EKPO.
    APPEND I_EKPO.
    CLEAR I_EKPO.
    ELSE.
    CONTINUE.
    ENDIF.
    ENDLOOP.
    SORT I_EKPO.
    ENDFORM. "PURCHASEDATA_VALIDATION
    *& FORM SALESDATA_VALIDATION *
    FORM SALESDATA_VALIDATION.
    SELECT VBELN POSNR MATNR
    FROM VBAP
    INTO CORRESPONDING FIELDS OF TABLE
    I_VBAP FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR.
    DATA: T_VBAP LIKE I_VBAP OCCURS 0 WITH HEADER LINE.
    T_VBAP] = I_VBAP[.
    REFRESH I_VBAP.
    FREE I_VBAP.
    LOOP AT T_VBAP.
    SELECT SINGLE VBELN FROM VBAK INTO VBAK-VBELN
    WHERE VBELN = T_VBAP-VBELN.
    IF SY-SUBRC = 0.
    MOVE-CORRESPONDING T_VBAP TO I_VBAP.
    APPEND I_VBAP.
    CLEAR I_VBAP.
    ELSE.
    CONTINUE.
    ENDIF.
    ENDLOOP.
    SORT I_VBAP.
    ENDFORM. "SALESDATA_VALIDATION

  • Regarding ALV report to output in excel

    How to do  ALV report to output in excel format?

    *& DATA DECLARATION *
    TABLES: MARA, "GENERAL MASTER DATA
    MARC, "PLANT DATA FOR MATERIAL
    MARD, "STORAGE LOCATION DATA FOR MATERIAL
    MBEW, "MATERIAL VALUATION
    MVKE, "SALES DATA FOR MATERIAL
    MAKT, "MATERIAL DESCRIPTION
    EKKO, "PURCHASING DOCUMENT HEADER
    EKPO, "PURCHASING DOCUMENT ITEM
    VBAK, "SALES DOCUMENT HEADER DATA
    VBAP. "SALES DOCUMENT ITEM DATA
    TYPE-POOLS : SLIS.
    DATA: VT_FIELDCAT1 TYPE SLIS_T_FIELDCAT_ALV,
    V_FIELDCAT TYPE SLIS_FIELDCAT_ALV,
    V_LAYOUT TYPE SLIS_LAYOUT_ALV,
    BDCDATA LIKE BDCDATA OCCURS 0 WITH HEADER LINE,
    BEGIN OF I_MARA OCCURS 0,
    MATNR LIKE MARA-MATNR, "MATERIAL NUMBER
    MBRSH LIKE MARA-MBRSH, "INDUSTRY SECTOR
    MEINS LIKE MARA-MEINS, "BASE UNIT OF MEASURE
    MATKL LIKE MARA-MATKL, "MATERIAL GROUP
    END OF I_MARA,
    BEGIN OF I_MARC OCCURS 0,
    MATNR LIKE MARC-MATNR, "MATERIAL NUMBER
    WERKS LIKE MARC-WERKS, "PLANT
    LVORM LIKE MARC-LVORM, "FLAG MATERIAL FOR DELETION AT PLANT
    "LEVEL
    DISPO LIKE MARC-DISPO, "MRP CONTROLLER
    END OF I_MARC,
    BEGIN OF I_MAKT OCCURS 0,
    MATNR LIKE MAKT-MATNR, "MATERIAL NUMBER
    MAKTX LIKE MAKT-MAKTX, "MATERIAL DESCRIPTION
    SPRAS LIKE MAKT-SPRAS, "LANGUAGE KEY
    END OF I_MAKT,
    BEGIN OF I_MVKE OCCURS 0,
    MATNR LIKE MVKE-MATNR, "MATERIAL NUMBER
    VKORG LIKE MVKE-VKORG, "SALES ORGANIZATION
    VTWEG LIKE MVKE-VTWEG, "DISTRIBUTION CHANNEL
    END OF I_MVKE,
    BEGIN OF I_MARD OCCURS 0,
    MATNR LIKE MARD-MATNR, "MATERIAL NUMBER
    LGORT LIKE MARD-LGORT, "STORAGE LOCATION
    LABST LIKE MARD-LABST, "VALUATED STOCK WITH UNRESTRICTED USE
    END OF I_MARD,
    BEGIN OF I_EKPO OCCURS 0,
    EBELN LIKE EKPO-EBELN, "PURCHASING DOCUMENT NUMBER
    EBELP LIKE EKPO-EBELP, "ITEM NUMBER OF PURCHASING DOCUMENT
    MATNR LIKE EKPO-MATNR, "MATERIAL NUMBER
    END OF I_EKPO,
    BEGIN OF I_VBAP OCCURS 0,
    VBELN LIKE VBAP-VBELN, "SALES DOCUMENT
    POSNR LIKE VBAP-POSNR, "SALES DOCUMENT ITEM
    MATNR LIKE VBAP-MATNR, "MATERIAL NUMBER
    END OF I_VBAP,
    BEGIN OF I_OUT OCCURS 0,
    MATNR LIKE MARC-MATNR,
    WERKS LIKE MARC-WERKS,
    LVORM LIKE MARC-LVORM,
    DISPO LIKE MARC-DISPO,
    MBRSH LIKE MARA-MBRSH,
    MEINS LIKE MARA-MEINS,
    MATKL LIKE MARA-MATKL,
    VKORG LIKE MVKE-VKORG,
    VTWEG LIKE MVKE-VTWEG,
    SPRAS LIKE MAKT-SPRAS,
    MAKTX LIKE MAKT-MAKTX,
    LGORT LIKE MARD-LGORT,
    LABST LIKE MARD-LABST,
    EBELN LIKE EKPO-EBELN,
    EBELP LIKE EKPO-EBELP,
    VBELN LIKE VBAP-VBELN,
    POSNR LIKE VBAP-POSNR,
    END OF I_OUT,
    BEGIN OF I_HEADING OCCURS 0,
    TEXT1(20),
    TEXT2(20),
    TEXT3(20),
    TEXT4(20),
    TEXT5(20),
    TEXT6(20),
    TEXT7(20),
    TEXT8(20),
    TEXT9(20),
    TEXT10(20),
    TEXT11(40),
    TEXT12(20),
    TEXT13(20),
    TEXT14(20),
    TEXT15(20),
    TEXT16(20),
    TEXT17(20),
    END OF I_HEADING.
    *& S E L E C T I O N - S C R E E N *
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-100.
    SELECT-OPTIONS: S_MATNR FOR MARA-MATNR. "OBLIGATORY.
    PARAMETERS: P_WERKS LIKE MARC-WERKS. "OBLIGATORY.
    SELECT-OPTIONS: S_LGORT FOR MARD-LGORT,
    S_DISPO FOR MARC-DISPO,
    S_EBELN FOR EKPO-EBELN .
    SELECTION-SCREEN END OF BLOCK B1.
    SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-101.
    PARAMETERS : RB1 RADIOBUTTON GROUP G1,
    RB2 RADIOBUTTON GROUP G1,
    RB3 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN END OF BLOCK B2.
    *& S T A R T - O F - S E L E C T I O N *
    START-OF-SELECTION.
    SELECT MATNR WERKS LVORM DISPO FROM MARC
    INTO CORRESPONDING FIELDS OF TABLE I_MARC
    WHERE MATNR IN S_MATNR
    AND DISPO IN S_DISPO
    AND WERKS = P_WERKS.
    IF I_MARC[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA AVAILABLE FROM MARC'.
    EXIT.
    ENDIF.
    PERFORM PURCHASEDATA_VALIDATION.
    PERFORM SALESDATA_VALIDATION.
    SELECT MATNR LGORT LABST FROM MARD INTO TABLE I_MARD
    FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR
    AND WERKS EQ P_WERKS
    AND LGORT IN S_LGORT.
    IF I_MARD[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA AVAILABLE FROM MARD'.
    EXIT.
    ENDIF.
    SELECT MATNR VKORG VTWEG FROM MVKE INTO TABLE I_MVKE
    FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR.
    IF I_MVKE[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA AVAILABLE FROM MVKE'.
    EXIT.
    ENDIF.
    LOOP AT I_MARC.
    MOVE-CORRESPONDING I_MARC TO I_OUT.
    CLEAR MARC.
    SELECT SINGLE MATNR MBRSH MEINS MATKL FROM MARA
    INTO CORRESPONDING FIELDS OF MARA
    WHERE MATNR = I_OUT-MATNR.
    IF SY-SUBRC = 0.
    MOVE: MARA-MBRSH TO I_OUT-MBRSH,
    MARA-MEINS TO I_OUT-MEINS,
    MARA-MATKL TO I_OUT-MATKL.
    ELSE.
    CONTINUE.
    ENDIF.
    SELECT SINGLE MATNR MAKTX SPRAS FROM MAKT
    INTO CORRESPONDING FIELDS OF MAKT
    WHERE MATNR = I_OUT-MATNR.
    IF SY-SUBRC = 0.
    MOVE: MAKT-MAKTX TO I_OUT-MAKTX,
    MAKT-SPRAS TO I_OUT-SPRAS.
    ELSE.
    CONTINUE.
    ENDIF.
    LOOP AT I_EKPO WHERE MATNR = I_MARC-MATNR.
    MOVE: I_EKPO-EBELN TO I_OUT-EBELN,
    I_EKPO-EBELP TO I_OUT-EBELP.
    ENDLOOP.
    LOOP AT I_VBAP WHERE MATNR = I_MARC-MATNR.
    MOVE: I_VBAP-VBELN TO I_OUT-VBELN,
    I_VBAP-POSNR TO I_OUT-POSNR.
    ENDLOOP.
    LOOP AT I_MARD WHERE MATNR = I_MARC-MATNR.
    MOVE: I_MARD-LABST TO I_OUT-LABST,
    I_MARD-LGORT TO I_OUT-LGORT.
    ENDLOOP.
    LOOP AT I_MVKE WHERE MATNR = I_MARC-MATNR.
    MOVE: I_MVKE-VKORG TO I_OUT-VKORG,
    I_MVKE-VTWEG TO I_OUT-VTWEG.
    APPEND I_OUT.
    ENDLOOP.
    CLEAR I_OUT.
    ENDLOOP.
    PERFORM OPTIONS.
    FORM OPTIONS *
    FORM OPTIONS.
    IF RB2 = 'X'.
    PERFORM FIELDCAT.
    PERFORM OUTPUT.
    ELSE.
    IF RB1 = 'X'.
    PERFORM HEADINGS.
    PERFORM DLOAD.
    ELSE.
    IF RB3 = 'X'.
    PERFORM HEADINGS.
    PERFORM DLOAD.
    PERFORM FIELDCAT.
    PERFORM OUTPUT.
    ENDIF.
    ENDIF.
    ENDIF.
    ENDFORM. "OPTIONS
    FORM HEADINGS *
    FORM HEADINGS.
    I_HEADING-TEXT1 = 'MATNR'.
    I_HEADING-TEXT2 = 'WERKS'.
    I_HEADING-TEXT3 = 'LVORM'.
    I_HEADING-TEXT4 = 'DISPO'.
    I_HEADING-TEXT5 = 'MBRSH'.
    I_HEADING-TEXT6 = 'MEINS'.
    I_HEADING-TEXT7 = 'MATKL'.
    I_HEADING-TEXT8 = 'VKORG'.
    I_HEADING-TEXT9 = 'VTWEG'.
    I_HEADING-TEXT10 = 'SPRAS'.
    I_HEADING-TEXT11 = 'MAKTX'.
    I_HEADING-TEXT12 = 'LGORT'.
    I_HEADING-TEXT13 = 'LABST'.
    I_HEADING-TEXT14 = 'EBELN'.
    I_HEADING-TEXT15 = 'EBELP'.
    I_HEADING-TEXT16 = 'VBELN'.
    I_HEADING-TEXT17 = 'POSNR'.
    APPEND I_HEADING.
    ENDFORM. "HEADINGS
    FORM DLOAD *
    FORM DLOAD.
    CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
    FILENAME = 'C:\MATSTK.XLS'
    FILETYPE = 'DAT'
    WRITE_FIELD_SEPARATOR = 'X'
    TABLES
    DATA_TAB = I_HEADING
    EXCEPTIONS
    FILE_WRITE_ERROR = 1.
    CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
    FILENAME = 'C:\MATSTK.XLS'
    FILETYPE = 'DAT'
    APPEND = 'X'
    WRITE_FIELD_SEPARATOR = 'X'
    TABLES
    DATA_TAB = I_OUT.
    ENDFORM. "DLOAD
    FORM FIELDCAT *
    FORM FIELDCAT.
    V_FIELDCAT-COL_POS = '1'.
    V_FIELDCAT-FIELDNAME = 'MATNR'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-HOTSPOT = 'X'.
    V_FIELDCAT-REF_FIELDNAME = 'MATNR'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '2'.
    V_FIELDCAT-FIELDNAME = 'WERKS'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'WERKS'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '3'.
    V_FIELDCAT-FIELDNAME = 'LVORM'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'LVORM'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '4'.
    V_FIELDCAT-FIELDNAME = 'DISPO'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'DISPO'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '5'.
    V_FIELDCAT-FIELDNAME = 'MBRSH'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MBRSH'.
    V_FIELDCAT-REF_TABNAME = 'MARA'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '6'.
    V_FIELDCAT-FIELDNAME = 'MEINS'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MEINS'.
    V_FIELDCAT-REF_TABNAME = 'MARA'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '7'.
    V_FIELDCAT-FIELDNAME = 'MATKL'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MATKL'.
    V_FIELDCAT-REF_TABNAME = 'MARA'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '8'.
    V_FIELDCAT-FIELDNAME = 'VKORG'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'VKORG'.
    V_FIELDCAT-REF_TABNAME = 'MVKE'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '9'.
    V_FIELDCAT-FIELDNAME = 'VTWEG'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'VTWEG'.
    V_FIELDCAT-REF_TABNAME = 'MVKE'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '10'.
    V_FIELDCAT-FIELDNAME = 'SPRAS'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'SPRAS'.
    V_FIELDCAT-REF_TABNAME = 'MAKT'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '11'.
    V_FIELDCAT-FIELDNAME = 'MAKTX'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MAKTX'.
    V_FIELDCAT-REF_TABNAME = 'MAKT'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '12'.
    V_FIELDCAT-FIELDNAME = 'LGORT'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'LGORT'.
    V_FIELDCAT-REF_TABNAME = 'MARD'.
    V_FIELDCAT-SELTEXT_L = 'STRG LOCT'.
    V_FIELDCAT-OUTPUTLEN = 10.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '13'.
    V_FIELDCAT-FIELDNAME = 'LABST'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-SELTEXT_M = 'STOCK'.
    V_FIELDCAT-OUTPUTLEN = 15.
    V_FIELDCAT-REF_FIELDNAME = 'LABST'.
    V_FIELDCAT-REF_TABNAME = 'MARD'.
    V_FIELDCAT-DO_SUM = 'X'.
    V_LAYOUT-TOTALS_TEXT = 'TOTAL STOCK:'.
    V_FIELDCAT-HOTSPOT = 'X'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '14'.
    V_FIELDCAT-FIELDNAME = 'EBELN'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-HOTSPOT = 'X'.
    V_FIELDCAT-REF_FIELDNAME = 'EBELN'.
    V_FIELDCAT-REF_TABNAME = 'EKPO'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '15'.
    V_FIELDCAT-FIELDNAME = 'EBELP'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'EBELP'.
    V_FIELDCAT-REF_TABNAME = 'EKPO'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '16'.
    V_FIELDCAT-FIELDNAME = 'VBELN'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-HOTSPOT = 'X'.
    V_FIELDCAT-REF_FIELDNAME = 'VBELN'.
    V_FIELDCAT-REF_TABNAME = 'VBAP'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '17'.
    V_FIELDCAT-FIELDNAME = 'POSNR'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'POSNR'.
    V_FIELDCAT-REF_TABNAME = 'VBAP'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    ENDFORM. "FIELDCAT
    FORM OUTPUT *
    FORM OUTPUT.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
    I_CALLBACK_PROGRAM = SY-REPID
    I_CALLBACK_TOP_OF_PAGE = 'TOP-OF-PAGE'
    I_GRID_TITLE = 'CLICK ON MATERIAL/PURDOC/SALESDOC FOR DETAILS'
    I_CALLBACK_USER_COMMAND = 'DISPLAYDETAILS'
    IS_LAYOUT = V_LAYOUT
    IT_FIELDCAT = VT_FIELDCAT1
    TABLES
    T_OUTTAB = I_OUT.
    IF SY-SUBRC 0.
    ENDIF.
    ENDFORM. "OUTPUT
    FORM TOP-OF-PAGE *
    FORM TOP-OF-PAGE.
    DATA: T_HEADER TYPE SLIS_T_LISTHEADER,
    WA_HEADER TYPE SLIS_LISTHEADER.
    WA_HEADER-TYP = 'H'.
    WA_HEADER-INFO = 'REPORT FOR : '.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    WA_HEADER-TYP = 'S'.
    WA_HEADER-INFO = 'MATERIAL DETAILS'.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    WA_HEADER-TYP = 'S'.
    WA_HEADER-INFO = 'PURCHASE ORDER DETAILS'.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    WA_HEADER-TYP = 'S'.
    WA_HEADER-INFO = 'SALES ORDER DETAILS'.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
    EXPORTING
    I_LOGO = 'GEAR'
    IT_LIST_COMMENTARY = T_HEADER.
    ENDFORM. "TOP-OF-PAGE
    *& FORM PURCHASEDATA_VALIDATION *
    FORM PURCHASEDATA_VALIDATION.
    SELECT EBELN EBELP MATNR
    FROM EKPO
    INTO TABLE I_EKPO
    FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR
    AND EBELN IN S_EBELN
    AND WERKS EQ P_WERKS.
    IF I_EKPO[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA IS SELECTED FROM TABLE EKPO'.
    EXIT.
    ENDIF.
    DATA: T_EKPO LIKE I_EKPO OCCURS 0 WITH HEADER LINE.
    T_EKPO] = I_EKPO[.
    REFRESH I_EKPO.
    FREE I_EKPO.
    LOOP AT T_EKPO.
    SELECT SINGLE EBELN FROM EKKO INTO EKPO-EBELN
    WHERE EBELN = T_EKPO-EBELN.
    IF SY-SUBRC = 0.
    MOVE-CORRESPONDING T_EKPO TO I_EKPO.
    APPEND I_EKPO.
    CLEAR I_EKPO.
    ELSE.
    CONTINUE.
    ENDIF.
    ENDLOOP.
    SORT I_EKPO.
    ENDFORM. "PURCHASEDATA_VALIDATION
    *& FORM SALESDATA_VALIDATION *
    FORM SALESDATA_VALIDATION.
    SELECT VBELN POSNR MATNR
    FROM VBAP
    INTO CORRESPONDING FIELDS OF TABLE
    I_VBAP FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR.
    DATA: T_VBAP LIKE I_VBAP OCCURS 0 WITH HEADER LINE.
    T_VBAP] = I_VBAP[.
    REFRESH I_VBAP.
    FREE I_VBAP.
    LOOP AT T_VBAP.
    SELECT SINGLE VBELN FROM VBAK INTO VBAK-VBELN
    WHERE VBELN = T_VBAP-VBELN.
    IF SY-SUBRC = 0.
    MOVE-CORRESPONDING T_VBAP TO I_VBAP.
    APPEND I_VBAP.
    CLEAR I_VBAP.
    ELSE.
    CONTINUE.
    ENDIF.
    ENDLOOP.
    SORT I_VBAP.
    ENDFORM. "SALESDATA_VALIDATION

  • Hyperlink in ALV output and when downloaded to Excel, maintain that hyperli

    Hi SAP Friends,
    I want to know if this is possible. My requirement is, display a column with Invoice # and hyperlink (or you can call it as Hotspot in SAP language). When clicked on the hyperlink, it should open a webpage, giving details of Invoice. I tried testing BCALV_GRID_VERIFY program. I can see hyperlink in ALV output and when I click, it opens a webpage. However, when I down load data to Excel using Excel inplace, hyperlink is gone. Only data is down loaded. How can we make it happen that hyperlink is maintained even after downloading data from ALV ?
    Any ideas ?
    Niranjan

    Waiting for any suggestions from users.
    Niranjan

  • Short Dump when downloading to EXCEL from ALV

    Hi,
    I have an ALV grid display program. The data in the grid is displayed correctly. But when trying to download the data to excel it gives a short dump.
    Assignment error: Overwriting a protected field.
    What happened?
    Error in ABAP application program.
    The current ABAP program "SAPLKKBL" had to be terminated because one of the
    statements could not be executed.
    This is probably due to an error in the ABAP program.
    Some times it allows to download the data, but sometimes it gives short dump.
    Thanks,
    Deepthi

    This is my part of the code:
      i_fieldcat-key     = gc_x.
      i_fieldcat-no_zero = gc_x.
      i_fieldcat-fix_column  = 'X'.
      i_fieldcat-hotspot = gc_x.
      perform bild_fieldcat using
        '' 'AUFNR' 'GT_REPORT ' ' '  'CAUFV'  ' '  'C' '12' ' '.
      perform bild_fieldcat using
        '' 'DISGR' 'GT_REPORT ' ' '  'MARC' ' '  'C' '4' ' '.
      perform bild_fieldcat using
        '' 'AUART' 'GT_REPORT ' ' '  'CAUFV' ' '  'C' '04' ' '.
      perform bild_fieldcat using
        '' 'DISPO' 'GT_REPORT ' ' '  'CAUFV' ' ' 'C' '06' ' '.
      i_fieldcat-no_zero = gc_x.
      perform bild_fieldcat using
        '' 'MATNR' 'GT_REPORT ' ' '  'MARA' ' '  'C' '18' ' '.
      i_fieldcat-no_zero = gc_x.
      perform bild_fieldcat using
        '' 'CHARG' 'GT_REPORT ' ' '  'MDFA' ' ' 'C' '14' ' ' .
    *begin insert RCHALASA
      i_fieldcat-no_zero = gc_x.
      i_fieldcat-fix_column  = 'X'.
      perform bild_fieldcat using
        '' 'FTRMI' 'GT_REPORT ' ' '  'CAUFV' ' ' 'D' '08' ' '.
    *end insert
      i_fieldcat-no_zero = gc_x.
      i_fieldcat-fix_column  = 'X'.
      perform bild_fieldcat using
        '' 'GLTRP' 'GT_REPORT ' ' '  'CAUFV'  ' '  'D' '10' ' '.
      i_fieldcat-no_zero = gc_x.
      perform bild_fieldcat using
        '' 'GLTRS' 'GT_REPORT' ' '  'CAUFV' ' ' 'D' '10' ' '.
      perform bild_fieldcat using
        '' 'GSTRP' 'GT_REPORT' ' '  'CAUFV' ' '  'D' '10' ' '.
      perform bild_fieldcat using
        '' 'AGE' 'GT_REPORT' ' '  ' ' 'Age'  'C' '08' ' '.
      i_fieldcat-no_zero = gc_x.
    i_fieldcat-do_sum  = gc_x.
      i_fieldcat-fix_column  = 'X'.
      perform assign_alv_qty_format.
      perform bild_fieldcat using
        '' 'GAMNG' 'GT_REPORT' ' '  ' '  'Order Qty'  'QUAN' '09' ' '.
      perform bild_fieldcat using
        '' 'STK_PROD_FLAG' 'GT_REPORT' ' '   ' '  'Stk/Prod'  'C' '06' ' '.
      i_fieldcat-no_zero = gc_x.
    i_fieldcat-do_sum  = gc_x.
      i_fieldcat-fix_column  = 'X'.
      perform assign_alv_qty_format.
      perform bild_fieldcat using
        '' 'IGMNG' 'GT_REPORT' ' '  ' ' 'Order Yield Qty' 'QUAN' '11' ' '.
      i_fieldcat-no_zero = gc_x.
    i_fieldcat-do_sum  = gc_x.
      i_fieldcat-fix_column  = 'X'.
      perform assign_alv_qty_format.
      perform bild_fieldcat using
        '' 'IASMG' 'GT_REPORT' ' ' ' ' 'Order Scrap Qty'  'QUAN' '11' ' '.
    **begin insert RCHALASA
      perform bild_fieldcat using
         '' 'YIELD_PER' 'GT_REPORT' ' ' ' ' 'Yield'  'C' '05' ' '.
    **end insert
    DATA: col_pos like sy-colno.
    col_pos = '17'.
      loop at gt_oper.
        gv_tabix = sy-tabix.
        i_fieldcat-no_zero = gc_x.
        i_fieldcat-do_sum  = gc_x.
        i_fieldcat-fix_column  = 'X'.
       col_pos = col_pos + 1.
        perform assign_alv_qty_format.
        gv_yield6(03) = gt_oper-vornr1(03).
    *begin insert RCHALASA
        move gt_oper-ltxa1 to gv_text.
      translate gv_text to upper case.
    gv_text = gv_yield.
    *end insert
        gv_tabixn = gv_tabix.
        gv_yield+6(03) = gv_tabixn.
        gv_fieldname = gv_yield.
        translate gv_fieldname to upper case.
        perform bild_fieldcat using
         '' gv_fieldname 'GT_REPORT' ' ' ' ' gv_text  'QUAN' '04' ' '.
       perform assign_alv_qty_format.
      gv_scrap6(03) = gt_oper-vornr1(03).
      select single
             grdtx
             from trugt
             into gv_text1
             where
             grund = gt_oper-vornr
             and werks in s_werks.
       gv_text = gv_scrap.
       i_fieldcat-no_zero = gc_x.
       gv_tabixn = gv_tabix.
      gv_scrap+6(03) = gv_tabixn.
       gv_fieldname = gv_scrap.
       translate gv_fieldname to upper case.
       perform bild_fieldcat using
         gv_fieldname 'GT_REPORT' ' ' gv_text1 'X' 'QUAN' '08' ' '.
       clear gv_text1.
      endloop.  " GT_OPER
      DATA: count type c.
      DESCRIBE table gt_grund lines count.
      loop at gt_grund into gl_grund.
        gv_tabix = sy-tabix.
        i_fieldcat-no_zero = gc_x.
        i_fieldcat-do_sum  = gc_x.
        i_fieldcat-fix_column  = 'X'.
        perform assign_alv_qty_format.
        if gl_grund-grund is initial.
          gl_grund = 'NONE'.
          gv_text = gl_grund.
        else.
           gv_text = gl_grund-grdtx.
        endif.
        gv_tabixn = gv_tabix.
        gv_scrap_code+11(03) = gv_tabixn.
        gv_fieldname = gv_scrap_code.
        translate gv_fieldname to upper case.
       col_pos = col_pos + 1.
        perform bild_fieldcat using
          '' gv_fieldname 'GT_REPORT' 'XMNGA' 'AFRU'  gv_text  'QUAN' '12' ' ' .
      endloop.  " GT_OPER
      gb_layout-zebra = 'X'.
      gb_print-no_print_listinfos = 'X'.
      gb_variant-variant = p_varia.
      perform create_events using gt_events[].
      call function 'SAPGUI_PROGRESS_INDICATOR'
        EXPORTING
          text = 'Reading SAP Records.......'(600).
      call function 'REUSE_ALV_GRID_DISPLAY'
           exporting
                i_callback_program       = gv_repid
                i_callback_top_of_page   = 'TOP_OF_PAGE'
               i_callback_pf_status_set = 'SET_STATUS'
                i_callback_user_command  = 'CALL_UP_SAP_TRANS'
                it_fieldcat              = i_fieldcat[]
                is_layout                = gb_layout
                i_grid_title             = gb_title
                i_default                = 'X'
                i_save                   = 'X'
                is_variant               = gb_variant
                is_print                 = gb_print
                it_events                = gt_events[]
           tables
                t_outtab                 = gt_report
           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.
    ***********ALV SUBROUTINE**************
    TYPE-POOLS: slis.
    DATA: gv_repid            LIKE sy-repid.
    DATA: i_fieldcat          TYPE slis_t_fieldcat_alv WITH HEADER LINE.
    DATA: gb_layout           TYPE slis_layout_alv.
    DATA: gb_selfield         TYPE slis_selfield.
    DATA: gb_print            TYPE slis_print_alv.
    DATA: i_sort              TYPE  slis_t_sortinfo_alv WITH HEADER LINE.
    DATA: gv_keyinfo          TYPE SLIS_KEYINFO_ALV.
    DATA: gb_variant          LIKE disvariant,
          gb_def_variant      LIKE disvariant.
    DATA: gb_title(70).
    DATA: gt_events           TYPE slis_t_event,
          gt_sort             TYPE SLIS_T_SORTINFO_ALV,
          gt_list_top_of_page TYPE slis_t_listheader,
          g_status_set        TYPE slis_formname VALUE 'PF_STATUS_SET',
          g_user_command      TYPE slis_formname VALUE 'USER_COMMAND',
          g_top_of_page       TYPE slis_formname VALUE 'TOP_OF_PAGE',
          g_end_of_page       TYPE slis_formname VALUE 'END_OF_PAGE',
          g_top_of_list       TYPE slis_formname VALUE 'TOP_OF_LIST',
          g_end_of_list       TYPE slis_formname VALUE 'END_OF_LIST'.
    DATA: it_event_exit TYPE slis_t_event_exit WITH HEADER LINE.
    *--- Rotinas ---
    FORM alv_init.
      CLEAR: gb_variant.
      gv_repid = sy-repid.
      gb_variant-report = gv_repid.
      CALL FUNCTION 'REUSE_ALV_VARIANT_DEFAULT_GET'
           EXPORTING
                i_save     = 'A'
           CHANGING
                cs_variant = gb_variant
           EXCEPTIONS
                not_found  = 2.
      IF sy-subrc = 0.
        p_varia = gb_variant-variant.
      ENDIF.
    ENDFORM.                    " ALV_INIT
    FORM alv_f4.
      gb_variant-report = gv_repid.
      CALL FUNCTION 'REUSE_ALV_VARIANT_F4'
           EXPORTING
                is_variant = gb_variant
                i_save     = 'A'
           IMPORTING
                es_variant = gb_variant
           EXCEPTIONS
                not_found  = 2.
      IF sy-subrc = 2.
        MESSAGE ID sy-msgid TYPE 'S' NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ELSE.
        p_varia = gb_variant-variant.
      ENDIF.
    ENDFORM.                                                    " ALV_F4
    FORM bild_fieldcat USING x_pos x_field x_tab x_reffld x_ref x_text x_type x_tam x_sym.
      i_fieldcat-col_pos       = x_pos.
      i_fieldcat-fieldname     = x_field.
      i_fieldcat-tabname       = x_tab.
      i_fieldcat-ref_fieldname = x_reffld.
      i_fieldcat-ref_tabname   = x_ref.
      i_fieldcat-seltext_l     = x_text.
      i_fieldcat-seltext_m     = x_text.
      i_fieldcat-seltext_s     = x_text.
      i_fieldcat-ddictxt  = 'M'   .
      i_fieldcat-inttype       = x_type.
      i_fieldcat-outputlen     = x_tam.
      i_fieldcat-symbol        = x_sym.
      APPEND i_fieldcat.
      CLEAR  i_fieldcat.
    ENDFORM.                    " BILD_FIELDCAT
    FORM create_events USING rt_events TYPE slis_t_event.
      DATA: ls_event TYPE slis_alv_event.
      CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
           EXPORTING
                i_list_type = 0
           IMPORTING
                et_events   = rt_events.
      READ TABLE rt_events WITH KEY name = slis_ev_top_of_page
                               INTO ls_event.
      IF sy-subrc = 0.
        MOVE g_top_of_page TO ls_event-form.
        APPEND ls_event TO rt_events.
      ENDIF.
    ENDFORM.                    "

  • Leading spaces in excel file from ALV

    Hi Guys,
    once I export a record from ALV to excel. Some values I think all values that are TYPE I. How can I remove this leading spaces.
    Ex: '                                                      100'
    something like that.. so if you dont expand the column with you wont see the value 100. I checked the internal table being passed to ALV. It doesnt have leading spaces also in the ALV display. there is no leading spaces. Is there something to to with column width optimization? I need this to optimize the column headers. Thanks in Advance!
    Regards,
    Michael Nacionales

    There is one table CRVS_B with field SFHNR, while creating PRTS I need this field, so I do like this:
    select max( SFHNR ) into l_sfhnr
    from CRVS_B.
    add var to l_sfhnr.
    So for example l_sfhnr is equal to 000000000000000010, then after add, it gives me 11, and surprisingly in database 11 is placing position in such a way that last char is empty so it is not 11 but 00000000000000011 ( 17 chars ) as after 11 one empty space, and when it comes next time:
    select max( SFHNR ) into l_sfhnr
    from CRVS_B.
    add var to l_sfhnr.
    the value of l_sfhnr is still 000000000000000010......
    else try this
    Hi
    Field_catalog:
    Field catalog with field descriptions
    2.7.1. Description
    Field catalog containing descriptions of the list output fields (usually a subset of the internal output table fields). A field catalog is required for every ALV list output.
    The field catalog for the output table is built-up in the caller's coding. The build-up can be completely or partially automated by calling the REUSE_ALV_FIELDCATALOG_MERGE module
    See also the documentation of the function module REUSE_ALV_FIELDCATALOG_MERGE.
    The minimal field catalog is documented under 'default'. The caller can use the other optional parameters to assign output attributes to a field which differ from the default.
    A field catalog need not be built-up and passed explicitly only under the following conditions:
    • The internal table to be output has the same structure as a Data Dictionary structure which is referred to in the internal table declaration using LIKE or INCLUDE STRUCTURE.
    • all fields in this structure are to be output
    • the structure name is passed to ALV in the parameter I_STRUCTURE_NAME.
    See also the documentation of the IMPORTING paramter I_STRUCTURE_NAME.
    Positioning
    • row_pos (row position)
    value set: 0, 1 - 3
    Only relevant if the list output is to be multi-line (two or three lines) by default.
    A multi-line list can also be defined by the user interactively if the default list is one-line.
    The parameter specifies the relative output line of the column in a multi-line list.
    • col_pos (column position)
    value set: 0, 1 - 60
    only relevant when the default relative column positions differ from the field catalog field sequence. The parameter specifies the relative column position of the field in the list output. The column order can be changed interactively by the user. If this parameter is initial for all field catalog entries, columns appear in the field catalog field sequence.
    Identification
    • fieldname (field name)
    value set: internal output table field name (required parameter)
    Name of the internal output table field which is described by this field catalog entry
    • tabname (internal output table)
    value set: SPACE, internal output table name
    This parameter is used in 'manual' field catalog build-up only for hierarchical-sequential lists.
    Name of the internal output table which contains the field FIELDCAT-FIELDNAME.
    Data Dictionary reference
    • ref_fieldname (reference field name)
    value set: SPACE, Data Dictionary field name
    Name of the Data Dictionary field referred to.
    This parameter is only used when the internal output table field described by the current field catalog entry has a reference to the Data Dictionary (not a program field), and the field name in the internal output table is different from the name of the field in the Data Dictionary. If the field names are identical, naming the Data Dictionary structure or table in the FIELDCAT-REF_TABNAME parameter is sufficient.
    • ref_tabname (reference table/structure field name)
    value set: SPACE, name of a Data Dictionary structure or table
    Structure or table name of the referred Data Dictionary field.
    This parameter is only used when the internal output table field described by the current field catalog entry has a Data Dictionary reference (not a program field).
    Reference to fields with currency/measurement unit
    Each internal output table sum or quantity field whose decimal places are to be formatted appropriately for the unit in the list must follow the convention:
    • the field is of data type QUAN or CURR (internal type P) (the field must really have this physical data type. Overwriting the physical data type with the parameter FIELDCAT-DATATYPE has no effect)
    • There is a field in the internal output table which contains the associated unit.
    • There is also an entry in the field catalog for the unit field.
    (If the unit is not to appear as a column in the list, and cannot be interactively displayed as a column, e.g. because it is always unambiguous and is therefore explicitly output by the caller in the list header, the field catalog units field entry can take the parameter FIELDCAT-TECH = 'X'.
    The association of a value field to a unit affects the output as follows:
    • appropriate decimal places display for the unit
    • an initialized field with a link to a non-initial unit is output as '0' for the unit (if FIELDCAT-NO_ZERO is initial). When this field is summed, this unit affects whether the units are homogeneous.
    • an initialized field with a link to an initial unit is output as SPACE. When this field is summed, the unit SPACE does not affect the homogeneity of the units.
    • When non-initial fields with an initial unit are summed, the unit SPACE is considered to be a unit.
    Link to currency unit
    • cfieldname (currency unit field name)
    value set: SPACE, output table field name
    Only relevant for amount columns with associated unit.
    Name of the internal output table field containing the currency unit associated with the amount field FIELDCAT-FIELDNAME. The field in FIELDCAT-CFIELDNAME must have its own field catalog entry.
    • ctabname (internal currency unit field output table)
    value set: SPACE, output table field name
    only relevant for hierarchical-sequential lists
    Name of the internal output table containing the FIELDCAT-CFIELDNAME field.
    Link to measurement unit
    • qfieldname (measurement unit field name)
    value set: SPACE, output table field name
    only relevant for quantity columns with unit link.
    Name of the internal output table field containing the measurement unit associated with the quantity field FIELDCAT-FIELDNAME.
    The field in FIELDCAT-QFIELDNAME must have its own field catalog entry.
    • qtabname (internal measurement unit field output table)
    value set: SPACE, output table field name
    only relevant for hierarchical-sequential lists
    Name of the internal output table containing the FIELDCAT-QFIELDNAME field.
    Column output options
    • outputlen (column width)
    value set: 0 (initial), n
    For fields with a Data Dictionary link this parameter can be left initial.
    For fields without a Data Dictionary link (program field) the parameter must be given the value of the desired field list output length (column width).
    initial = column width is the output length of the referred Data Dictionary field (domain).
    n = column width is n characters
    • key (key column)
    value set: SPACE, 'X' 'X' = kex field (key field output in color)
    Key fields can not be interactively hidden. Parameter FIELDCAT-NO_OUT must be left initial.
    For exceptions see the documentation of the FIELDCAT-KEY_SEL parameter.
    • key_sel (hideable key column)
    value set: SPACE, 'X'
    only relevant when FIELDCAT-KEY = 'X'
    Key field which can be hidden interactively.
    The key column sequence cannot be changed interactively by the user.
    The output is controlled by the FIELDCAT-NO_OUT parameter analogously to non-key fields.
    • no_out (field in field list)
    value set: SPACE, 'X' 'X' = field is not displayed in the current list.
    The user can interactively choose the field for output from the field list.
    The user can display the contents of these fields at line level using the 'Detail' function.
    See also the 'Detail screen' documentation of the parameter IS_LAYOUT.
    • tech (technical field)
    value set: SPACE, 'X' 'X' = technical field
    Field cannot be output in the list and cannot be displayed interactively.
    Field can only be used in the field catalog (not in IT_SORT, ...).
    • emphasize (highlight columns in color)
    value set: SPACE, 'X' or 'Cxyz' (x:'1'-'9'; y,z: '0'=off '1'=on)
    'X' = column is colored with the default column highlight color.
    'Cxyz' = column is colored with a coded color:
    • C: Color (coding must begin with C)
    • x: color number
    • y: bold
    • z: inverse
    • hotspot (column as hotspot)
    value set: SPACE, 'X'
    'X' = column cells are output as hotspots
    • fix_column (fix column)
    value set: SPACE, 'X'
    Not relevant for block lists (output of several lists consecutively)
    'X' = column fixed (does not scroll horizontally)
    All columns to be fixed must have this flag, starting from the left. If a column without this flag is output, only the columns to the left of this column are fixed. The user can change the column fixing interactively. See also the documentation of the Layout parameter
    IS_LAYOUT-NO_KEYFIX of the IMPORTING paramter IS_LAYOUT.
    • do_sum (sum over column)
    value set: SPACE, 'X' 'X' = a sum is to be calculated over this internal output table field.
    This function can also be called by the user interactively.
    • no_sum (sums forbidden)
    value set: SPACE, 'X' 'X' = no sum can be calculated over this field, although the data type of the field would allow summing.
    • input (column ready for input)
    Function not available
    Format column contents
    • icon
    value set: SPACE, 'X' 'X' = column contents to be output as an icon.
    The caller must consider the printability of icons.
    • symbol
    value set: SPACE, 'X' 'X' = column contents are to be output as a symbol.
    The internal output table column must be a valid symbol character.
    The caller must consider the printability of symbols.
    Symbols can usually be printed, but may not always be output correctly, depending on the printer configuration.
    • just (justification)
    value set: SPACE, 'R', 'L', 'C'
    Only relevant for fields of data type CHAR or NUMC
    ' ' = default justification for this data type
    'R' = right-justified output
    'L' = left-justified output
    'C' = centered output
    The justification of the column header always follows the justification of the columns. Independent justification of the column neader is not possible.
    • lzero (leading zeros)
    value set: SPACE, 'X'
    Only relevant for fields of data type NUMC
    ALV outputs NUMC fields right-justified without leading zeros by default.
    'X' = output with leading zeros
    Note: If a NUMC field is output left-justified or centered by FIELDCAT-JUST, leading zeros are output. If the output of leading zeros is suppressed by a Data Dictionary reference ALPHA conversion exit, the output is always left-justified.
    • no_sign (no +/- sign) Only relevant for value fields
    value set: SPACE, 'X' 'X' = value output without +/ sign
    • no_zero (suppress zeros) Only relevant for value fields
    value set: SPACE, 'X' 'X' = suppress zeros
    • edit_mask (field formatting)
    value set: SPACE, template
    template = see documentation of WRITE formatting option USING EDIT MASK template
    The output conversion conv can be made by template = '== conv'.
    Texts
    The following text parameters should be specified for program fields without a Data Dictionary reference. The texts are taken from the Data Dictionary for fields with a Data Dictionary reference. If this is not desired, the text parameters can also be specified. The Data Dictionary texts are then ignored. If the user changes the column width interactively, the column header text with the appropriate length is always used. The interactive function 'Optimize column width' takes account of both the field contents and the column headers: if all field contents are shorter than the shortest column header, the column width depends on the column header.
    The 'long field label' is also used in display variant definition, sort, etc. popups.
    • seltext_l (long field label)
    • seltext_m (medium field label)
    • seltext_s (short field label)
    • reptext_ddic (header)
    analogous to the Data element maintenance 'Header'
    The specified text is not necessarily output in the list, an optimum among all texts is sought.
    • ddictxt (specify text)
    value set: SPACE, 'L', 'M', 'S'
    You can specify with values 'L', 'M', and 'S', the keyword that should always be used as column header. If the column width changes, no attempt is made in this case to find an appropriate header for the new output width.
    Parameters for program fields without Data Dictionary reference
    see also 'Text' parameters
    • datatype (data type)
    value set: SPACE, Data Dictionary data type (CHAR, NUMC,...)
    Only relevant for fields without Data Dictionary reference
    Program field data type
    • ddic_outputlen (external output length)
    value set: 0 (initial), n
    Only relevant for fields without Data Dictionary reference whose output is nevertheless to be modified by a conversion exit.
    Prerequisites:
    • FIELDCAT-EDIT_MASK = '==conv'
    see also the documentation of the parameter FIELDCAT-EDIT_MASK
    • FIELDCAT-INTLEN = n
    see also the documentation of the parameter FIELDCAT-INTLEN
    n = external format field output length
    The column width FIELDCAT-OUTPUTLEN need not be the same as the external format output length (FIELDCAT-DDIC_OUTPUTLEN).
    • intlen (internal output length)
    value set: 0 (initial), n
    Only relevant for fields without Data Dictionary reference whose output is nevertheless to be modified by a conversion exit.
    Prerequisites:
    • FIELDCAT-EDIT_MASK = '==conv'
    see also the documentation of the parameter FIELDCAT-EDIT_MASK
    • FIELDCAT-DDIC_OUTPUTLEN = n
    see also the documentation of the parameter FIELDCAT-DDIC_OUTPUTLEN
    n = internal format field output length
    • rollname (data element)
    value set: SPACE, Data Dictionary data element name
    F1 help can be provided for a program field without a Data Dictionary reference, or F1 help which differs from the Data Dictionary help can be provided for a field with a Data Dictionary reference, using this parameter.
    When F1 help is called for this field, the documentation of the specified data element is displayed.
    If the FIELDCAT-ROLLNAME is initial for fields with a Data Dictionary reference, the documentation of the data element of the referred Data Dictionary field is output.
    Others
    • sp_group (field group key)
    value set: SPACE, CHAR(1)
    Field group key.
    Keys are assigned to group names in the IT_SPECIAL_GROUPS parameter (see also the documentation of the parameter IT_SPECIAL_GROUPS).
    When such an assignment is made in the field catalog and in IT_SPECIAL_GROUPS, the fields are grouped correspondingly in the display variant popup.
    • reprep (Report/Report interface selection criterion)
    value set: SPACE, 'X'
    Prerequisites:
    • The system contains the Report/Report interface (function group RSTI, table TRSTI)
    • Parameter LAYOUT-REPREP = 'X'
    (see also the documentation of the parameter LAYOUT-REPREP of the IMPORTING parameter IS_LAYOUT )
    'X' = When the Report/Report interface is called, the value of this field is passed in the selected interface start record as a selection criterion.
    2.7.2. Default
    • The following entries are usually sufficient for internal table fields with a reference to a field defined in the Data Dictionary :
    • fieldname
    • ref_tabname
    Notes:
    ALV gets the remaining information from the Data Dictionary.
    If no relative column position (COL_POS) is specified, the fields are output in the list in the order in which they were added to the field catalog.
    REF_FIELDNAME need only be specifid when the name of the internal table field differs from the name of the referred Data Dictionary field.
    Information which is explicitly entered in the field catalog is not overwritten by information from the Data Dictionary.
    Priority rule:
    Entries in the field catalog have priority over differing entries in the Data Dictionary.
    • The following entries are usually sufficient for internal table fields without a reference to the Data Dictionary (program fields):
    • fieldname
    • outputlen
    • datatype
    • seltext_s
    • seltext_m
    • seltext_l
    Notes:
    F1 help can be provided for program fields by assigning a data element to the parameter ROLLNAME.
    If the parameters SELTEXT_S, SELTEXT_M, SELTEXT_L, and REPTEXT_DDIC contain appropriate field labels, the program field column headers are also adjusted appropriately when the column width changes.
    B. REUSE_ALV_FIELDCATALOG_MERGE : This function module is used to populate a fieldcatalog which is essential to display the data in ALV. If the output data is from a single dictionary table and all the columns are selected, then we need not exclusively create the field catalog. Its enough to mention the table name as a parameter(I_structure name) in the REUSE_ALV_LIST_DISPLAY. But in other cases we need to create it.
    The Important Parameters are :
    I. Export :
    i. I_program_name : report id
    ii. I_internal_tabname : the internal output table
    iii. I_inclname : include or the report name where all the dynamic forms are handled.
    II Changing
    ct_fieldcat : an internal table with the type SLIS_T_FIELDCAT_ALV which is
    declared in the type pool SLIS.
    Reward points if useful
    Regards
    Anji
    Vijayendra Rao  
    Posts: 1,699
    Questions: 28
    Registered: 9/14/04
    Forum points: 3,018 
      Re: ALV  
    Posted: May 14, 2007 8:29 PM    in response to: kotireddy       Reply 
    Hi,
    Field catalog defines the attributes and specifies the technical details of the columns displayed in an ALV output.
    You can check the following thread to see how to build a field catalog and how to work with ALV.
    Message was edited by:
            Karthikeyan Pandurangan

  • Non-English string access from excel sheet through JDBC

    My excel sheet data is
    Test ������������
    I am using JDBC connectivity for accessing the Excel sheet.
    Code looks like,
    List Output = new List();
    try
    Class.forName( "sun.jdbc.odbc.JdbcOdbcDriver" );
    c = DriverManager.getConnection( "jdbc:odbc:qa-list", "", "" );
    stmnt = c.createStatement();
    ResultSet rs = stmnt.executeQuery("select * from [Sheet1$];");
    ResultSetMetaData rsmd = rs.getMetaData();
    int numberOfColumns = rsmd.getColumnCount();
    for(int i=1; i <= numberOfColumns; i++){
    Output.add(rsmd.getColumnLabel(i));
    catch( Exception e )
    System.err.println( e );
    finally
    try
    stmnt.close();
    c.close();
    catch( Exception e )
    System.err.println( e );
    Now. I am showing those data into the table(JTable) Applet programming.
    For, English string it is showing properly but, for non-English string are showing �???????????????????�
    I would like to know what could be the reason.
    Addional info:
    ava version "1.6.0_01"
    Java(TM) SE Runtime Environment (build 1.6.0_01-b06)
    Java HotSpot(TM) Client VM (build 1.6.0_01-b06, mixed mode, sharing)
    If possible please send some reference code .

    I have one excel sheet which having differenct countries specific meaining of common words.
    I am using JDBC connectivity for accessing that Excel sheet.
    Code looks like,
    List Output = new List();
    try
    Class.forName( "sun.jdbc.odbc.JdbcOdbcDriver" );
    c = DriverManager.getConnection( "jdbc:odbc:qa-list", "", "" );
    stmnt = c.createStatement();
    ResultSet rs = stmnt.executeQuery("select * from [Sheet1$];");
    ResultSetMetaData rsmd = rs.getMetaData();
    int numberOfColumns = rsmd.getColumnCount();
    for(int i=1; i <= numberOfColumns; i++){
    Output.add(rsmd.getColumnLabel(i));
    catch( Exception e ){
    System.err.println( e );
    finally{
    try{
    stmnt.close();
    c.close();
    catch( Exception e ){
    System.err.println( e );
    Now. I am showing those output data into the table(JTable) in my Applet programming.
    For, English string it is showing properly but, for non-English strings are showing question marks like, �?????�
    I would like to know what could be the reason.
    Please help me, i am stuck in my project.

  • Report to Excel

    In the recent past, my team has received multiple requests to convert a standard report into excel for various valid business reasons. The standard SAP features mentioned below which lets you save the file does not fully meet the request:
    Option-1 (List->Export->Spreadsheet) - Even though this option letu2019s you save the report in excel format, it does not save any of the report totals.
    Option-2 (List->Local File-> Spreadsheet) u2013 This options lets you save the report including the totals in excel format. However, this option requires significant amount of time in reformatting the report
    I would like to know is there any alternative solutions including 3rd party solution which will require very minimal effort on the user side to convert the standard report into excel, preferably a WYSIWYG in excel relative to a standard SAP report?
    Please advice.

    Try in the below Example:
    *& DATA DECLARATION *
    TABLES: MARA, "GENERAL MASTER DATA
    MARC, "PLANT DATA FOR MATERIAL
    MARD, "STORAGE LOCATION DATA FOR MATERIAL
    MBEW, "MATERIAL VALUATION
    MVKE, "SALES DATA FOR MATERIAL
    MAKT, "MATERIAL DESCRIPTION
    EKKO, "PURCHASING DOCUMENT HEADER
    EKPO, "PURCHASING DOCUMENT ITEM
    VBAK, "SALES DOCUMENT HEADER DATA
    VBAP. "SALES DOCUMENT ITEM DATA
    TYPE-POOLS : SLIS.
    DATA: VT_FIELDCAT1 TYPE SLIS_T_FIELDCAT_ALV,
    V_FIELDCAT TYPE SLIS_FIELDCAT_ALV,
    V_LAYOUT TYPE SLIS_LAYOUT_ALV,
    BDCDATA LIKE BDCDATA OCCURS 0 WITH HEADER LINE,
    BEGIN OF I_MARA OCCURS 0,
    MATNR LIKE MARA-MATNR, "MATERIAL NUMBER
    MBRSH LIKE MARA-MBRSH, "INDUSTRY SECTOR
    MEINS LIKE MARA-MEINS, "BASE UNIT OF MEASURE
    MATKL LIKE MARA-MATKL, "MATERIAL GROUP
    END OF I_MARA,
    BEGIN OF I_MARC OCCURS 0,
    MATNR LIKE MARC-MATNR, "MATERIAL NUMBER
    WERKS LIKE MARC-WERKS, "PLANT
    LVORM LIKE MARC-LVORM, "FLAG MATERIAL FOR DELETION AT PLANT
    "LEVEL
    DISPO LIKE MARC-DISPO, "MRP CONTROLLER
    END OF I_MARC,
    BEGIN OF I_MAKT OCCURS 0,
    MATNR LIKE MAKT-MATNR, "MATERIAL NUMBER
    MAKTX LIKE MAKT-MAKTX, "MATERIAL DESCRIPTION
    SPRAS LIKE MAKT-SPRAS, "LANGUAGE KEY
    END OF I_MAKT,
    BEGIN OF I_MVKE OCCURS 0,
    MATNR LIKE MVKE-MATNR, "MATERIAL NUMBER
    VKORG LIKE MVKE-VKORG, "SALES ORGANIZATION
    VTWEG LIKE MVKE-VTWEG, "DISTRIBUTION CHANNEL
    END OF I_MVKE,
    BEGIN OF I_MARD OCCURS 0,
    MATNR LIKE MARD-MATNR, "MATERIAL NUMBER
    LGORT LIKE MARD-LGORT, "STORAGE LOCATION
    LABST LIKE MARD-LABST, "VALUATED STOCK WITH UNRESTRICTED USE
    END OF I_MARD,
    BEGIN OF I_EKPO OCCURS 0,
    EBELN LIKE EKPO-EBELN, "PURCHASING DOCUMENT NUMBER
    EBELP LIKE EKPO-EBELP, "ITEM NUMBER OF PURCHASING DOCUMENT
    MATNR LIKE EKPO-MATNR, "MATERIAL NUMBER
    END OF I_EKPO,
    BEGIN OF I_VBAP OCCURS 0,
    VBELN LIKE VBAP-VBELN, "SALES DOCUMENT
    POSNR LIKE VBAP-POSNR, "SALES DOCUMENT ITEM
    MATNR LIKE VBAP-MATNR, "MATERIAL NUMBER
    END OF I_VBAP,
    BEGIN OF I_OUT OCCURS 0,
    MATNR LIKE MARC-MATNR,
    WERKS LIKE MARC-WERKS,
    LVORM LIKE MARC-LVORM,
    DISPO LIKE MARC-DISPO,
    MBRSH LIKE MARA-MBRSH,
    MEINS LIKE MARA-MEINS,
    MATKL LIKE MARA-MATKL,
    VKORG LIKE MVKE-VKORG,
    VTWEG LIKE MVKE-VTWEG,
    SPRAS LIKE MAKT-SPRAS,
    MAKTX LIKE MAKT-MAKTX,
    LGORT LIKE MARD-LGORT,
    LABST LIKE MARD-LABST,
    EBELN LIKE EKPO-EBELN,
    EBELP LIKE EKPO-EBELP,
    VBELN LIKE VBAP-VBELN,
    POSNR LIKE VBAP-POSNR,
    END OF I_OUT,
    BEGIN OF I_HEADING OCCURS 0,
    TEXT1(20),
    TEXT2(20),
    TEXT3(20),
    TEXT4(20),
    TEXT5(20),
    TEXT6(20),
    TEXT7(20),
    TEXT8(20),
    TEXT9(20),
    TEXT10(20),
    TEXT11(40),
    TEXT12(20),
    TEXT13(20),
    TEXT14(20),
    TEXT15(20),
    TEXT16(20),
    TEXT17(20),
    END OF I_HEADING.
    *& S E L E C T I O N - S C R E E N *
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-100.
    SELECT-OPTIONS: S_MATNR FOR MARA-MATNR. "OBLIGATORY.
    PARAMETERS: P_WERKS LIKE MARC-WERKS. "OBLIGATORY.
    SELECT-OPTIONS: S_LGORT FOR MARD-LGORT,
    S_DISPO FOR MARC-DISPO,
    S_EBELN FOR EKPO-EBELN .
    SELECTION-SCREEN END OF BLOCK B1.
    SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-101.
    PARAMETERS : RB1 RADIOBUTTON GROUP G1,
    RB2 RADIOBUTTON GROUP G1,
    RB3 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN END OF BLOCK B2.
    *& S T A R T - O F - S E L E C T I O N *
    START-OF-SELECTION.
    SELECT MATNR WERKS LVORM DISPO FROM MARC
    INTO CORRESPONDING FIELDS OF TABLE I_MARC
    WHERE MATNR IN S_MATNR
    AND DISPO IN S_DISPO
    AND WERKS = P_WERKS.
    IF I_MARC[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA AVAILABLE FROM MARC'.
    EXIT.
    ENDIF.
    PERFORM PURCHASEDATA_VALIDATION.
    PERFORM SALESDATA_VALIDATION.
    SELECT MATNR LGORT LABST FROM MARD INTO TABLE I_MARD
    FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR
    AND WERKS EQ P_WERKS
    AND LGORT IN S_LGORT.
    IF I_MARD[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA AVAILABLE FROM MARD'.
    EXIT.
    ENDIF.
    SELECT MATNR VKORG VTWEG FROM MVKE INTO TABLE I_MVKE
    FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR.
    IF I_MVKE[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA AVAILABLE FROM MVKE'.
    EXIT.
    ENDIF.
    LOOP AT I_MARC.
    MOVE-CORRESPONDING I_MARC TO I_OUT.
    CLEAR MARC.
    SELECT SINGLE MATNR MBRSH MEINS MATKL FROM MARA
    INTO CORRESPONDING FIELDS OF MARA
    WHERE MATNR = I_OUT-MATNR.
    IF SY-SUBRC = 0.
    MOVE: MARA-MBRSH TO I_OUT-MBRSH,
    MARA-MEINS TO I_OUT-MEINS,
    MARA-MATKL TO I_OUT-MATKL.
    ELSE.
    CONTINUE.
    ENDIF.
    SELECT SINGLE MATNR MAKTX SPRAS FROM MAKT
    INTO CORRESPONDING FIELDS OF MAKT
    WHERE MATNR = I_OUT-MATNR.
    IF SY-SUBRC = 0.
    MOVE: MAKT-MAKTX TO I_OUT-MAKTX,
    MAKT-SPRAS TO I_OUT-SPRAS.
    ELSE.
    CONTINUE.
    ENDIF.
    LOOP AT I_EKPO WHERE MATNR = I_MARC-MATNR.
    MOVE: I_EKPO-EBELN TO I_OUT-EBELN,
    I_EKPO-EBELP TO I_OUT-EBELP.
    ENDLOOP.
    LOOP AT I_VBAP WHERE MATNR = I_MARC-MATNR.
    MOVE: I_VBAP-VBELN TO I_OUT-VBELN,
    I_VBAP-POSNR TO I_OUT-POSNR.
    ENDLOOP.
    LOOP AT I_MARD WHERE MATNR = I_MARC-MATNR.
    MOVE: I_MARD-LABST TO I_OUT-LABST,
    I_MARD-LGORT TO I_OUT-LGORT.
    ENDLOOP.
    LOOP AT I_MVKE WHERE MATNR = I_MARC-MATNR.
    MOVE: I_MVKE-VKORG TO I_OUT-VKORG,
    I_MVKE-VTWEG TO I_OUT-VTWEG.
    APPEND I_OUT.
    ENDLOOP.
    CLEAR I_OUT.
    ENDLOOP.
    PERFORM OPTIONS.
    FORM OPTIONS *
    FORM OPTIONS.
    IF RB2 = 'X'.
    PERFORM FIELDCAT.
    PERFORM OUTPUT.
    ELSE.
    IF RB1 = 'X'.
    PERFORM HEADINGS.
    PERFORM DLOAD.
    ELSE.
    IF RB3 = 'X'.
    PERFORM HEADINGS.
    PERFORM DLOAD.
    PERFORM FIELDCAT.
    PERFORM OUTPUT.
    ENDIF.
    ENDIF.
    ENDIF.
    ENDFORM. "OPTIONS
    FORM HEADINGS *
    FORM HEADINGS.
    I_HEADING-TEXT1 = 'MATNR'.
    I_HEADING-TEXT2 = 'WERKS'.
    I_HEADING-TEXT3 = 'LVORM'.
    I_HEADING-TEXT4 = 'DISPO'.
    I_HEADING-TEXT5 = 'MBRSH'.
    I_HEADING-TEXT6 = 'MEINS'.
    I_HEADING-TEXT7 = 'MATKL'.
    I_HEADING-TEXT8 = 'VKORG'.
    I_HEADING-TEXT9 = 'VTWEG'.
    I_HEADING-TEXT10 = 'SPRAS'.
    I_HEADING-TEXT11 = 'MAKTX'.
    I_HEADING-TEXT12 = 'LGORT'.
    I_HEADING-TEXT13 = 'LABST'.
    I_HEADING-TEXT14 = 'EBELN'.
    I_HEADING-TEXT15 = 'EBELP'.
    I_HEADING-TEXT16 = 'VBELN'.
    I_HEADING-TEXT17 = 'POSNR'.
    APPEND I_HEADING.
    ENDFORM. "HEADINGS
    FORM DLOAD *
    FORM DLOAD.
    CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
    FILENAME = 'C:\MATSTK.XLS'
    FILETYPE = 'DAT'
    WRITE_FIELD_SEPARATOR = 'X'
    TABLES
    DATA_TAB = I_HEADING
    EXCEPTIONS
    FILE_WRITE_ERROR = 1.
    CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
    FILENAME = 'C:\MATSTK.XLS'
    FILETYPE = 'DAT'
    APPEND = 'X'
    WRITE_FIELD_SEPARATOR = 'X'
    TABLES
    DATA_TAB = I_OUT.
    ENDFORM. "DLOAD
    FORM FIELDCAT *
    FORM FIELDCAT.
    V_FIELDCAT-COL_POS = '1'.
    V_FIELDCAT-FIELDNAME = 'MATNR'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-HOTSPOT = 'X'.
    V_FIELDCAT-REF_FIELDNAME = 'MATNR'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '2'.
    V_FIELDCAT-FIELDNAME = 'WERKS'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'WERKS'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '3'.
    V_FIELDCAT-FIELDNAME = 'LVORM'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'LVORM'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '4'.
    V_FIELDCAT-FIELDNAME = 'DISPO'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'DISPO'.
    V_FIELDCAT-REF_TABNAME = 'MARC'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '5'.
    V_FIELDCAT-FIELDNAME = 'MBRSH'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MBRSH'.
    V_FIELDCAT-REF_TABNAME = 'MARA'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '6'.
    V_FIELDCAT-FIELDNAME = 'MEINS'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MEINS'.
    V_FIELDCAT-REF_TABNAME = 'MARA'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '7'.
    V_FIELDCAT-FIELDNAME = 'MATKL'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MATKL'.
    V_FIELDCAT-REF_TABNAME = 'MARA'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '8'.
    V_FIELDCAT-FIELDNAME = 'VKORG'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'VKORG'.
    V_FIELDCAT-REF_TABNAME = 'MVKE'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '9'.
    V_FIELDCAT-FIELDNAME = 'VTWEG'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'VTWEG'.
    V_FIELDCAT-REF_TABNAME = 'MVKE'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '10'.
    V_FIELDCAT-FIELDNAME = 'SPRAS'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'SPRAS'.
    V_FIELDCAT-REF_TABNAME = 'MAKT'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '11'.
    V_FIELDCAT-FIELDNAME = 'MAKTX'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'MAKTX'.
    V_FIELDCAT-REF_TABNAME = 'MAKT'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '12'.
    V_FIELDCAT-FIELDNAME = 'LGORT'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'LGORT'.
    V_FIELDCAT-REF_TABNAME = 'MARD'.
    V_FIELDCAT-SELTEXT_L = 'STRG LOCT'.
    V_FIELDCAT-OUTPUTLEN = 10.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '13'.
    V_FIELDCAT-FIELDNAME = 'LABST'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-SELTEXT_M = 'STOCK'.
    V_FIELDCAT-OUTPUTLEN = 15.
    V_FIELDCAT-REF_FIELDNAME = 'LABST'.
    V_FIELDCAT-REF_TABNAME = 'MARD'.
    V_FIELDCAT-DO_SUM = 'X'.
    V_LAYOUT-TOTALS_TEXT = 'TOTAL STOCK:'.
    V_FIELDCAT-HOTSPOT = 'X'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '14'.
    V_FIELDCAT-FIELDNAME = 'EBELN'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-HOTSPOT = 'X'.
    V_FIELDCAT-REF_FIELDNAME = 'EBELN'.
    V_FIELDCAT-REF_TABNAME = 'EKPO'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '15'.
    V_FIELDCAT-FIELDNAME = 'EBELP'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'EBELP'.
    V_FIELDCAT-REF_TABNAME = 'EKPO'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '16'.
    V_FIELDCAT-FIELDNAME = 'VBELN'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-HOTSPOT = 'X'.
    V_FIELDCAT-REF_FIELDNAME = 'VBELN'.
    V_FIELDCAT-REF_TABNAME = 'VBAP'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    V_FIELDCAT-COL_POS = '17'.
    V_FIELDCAT-FIELDNAME = 'POSNR'.
    V_FIELDCAT-TABNAME = 'I_OUT'.
    V_FIELDCAT-REF_FIELDNAME = 'POSNR'.
    V_FIELDCAT-REF_TABNAME = 'VBAP'.
    APPEND V_FIELDCAT TO VT_FIELDCAT1.
    CLEAR V_FIELDCAT.
    ENDFORM. "FIELDCAT
    FORM OUTPUT *
    FORM OUTPUT.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
    I_CALLBACK_PROGRAM = SY-REPID
    I_CALLBACK_TOP_OF_PAGE = 'TOP-OF-PAGE'
    I_GRID_TITLE = 'CLICK ON MATERIAL/PURDOC/SALESDOC FOR DETAILS'
    I_CALLBACK_USER_COMMAND = 'DISPLAYDETAILS'
    IS_LAYOUT = V_LAYOUT
    IT_FIELDCAT = VT_FIELDCAT1
    TABLES
    T_OUTTAB = I_OUT.
    IF SY-SUBRC 0.
    ENDIF.
    ENDFORM. "OUTPUT
    FORM TOP-OF-PAGE *
    FORM TOP-OF-PAGE.
    DATA: T_HEADER TYPE SLIS_T_LISTHEADER,
    WA_HEADER TYPE SLIS_LISTHEADER.
    WA_HEADER-TYP = 'H'.
    WA_HEADER-INFO = 'REPORT FOR : '.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    WA_HEADER-TYP = 'S'.
    WA_HEADER-INFO = 'MATERIAL DETAILS'.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    WA_HEADER-TYP = 'S'.
    WA_HEADER-INFO = 'PURCHASE ORDER DETAILS'.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    WA_HEADER-TYP = 'S'.
    WA_HEADER-INFO = 'SALES ORDER DETAILS'.
    APPEND WA_HEADER TO T_HEADER.
    CLEAR WA_HEADER.
    CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
    EXPORTING
    I_LOGO = 'GEAR'
    IT_LIST_COMMENTARY = T_HEADER.
    ENDFORM. "TOP-OF-PAGE
    *& FORM PURCHASEDATA_VALIDATION *
    FORM PURCHASEDATA_VALIDATION.
    SELECT EBELN EBELP MATNR
    FROM EKPO
    INTO TABLE I_EKPO
    FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR
    AND EBELN IN S_EBELN
    AND WERKS EQ P_WERKS.
    IF I_EKPO[] IS INITIAL.
    WRITE:/ 'NO MATCHING DATA IS SELECTED FROM TABLE EKPO'.
    EXIT.
    ENDIF.
    DATA: T_EKPO LIKE I_EKPO OCCURS 0 WITH HEADER LINE.
    T_EKPO] = I_EKPO[.
    REFRESH I_EKPO.
    FREE I_EKPO.
    LOOP AT T_EKPO.
    SELECT SINGLE EBELN FROM EKKO INTO EKPO-EBELN
    WHERE EBELN = T_EKPO-EBELN.
    IF SY-SUBRC = 0.
    MOVE-CORRESPONDING T_EKPO TO I_EKPO.
    APPEND I_EKPO.
    CLEAR I_EKPO.
    ELSE.
    CONTINUE.
    ENDIF.
    ENDLOOP.
    SORT I_EKPO.
    ENDFORM. "PURCHASEDATA_VALIDATION
    *& FORM SALESDATA_VALIDATION *
    FORM SALESDATA_VALIDATION.
    SELECT VBELN POSNR MATNR
    FROM VBAP
    INTO CORRESPONDING FIELDS OF TABLE
    I_VBAP FOR ALL ENTRIES IN I_MARC
    WHERE MATNR = I_MARC-MATNR.
    DATA: T_VBAP LIKE I_VBAP OCCURS 0 WITH HEADER LINE.
    T_VBAP] = I_VBAP[.
    REFRESH I_VBAP.
    FREE I_VBAP.
    LOOP AT T_VBAP.
    SELECT SINGLE VBELN FROM VBAK INTO VBAK-VBELN
    WHERE VBELN = T_VBAP-VBELN.
    IF SY-SUBRC = 0.
    MOVE-CORRESPONDING T_VBAP TO I_VBAP.
    APPEND I_VBAP.
    CLEAR I_VBAP.
    ELSE.
    CONTINUE.
    ENDIF.
    ENDLOOP.
    SORT I_VBAP.
    ENDFORM. "SALESDATA_VALIDATION
    Rohan Malik  
    Posts: 165
    Registered: 9/21/07
    Forum Points: 90 
       Re: Regarding ALV report to output in excel  
    Posted: Feb 21, 2008 6:50 AM    in response to: naveenkumar bai...       E-mail this message      Reply 
    hi naveen kumar,
    You can use the FM - ALV_XXL_CALL.
    It is the same function module invoked when you click on the export to excel button of the ALV.
    You can pass teh field catalog of the ALV here along with the name of ur internal table and the internal table itself. It will download everything to Excel alongwith the Column headers ( depending on ur field catalog definition). Just make sure ur field catalog has the COL_Heading correctly populated.
    Sample Code - CALL FUNCTION 'ALV_XXL_CALL'
    EXPORTING
    i_tabname = 'T_GRID' " Name of the Internal table
    it_fieldcat = t_fcatk[] " Field catalog
    TABLES
    it_outtab = t_grid " Interbnal table with data
    EXCEPTIONS
    fatal_error = 1
    no_display_possible = 2
    OTHERS = 3.
    IF sy-subrc 0.
    MESSAGE e806(bk).
    ENDIF.
    Regarding ALV report to output in excel
    reward if helpful

Maybe you are looking for