Problem with HP Envy 15-j009 WM

I have a problem with my laptop HP Envy 15-j009wm buy it a few days ago and randomly conjelada stays. When conjela I have to turn it off forcefully. Realize you already extensive test and passes all but the problems persist.

Hello @BlackXtreme,
Welcome to the HP Forums, I hope you enjoy your experience! To help you get the most out of the HP Forums I would like to direct your attention to the HP Forums Guide First Time Here? Learn How to Post and More.
I understand that your notebook is not able to power off without forcefully turning it off. When you mentioned "conjelada", is this a program that is frozen on your computer screen? Which tests have you performed when diagnosing this issue? I would be happy to help you, but first I would encourage you to post your product number for your computer. Below is a is an HP Support document that will demonstrate how to find your computer's product number. In addition, it will also help if you indicate which operating system you are using; and whether your operating system is 32 or 64 bit. The more information you can provide, the better!
How Do I Find My Model Number or Product Number?
Which Windows operating system am I running?
Is the Windows Version on My Computer 32-bit or 64-bit?
Please re-post with the necessary information, this way I will be able to research this further for you. I look forward to your reply!
Cheers!
MechPilot
I work on behalf of HP
Please click “Accept as Solution ” if you feel my post solved your issue, it will help others find the solution.
Click the “Kudos, Thumbs Up" on the right to say “Thanks” for helping!

Similar Messages

  • Problem with Hp Envy 17 1190en overheatin​g, 10 months old and 3 times in warranty repair!

    Same problem with hp envy laptop and no success with repaird laptop, all the time same problem motherboard melt up. I use all the time notebook cooler and laptop breaths more than it needs but it doest work normaly. Temps are wiht cooler bad normally in internet 76 and plaing games are temps over 100.
    Is it possible hp give me new series envy or they repair it hundred times?
    Thank you, sorry about my english .

    Hi,
    Please provide us the complete model of your system along with the operating system, so that we can better assist you.
    How to locate model number for your notebook:
    http://h10025.www1.hp.com/ewfrf/wc/document?cc=us&​​lc=en&docname=c00033108
    It would also be good to know where you are located.
    R
    Although I am an HP Employee, I am speaking for myself and not for HP.

  • Wireless printing problem with HP Envy all-in-one 110 when running Mac OS 10.7

    I just bought the HP Envy all-in-one 110. I have a Macbook Air running IS 10.7. I managed to install the software correctly and the wirless network light is showing on the printer. I ran a test page from the printer and all the settings say they are "enabled." But I still can't get the printer to print over the wireless network. When I plugged in a USB cable, I managed to get it to print. I have a wireless router running over the Sonic.net DSL network. Network strength is good. I've switched off and restarted all equipment several times but still no results. Help!

    Hi,
    I believe the router may not support Multicasting, a network protocol used for Apple's Bonjour service to operate as it should.
    Will be helpful to know the exact router brand and model.
    As a workaroung, you may try setting the printer by using standard IP, it should allow you to print, however the router issue (more likely) have to be handled first to allow the full software functionality including scanning.
    Follow the steps below to set an IP print queue, it will also help to better understand the cause for the problem:
    Enter System Preferences > Print & Scan.
    Click the plus sign.
    Click the IP icon.
    Select the HP Jetdirect Socket protocol.
    Enter the printer IP address into the Address field
    Now try printing using the newly created print queue, listed as the printer IP address.
    Say thanks by clicking the Kudos thumb up in the post.
    If my post resolve your problem please mark it as an Accepted Solution

  • Printing problems with HP ENVY 4502

    I've been having trouble with printing ever since my laptop updated to 8.1. System resets do not solve the problem. 
    The problem is that my printer is online, but my computer will not acknowledge it at all. I have to turn the wireless on and off constantly for my laptop to pick it up for just a couple minutes. When it does somehow pick up, I cannot print anything. I have downloaded the HP Driver software help and it has not solved my problem.  I also have the HP aio remote and when it says my printer is online (which it should always say but it does not) and i search for documents, none of my documents show up except for one .PDF file. I'm a college student in need of printing and need help dearly.

    I should also mention that I have been able to scan items recently. When i go to print it says "no printer installed" when i've gone through the process to install it a number of times as HP Support instructed.

  • Printing problem with HP Envy 5530

    I'm using the Instant Ink service but intermittently I am unable to print. The printer simply displays a message "Printing" but nothing happens. Any ideas? 

    Hi ,
    Welcome to the HP Forums, and thanks for posting! I'd like to help you with the hang-ups you are experiencing when printing to your HP ENVY 5530 e-All-in-One printer. Firstly, do you have the printer plugged directly into a wall outlet? The printer has a power moderator built in, so if it is plugged into a power surge or battery backup, it can cause serious power fluctuations. The most common cause of the hang-ups that you are experiencing, would be if the printer is unable to pull power fast enough to complete the action. If that doesn't immediately resolve the issue, can you try to make a copy on the printer for me, and let me know if it completes? If the copy works fine, the issue may have something to do with your wireless connection or the software installed on your computer. Please answer the following questions so that I'm better able to assist: What operating system, and version do you have? Mac or Windows ?What program are you printing from?Have you tried printing from multiple programs or multiple file types?I look forward to hearing back and working towards a resolution for this issue.

  • Problem with Audio on HP Envy 6-1130sw (C6F62EA)

    Hello everyone.
    I have a problem with audio on my ultrabook HP Envy 6. Sometimes when I try to play music there are no low tones and music plays really silent... And then when I restart PC problem dissapears and music plays fine... I thought there is a problem with speakers, but when I connected 5.1 speakers there were also only high tones. Same thing happens on headphones. Is it a hardware problem or maybe software? Actually I use Windows 8.1 and drivers are up to date. If any one of you had same problem please post.
    Thanks. 

    Hi piotrek1130sw,
    From what you have described, I think the best approach would be to restore the original IDT driver, restart the computer, test that driver, then install the driver update, and test the outcome of installing the newest driver.
    Use the following link for instructions to recovery the ITD driver using Recovery Manager. Restoring applications and drivers.
    Once the driver is restored, restart the computer and test the audio. If the audio is good you can continue to use this driver, or you can reinstall the update and see what happens. IDT High-Definition (HD) Audio Driver.
    If installing the newest driver causes the issue to occur but the recovered driver worked, I suggest recovering again.
    If neither driver works I will gladly follow up and provide any assistance I can.
    Please let me know the outcome.
    Please click the Thumbs up icon below to thank me for responding.
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Please click “Accept as Solution” if you feel my post solved your issue, it will help others find the solution.
    Sunshyn2005 - I work on behalf of HP

  • HP Envy 15 Graphics Problem with Windows 8.1 (Intel and NVidia Graphics). Help!

    I bought an HP ENVY TouchSmart 15-j013ea about 6 months ago and I have had a major problem with the graphics that I cannot seem to solve. I think it started when I updated to Windows 8.1, even though I am not 100% certain.
    I have noticed the following three problems, and I think they are related:
    Some windows (such as Chrome, Skype, or even Device Manager or other windows) are very blurry compared to others.
    The firefox menu window has some deformed black arrows instead of the normal ones.
    When playing a game (specifically, Star Wars the Force Unleashed 2), after a while I get an error that the computer has ran out of memory. However, according to task manager, only about 50% is in use, not to mention that I have 8 GB of RAM + 2 GB graphics memory. At the same time, the computer gets rather loud (like a fan working overtime) and hot.
    The laptop has both Intel and NVidia graphics, and both are enabled in Device Manager. To be honest, I have no idea which is used when, or how to check that (let me know if there is a way)
    I have tried the following without success:
    Uninstalling the Intel graphics driver from device manager and installing a version I downloaded from the HP website for my laptop and OS. After that, Windows would NOT BOOT, and I had to do a system restore.
    Uninstalling the Intel graphics from Programs and Features, and installing 2 different versions from the Intel website. Nothing changed.
    Updating Nvidia driver through GeForce Experience. Nothing changed.
    Updating Intel drivers from Windows Update. Nothing changed.
    Quite frankly I am not sure what the problem could be, since the graphics versions are supposed to be compatible with WIndows 8.1. I also don't get why some windows are blurry and others are not. I am thinking the computer uses only the Intel graphics and not the Nvidia (at least in the blurry windows), but even if that was the case (and it shouldn't be), I don't think I should be having this problem.
    At this point, I really need help. My graphics details are:
    Intel HD Graphics 4600: Driver version: 10.18.10.3412
    NVidia GeForce GT 740M: Driver version: 335.23
    NVidia GeForce Experience version: 1.8.2
    I am attaching screenshots that show driver details and the problems.
    Thank you.
    Blurry Chrome:
    Firefox menu problem:
    Device Manager and driver windows are also blurry, both graphics are shown

    I had a similar problem with a Dell laptop.  I found the problem was the laptop wanted to switch between the Intel and NYIDIA video cards.  It would switch to the Intel when high graphics was not required then to the NIVIDIA when high graphics was required.  The laptop does this to save power when high graphics is not required but it caused problems with some applications, specifically high graphics games.
    For me the solution was to disable the Intel graphics processor.  You can do this by right clicking on your Wallpaper, select the NIVIDIA Control Panel, then select Set Physx Configuration.  You will see a dropdown box labeled Select Physx Processor.  It is set to Auto by default.  This allows the switching I described. Select this dropdown box and select your NIVIDIA processor.  This will prevent the laptop from switching and force it to use your NVIDIA processor exclusively.
    Hope this helps.
    Sacto Fred
    Owner and CEO
    H&O PC Soultions

  • Hp Envy m6-1105dx. Problems with my charger.

    Product Name: Hp Envy m6-1105dx
    Operating System installed: Windows 8
    I'm going to keep this simple.
    I bought this computer on February 20th, 2013, so up to this date It's been over a month. I've never bought a laptop before, and in just a little over a month...started to have these kind of complications.
    Since this is the hardware section, lets start with that.
    I plug in my charger, it does not work. I try a second time, and we have the same result. I have to continuously plug the charger in, and out in order to receive a charge.. I call this the "Hopefully it works” method. Problem number two, is that everytime my computer goes to sleep, the charger shows that it doesn’t register anymore....and this sets us back to problem one.
    This is a new laptop, so I believe problems with the battery really shouldn't be showing me these kinds of complications. I’m very frustrated at the fact that my laptop’s battery or charger will not work.
    For any other information that might help....
    Yes the battery is in, Yes my charger is plugged into the wall, and yes I've reset my computer to check if this problem would still Reoccur. The only thing I didn’t do is replace my battery, or charging cable. The reason being is that i just bought this computer.
    Thank you very much for reading this topic, sorry for the “Ranting” kind of approach, but I hope you can see my frustration.
    Any advice, or basically a solution to my problem will be very much so appreciated.

    Unfortunately it appears you got a lemon. It happens. If you have a return right at the point of sale, exercise it. Otherwise call HP and work your way through the phone tree to see about returning it.  The only other possibilty is that a BIOS update was just released on 3-15
    http://h10025.www1.hp.com/ewfrf/wc/softwareDownloa​dIndex?softwareitem=ob-116472-1&cc=us&dlc=&lc=en&o​...
    Of course you are going to have to catch it when it is working and the BIOS update entails a bit of risk if the computer crashes during the update. I would call Customer Service and ask them if they want you to try the BIOS update. Before they authorize a return they are going to make you go in and reset the BIOS to defaults and muck around in there a bit anyway.

  • Monitor problem with envy dv6-7214nr

    I have a problem with my monitor.  At the very top there is a single line that keeps flashing.  What could the problem be?  A bad monitor?  Or something else?

    Hi Antlan,
    Thank you for visiting the HP Support Forums and Welcome. I have read your thread on your HP ENVY dv6-7214nr Notebook and getting a flashing line on the screen. Try performing a hard reset. When performing a hard reset please note remove any and all USB devices, and remove memory cards from the card reader slot. Disconnect all non-essential devices. If that does not help try to turn on the computer you start to press F11 repeatedly till the menu opens. You can do a system restore. You could check for a BIOS update.
    Hope this is helpful.
    Thanks.
    Please click “Accept as Solution ” if you feel my post solved your issue, it will help others find the solution.
    Click the “Kudos, Thumbs Up" on the bottom to say “Thanks” for helping!

  • Windows 8/8.1 Partial Print Problems with Networked Inkjet Printers (Envy, Officejet and Deskjet)

    There are a lot of threads being posted about this problems with printing on the following these devices when they are connected in a Network Environment (Wireless or Wired)
    HP Officejet Pro 6830
    HP Officejet 6800
    HP Officejet Pro 6230
    HP Officejet 6220
    HP Officejet Pro 8610 e-All-in-One Printer series
    HP Officejet Pro 8620 e-All-in-One Printer series
    HP Officejet Pro 8630 e-All-in-One Printer series
    HP Officejet Pro 8640 e-All-in-One
    HP Officejet Pro 8650 e-All-in-One
    HP Officejet Pro 8660 e-All-in-One
    HP Officejet 7610 Wide Format ePrinter
    HP Officejet Pro 3610 Black and White e-All-in-One
    HP Officejet Pro 3620 Black and White e-All-in-One
    HP Officejet Pro 251dw Printer series
    HP Officejet Pro 276dw MFP series
    HP Officejet 7110 Wide format ePrinter
    HP Officejet Pro 501dw Printer
    HP Officejet Pro 401dw Printer
    HP Officejet Pro X451dw Printer
    HP Officejet Pro X576dw MFP
    HP Officejet Pro X476dn MFP
    HP Officejet Pro 451dn/551dn MFP
    HP Officejet Pro 451dw/551dw MFP
    HP Officejet 4630 e-All-in-One
    HP Deskjet Ink Advantage 4640 e-All-in-One Printer series
    HP Deskjet 2540 All-in-One Printer
    HP Deskjet Ink Advantage 2540 All-in-One Printer
    HP ENVY 5530 e-All-in-One Printer
    HP Deskjet Ink Advantage 4510 e-All-in-One Printer
    HP ENVY 4500 e-All-in-One Printer
    HP Deskjet Ink Advantage 3540 e-All-in-One Printer
    HP posted a workaround for this problem while they were working with Microsoft to get the root cause of the problem, many customers commented that the workaround helped them out and they were able to print. This workaround was not easy to use as the customer needed to add another printer manually and changed drivers.
    We can now announce that the problem has been fixed, the problem involved a Microsoft Network component that HP was using to talk to and track the printers on the network. This fix is being rolled out by Microsoft via Windows Update and anyone who has Windows Update enabled and set to automatically install updates should have already received this update. For those that do not have Windows Update setup to automatically install fixes the fix is available now and should be installed.
    The details of this fix and a manual method of installing it can be found here.
    http://support.microsoft.com/kb/3000461
    This fix is only designed for users that are using there printer on a Network (Wireless or Wired) and will not fix partial printing problems encountered with USB connections.
    There are many threads in HPs forums about this issue (below are links to a few of them)
    http://h30434.www3.hp.com/t5/Printing-Issues-Troubleshooting/Missing-partial-prints-amp-Printer-Offl...
    http://h30434.www3.hp.com/t5/Printing-Issues-Troubleshooting/HP-Envy-4500-cancels-job-in-the-middle-...
    http://h30434.www3.hp.com/t5/Other-Printing-Questions/Only-prints-half-a-page/m-p/4054888
    JonW
    I work for HP

    @tenkeypro 
    First, I would suggest you uninstall the exsisting driver and reinstall following one of these documents to see if it will clear this error message:
    Install HP print and scan software on a Windows 8 computer (32-bit and 64-bit)
    Universal Print Driver (no scan)
    Driver support included in Windows 8 / Windows 8.1 or in Windows Update
    I am an HP employee.
    Say Thanks by clicking the Kudos Star in the post that helped you.
    Please mark the post that solves your problem as Accepted Solution

  • I have a new IPhone5c and do not receive texts or calls from my daughter's phone. We did not have this problem with my old Envy Touch. Verizon is our provider. Can you troubleshoot?

    I have a new IPhone5c and do not receive texts or calls sent from my daughter's phone; I'll call this phone 2. We did not have this problem with my old Envy Touch. Verizon is our provider. Can you troubleshoot? My other daughter has a new IPhone5c too. She receives calls and texts from sent from phone 2. Any tips for remedying this problem?
    Thank you.

    Turn off iMessage in your phones settings.   Apple devices can only use iMessage to other Apple devices.
    Turning off iMessage will allow the messages to go as regular text messages.

  • ENVY 7640 error "There is a problem with this printer"

    Hi guys. I got this printer 4 months ago and it has been working marvelous. But this weekend when I turned it on the error "There is a problem with this printer" appeared, just after it connected to my wifi network.I made several tests and the error comes only if the network is connected to the internet.When it is not connected to the internet the printer works fine (prints, scans, all via wifi).I have a MAC and an AirPort Time Capsule.Is there any set up that solves the problem?

    Hi , Welcome to the HP Forums! I see that you are getting the error message, "There is a problem with this printer," with your HP Envy 7640 on Mac OS X 10.10. I am happy to help!  Is this error message showing on the printer's display screen, or on the computer screen? If the error is on the computer screen, try resetting the print system. If the error is on the printer's display screen, please try a hard reset, by going to this post, How to perform a Hard Reset, by . It is important that the printer's power cable is plugged directly into the wall outlet, and not a surge protector. Issues when Connected to an Uninterruptible Power Supply/Power Strip/Surge Protector. This applies to Inkjet printers as well. I would also double-check that your printer's firmware is up-to-date. Getting the Latest Firmware and Product Updates. Hope this helps!  “Please click the Thumbs up icon below to thank me for responding.”

  • Problem with scanning document to searchable pdf in HP Envy 4500

    I just bought HP Envy 4500 , overall good printer, but I can't find option for scanning to searchable pdf. I already updated my desktop software and printer's firmware, but still there is no option "scan to searchable pdf". Do i have to download some other software from HP? 

    Hello katiemac,
    Welcome to the HP Support Forums!
    When you are scanning with the ENVY 4500, how are you doing performing the scan? For example, if you are not using the HP software or scanning from the front panel of the printer you may not be getting all the features.
    What is the Operating System installed on the computer, Windows or Mac?
    JERENDS
    I work on behalf of HP
    Please click “Accept as Solution” if you feel my post solved your issue, it will help others find the solution.
    Click the “Kudos Thumbs Up" to the left of the reply button to say “Thanks” for helping!

  • Problem with performance in a code.

    Hi People! I have problems with the performance of this program. The tables that I use have much data and the program take two hours to finish.
    Please, some one tell me how can I make a better performance.
    Thanks!
    This is the program:
    TABLES:
            faglflext,         "Saldos mensuales por cta. 
                                contable y prf center.
            zavg_bal_table,
            skat.              "Chart of accounts
    ********************INTERNAL TABLE DEFINITION***************************
    DATA: BEGIN OF t_itab1 OCCURS 0.
    DATA: rbukrs      TYPE faglflext-rbukrs. "Company Code
    DATA: racct       TYPE faglflext-racct. "Account ID
    DATA: prctr       TYPE faglflext-prctr. "Profit Center
    DATA: kslvt       TYPE faglflext-kslvt. "Total of the period in group currency
    DATA: ksl01       TYPE faglflext-ksl01. "Total of the period in group currency
    DATA: ksl02       TYPE faglflext-ksl02. "Total of the period in group currency
    DATA: ksl03       TYPE faglflext-ksl03. "Total of the period in group currency
    DATA: ksl04       TYPE faglflext-ksl04. "Total of the period in group currency
    DATA: ksl05       TYPE faglflext-ksl05. "Total of the period in group currency
    DATA: ksl06       TYPE faglflext-ksl06. "Total of the period in group currency
    DATA: ksl07       TYPE faglflext-ksl07. "Total of the period in group currency
    DATA: ksl08       TYPE faglflext-ksl08. "Total of the period in group currency
    DATA: ksl09       TYPE faglflext-ksl09. "Total of the period in group currency
    DATA: ksl10       TYPE faglflext-ksl10. "Total of the period in group currency
    DATA: ksl11       TYPE faglflext-ksl11. "Total of the period in group currency
    DATA: ksl12       TYPE faglflext-ksl12. "Total of the period in group currency
    DATA: ksl13       TYPE faglflext-ksl13. "Total of the period in group currency
    DATA: ksl14       TYPE faglflext-ksl14. "Total of the period in group currency
    DATA: ksl15       TYPE faglflext-ksl15. "Total of the period in group currency
    DATA: ksl16       TYPE faglflext-ksl16. "Total of the period in group currency
    DATA: rldnr       TYPE faglflext-rldnr. "Ledger in GL Accounting
    DATA: rtcur       TYPE faglflext-rtcur. "Currency Key
    DATA: txt20       TYPE skat-txt20.      "Description Text
    DATA: saknr       TYPE skat-saknr.      "G/L account number
    DATA: ktopl       TYPE skat-ktopl.      "Chart of Accounts
    DATA: rpmax       TYPE faglflext-rpmax. "Period
    DATA: total_sum   LIKE faglflext-ksl01. "Amount of the first month
    DATA: ryear       LIKE faglflext-ryear. "Fiscal Year
    DATA: year        LIKE faglflext-ryear. "Past Year
    DATA: day_a       TYPE sy-datum.
    DATA: per_day     TYPE rr_umper.
    DATA: average     TYPE vtcur12.
    DATA: agregate    TYPE vtcur12.
    DATA: accumulate  TYPE vtcur12.
    DATA: average_sap TYPE rr_umper.
    DATA: END OF t_itab1.
    DATA: BEGIN OF t_itab2 OCCURS 0.
    DATA: rbukrs    TYPE faglflext-rbukrs. "Company Code
    DATA: racct     TYPE faglflext-racct. "Account ID
    DATA: prctr     TYPE faglflext-prctr. "Profit Center
    DATA: kslvt     TYPE faglflext-kslvt. "Total of the period in group currency
    DATA: ksl01     TYPE faglflext-ksl01. "Total of the period in group currency
    DATA: ksl02     TYPE faglflext-ksl02. "Total of the period in group currency
    DATA: ksl03     TYPE faglflext-ksl03. "Total of the period in group currency
    DATA: ksl04     TYPE faglflext-ksl04. "Total of the period in group currency
    DATA: ksl05     TYPE faglflext-ksl05. "Total of the period in group currency
    DATA: ksl06     TYPE faglflext-ksl06. "Total of the period in group currency
    DATA: ksl07     TYPE faglflext-ksl07. "Total of the period in group currency
    DATA: ksl08     TYPE faglflext-ksl08. "Total of the period in group currency
    DATA: ksl09     TYPE faglflext-ksl09. "Total of the period in group currency
    DATA: ksl10     TYPE faglflext-ksl10. "Total of the period in group currency
    DATA: ksl11     TYPE faglflext-ksl11. "Total of the period in group currency
    DATA: ksl12     TYPE faglflext-ksl12. "Total of the period in group currency
    DATA: ksl13     TYPE faglflext-ksl13. "Total of the period in group currency
    DATA: ksl14     TYPE faglflext-ksl14. "Total of the period in group currency
    DATA: ksl15     TYPE faglflext-ksl15. "Total of the period in group currency
    DATA: ksl16     TYPE faglflext-ksl16. "Total of the period in group currency
    DATA: rldnr     TYPE faglflext-rldnr. "Ledger in GL Accounting
    DATA: rtcur     TYPE faglflext-rtcur. "Currency Key
    DATA: txt20     TYPE skat-txt20.      "Description Text
    DATA: saknr     TYPE skat-saknr.      "G/L account number
    DATA: ktopl     TYPE skat-ktopl.      "Chart of Accounts
    DATA: rpmax     TYPE faglflext-rpmax. "Period
    DATA: total_sum LIKE faglflext-ksl01. "Amount of the first month
    DATA: ryear     LIKE faglflext-ryear. "Fiscal Year
    DATA: year      LIKE faglflext-ryear. "Past Year
    DATA: END OF t_itab2.
    DATA: BEGIN OF t_zavg OCCURS 0.
    DATA: bukrs       TYPE bukrs.
    DATA: racct       TYPE racct.
    DATA: prctr       TYPE prctr.
    DATA: day_a       TYPE sy-datum.
    DATA: per_day     TYPE rr_umper.
    DATA: average     TYPE vtcur12.
    DATA: agregate    TYPE vtcur12.
    DATA: accumulate  TYPE vtcur12.
    DATA: average_sap TYPE rr_umper.
    DATA: END OF t_zavg.
    DATA: BEGIN OF t_zavg2 OCCURS 0.
    DATA: day_a       TYPE sy-datum.
    DATA: racct       TYPE racct.
    DATA: prctr       TYPE prctr.
    DATA: per_day     TYPE rr_umper.
    DATA: average     TYPE vtcur12.
    DATA: agregate    TYPE vtcur12.
    DATA: accumulate  TYPE vtcur12.
    DATA: average_sap TYPE rr_umper.
    DATA: END OF t_zavg2.
    *                      Variable definition                             *
    DATA: balance_month_01          LIKE faglflext-ksl01.
    DATA: balance_month_02          LIKE faglflext-ksl01.
    DATA: balance_month_03          LIKE faglflext-ksl01.
    DATA: balance_month_04          LIKE faglflext-ksl01.
    DATA: balance_month_05          LIKE faglflext-ksl01.
    DATA: balance_month_06          LIKE faglflext-ksl01.
    DATA: balance_month_07          LIKE faglflext-ksl01.
    DATA: balance_month_08          LIKE faglflext-ksl01.
    DATA: balance_month_09          LIKE faglflext-ksl01.
    DATA: balance_month_10          LIKE faglflext-ksl01.
    DATA: balance_month_11          LIKE faglflext-ksl01.
    DATA: balance_month_12          LIKE faglflext-ksl01.
    DATA: balance_month_13          LIKE faglflext-ksl01.
    DATA: current_average_balance   LIKE zavg_bal_table-average.
    DATA: current_balance           LIKE faglflext-ksl01.
    DATA: current_activity_balance  LIKE faglflext-ksl01.
    DATA: current_aggregate_balance LIKE zavg_bal_table-agregate.
    DATA: average_balance_ytd       LIKE zfintbco0001-period_avg_12.
    DATA: count                     TYPE i.
    DATA: wa_itab                   LIKE LINE OF t_itab1.
    DATA: wa_low                    LIKE LINE OF t_itab1.
    DATA: wa_high                   LIKE LINE OF t_itab1.
    DATA: wa_itab2                  LIKE LINE OF t_itab2.
    DATA: wa_zavg2                  LIKE LINE OF t_zavg2.
    DATA: wa_zavg                   LIKE LINE OF t_zavg.
    DATA: t_acum                    TYPE i.
    DATA: companycode               TYPE faglflext-rbukrs.
    DATA: descripcion               TYPE skat-txt20.
    DATA: oref                      TYPE REF TO cx_root,
          emsg                      TYPE zedesc,
          param1                    TYPE zparm,
          parm1                     TYPE zparm.
    DATA: avg1                      TYPE faglflext-ksl01.  "AVG = AVERAGE
    DATA: avg2                      TYPE faglflext-ksl01.
    DATA: avg3                      TYPE faglflext-ksl01.
    DATA: avg4                      TYPE faglflext-ksl01.
    DATA: avg5                      TYPE faglflext-ksl01.
    DATA: avg6                      TYPE faglflext-ksl01.
    DATA: avg7                      TYPE faglflext-ksl01.
    DATA: avg8                      TYPE faglflext-ksl01.
    DATA: avg9                      TYPE faglflext-ksl01.
    DATA: avg10                     TYPE faglflext-ksl01.
    DATA: avg11                     TYPE faglflext-ksl01.
    DATA: avg12                     TYPE faglflext-ksl01.
    DATA: conteo                    TYPE i.
    DATA: conteo2                   TYPE i.
    DATA: numerocta                 TYPE faglflext-racct.
    DATA: profitcenter              TYPE faglflext-prctr.
    DATA: average_month_01          TYPE zavg_bal_table-average.
    DATA: aggregate_month_01        TYPE zavg_bal_table-agregate.
    DATA: average_month_02          TYPE zavg_bal_table-average.
    DATA: aggregate_month_02        TYPE zavg_bal_table-agregate.
    DATA: average_month_03          TYPE zavg_bal_table-average.
    DATA: aggregate_month_03        TYPE zavg_bal_table-agregate.
    DATA: average_month_04          TYPE zavg_bal_table-average.
    DATA: aggregate_month_04        TYPE zavg_bal_table-agregate.
    DATA: average_month_05          TYPE zavg_bal_table-average.
    DATA: aggregate_month_05        TYPE zavg_bal_table-agregate.
    DATA: average_month_06          TYPE zavg_bal_table-average.
    DATA: aggregate_month_06        TYPE zavg_bal_table-agregate.
    DATA: average_month_07          TYPE zavg_bal_table-average.
    DATA: aggregate_month_07        TYPE zavg_bal_table-agregate.
    DATA: average_month_08          TYPE zavg_bal_table-average.
    DATA: aggregate_month_08        TYPE zavg_bal_table-agregate.
    DATA: average_month_09          TYPE zavg_bal_table-average.
    DATA: aggregate_month_09        TYPE zavg_bal_table-agregate.
    DATA: average_month_10          TYPE zavg_bal_table-average.
    DATA: aggregate_month_10        TYPE zavg_bal_table-agregate.
    DATA: average_month_11          TYPE zavg_bal_table-average.
    DATA: aggregate_month_11        TYPE zavg_bal_table-agregate.
    DATA: average_month_12          TYPE zavg_bal_table-average.
    DATA: aggregate_month_12        TYPE zavg_bal_table-agregate.
    DATA: ano                       TYPE i.
    DATA: ano_pasado                TYPE i.
    DATA: ano_corriente             TYPE i.
    DATA: mesdia                    TYPE adb_pfrom.
    DATA: firstline                 TYPE i.
    DATA: kslvt                     TYPE faglflext-kslvt.
    DATA: ksl01                     TYPE faglflext-ksl01.
    DATA: ksl02                     TYPE faglflext-ksl02.
    DATA: ksl03                     TYPE faglflext-ksl03.
    DATA: ksl04                     TYPE faglflext-ksl04.
    DATA: ksl05                     TYPE faglflext-ksl05.
    DATA: ksl06                     TYPE faglflext-ksl06.
    DATA: ksl07                     TYPE faglflext-ksl07.
    DATA: ksl08                     TYPE faglflext-ksl08.
    DATA: ksl09                     TYPE faglflext-ksl09.
    DATA: ksl10                     TYPE faglflext-ksl10.
    DATA: ksl11                     TYPE faglflext-ksl11.
    DATA: ksl12                     TYPE faglflext-ksl12.
    DATA: ksl13                     TYPE faglflext-ksl13.
    DATA: ksl14                     TYPE faglflext-ksl14.
    DATA: ksl15                     TYPE faglflext-ksl15.
    DATA: ksl16                     TYPE faglflext-ksl16.
    DATA: itab_kslvt                TYPE faglflext-kslvt.
    DATA: itab_ksl01                TYPE faglflext-ksl01.
    DATA: itab_ksl02                TYPE faglflext-ksl02.
    DATA: itab_ksl03                TYPE faglflext-ksl03.
    DATA: itab_ksl04                TYPE faglflext-ksl04.
    DATA: itab_ksl05                TYPE faglflext-ksl05.
    DATA: itab_ksl06                TYPE faglflext-ksl06.
    DATA: itab_ksl07                TYPE faglflext-ksl07.
    DATA: itab_ksl08                TYPE faglflext-ksl08.
    DATA: itab_ksl09                TYPE faglflext-ksl09.
    DATA: itab_ksl10                TYPE faglflext-ksl10.
    DATA: itab_ksl11                TYPE faglflext-ksl11.
    DATA: itab_ksl12                TYPE faglflext-ksl12.
    DATA: itab_ksl13                TYPE faglflext-ksl13.
    DATA: itab_ksl14                TYPE faglflext-ksl14.
    DATA: itab_ksl15                TYPE faglflext-ksl15.
    DATA: itab_ksl16                TYPE faglflext-ksl16.
    DATA: itab_bal00                TYPE faglflext-kslvt.
    DATA: itab_bal01                TYPE faglflext-ksl01.
    DATA: itab_bal02                TYPE faglflext-ksl02.
    DATA: itab_bal03                TYPE faglflext-ksl03.
    DATA: itab_bal04                TYPE faglflext-ksl04.
    DATA: itab_bal05                TYPE faglflext-ksl05.
    DATA: itab_bal06                TYPE faglflext-ksl06.
    DATA: itab_bal07                TYPE faglflext-ksl07.
    DATA: itab_bal08                TYPE faglflext-ksl08.
    DATA: itab_bal09                TYPE faglflext-ksl09.
    DATA: itab_bal10                TYPE faglflext-ksl10.
    DATA: itab_bal11                TYPE faglflext-ksl11.
    DATA: itab_bal12                TYPE faglflext-ksl12.
    DATA: itab_bal13                TYPE faglflext-ksl13.
    DATA: itab_bal14                TYPE faglflext-ksl14.
    DATA: itab_bal15                TYPE faglflext-ksl15.
    DATA: itab_bal16                TYPE faglflext-ksl16.
    DATA: numero_de_cta             TYPE  faglflext-racct.
    DATA: company_code              TYPE  faglflext-rbukrs.
    DATA: profit_center             TYPE  faglflext-prctr.
    DATA: currency_code             TYPE  faglflext-rtcur.
    DATA: average_month             TYPE  zavg_bal_table-average.
    DATA: aggregate_month           TYPE  zavg_bal_table-agregate.
    * VARIABLES FOR INTERFACES LOG
    DATA: v_tipo                    TYPE zzfinbc85typede VALUE 1. "Tipo 1 = OUT
    DATA: v_nom_int(9)              TYPE c VALUE 'ZFINFII00'. "Nombre de la interfaz
    DATA: v_modulo(2)               TYPE c VALUE 'FI'. "Modulo
    DATA: v_comp_code(4)            TYPE c VALUE '0000'. "Compañia 0000
    DATA: v_alegacy(4)              TYPE c VALUE '0001'.
    DATA: v_fecha                   TYPE d.
    DATA: v_error2(3)               TYPE c VALUE 'E'.
    DATA: l_sys_exc                 TYPE REF TO  cx_ai_system_fault.
    DATA: last_day                  TYPE sy-datum.
    DATA: numero_mes                TYPE i.
    DATA: ryear                     TYPE faglflext-ryear.
    DATA: numero_cuenta             TYPE faglflext-racct.
    DATA: numero_profit             TYPE faglflext-prctr.
    DATA: day_a                     TYPE i.
    DATA: text(20)                  TYPE c.
    *Acknowledge
    DATA: lo_async_messaging        TYPE REF TO if_wsprotocol_async_messaging,
    lo_msg_id_protocol              TYPE REF TO if_wsprotocol_message_id,
    l_msg_id                        TYPE sxmsguid,
    l_ack_request                   TYPE prx_ack_request_details.
    DATA: fecha                     TYPE sy-datum.
    DATA: fecha_ejecutandose        TYPE sy-datum.
    DATA: fecha_corriente           TYPE i.
    DATA: jan_fin                   TYPE sy-datum.
    DATA: feb_fin                   TYPE sy-datum.
    DATA: febb_fin                  TYPE sy-datum.
    DATA: mar_fin                   TYPE sy-datum.
    DATA: apr_fin                   TYPE sy-datum.
    DATA: may_fin                   TYPE sy-datum.
    DATA: jun_fin                   TYPE sy-datum.
    DATA: jul_fin                   TYPE sy-datum.
    DATA: aug_fin                   TYPE sy-datum.
    DATA: sep_fin                   TYPE sy-datum.
    DATA: oct_fin                   TYPE sy-datum.
    DATA: nov_fin                   TYPE sy-datum.
    DATA: dec_fin                   TYPE sy-datum.
    DATA: porciento1                TYPE faglflext-ksl01.
    DATA: porciento2                TYPE faglflext-ksl01.
    DATA: porciento3                TYPE faglflext-ksl01.
    DATA: porciento4                TYPE faglflext-ksl01.
    DATA: porciento5                TYPE faglflext-ksl01.
    DATA: porciento6                TYPE faglflext-ksl01.
    DATA: porciento7                TYPE faglflext-ksl01.
    DATA: porciento8                TYPE faglflext-ksl01.
    DATA: porciento9                TYPE faglflext-ksl01.
    DATA: porciento10               TYPE faglflext-ksl01.
    DATA: porciento11               TYPE faglflext-ksl01.
    DATA: porciento12               TYPE faglflext-ksl01.
    data: mes(2)                    type c value '00'.
    data: mes_anterior              type sy-datum.
    data: ceros(2)                  type c.
    *DEFINICION DE RANGOS.
    RANGES profit FOR faglflext-prctr.
    RANGES account FOR faglflext-racct.
    RANGES end_month FOR zavg_bal_table-day_a.
    *Sele asigna el fin de mes a cada variable para que sea utilizada luego en el programa.
    jan_fin = '20060131'.
    feb_fin = '20060228'.
    febb_fin = '20060229'.
    mar_fin = '20060331'.
    apr_fin = '20060430'.
    may_fin = '20060531'.
    jun_fin = '20060630'.
    jul_fin = '20060731'.
    aug_fin = '20060831'.
    sep_fin = '20060930'.
    oct_fin = '20061031'.
    nov_fin = '20061130'.
    dec_fin = '20061231'.
    *Inicializando las variables a valor '0'.
    balance_month_01          = 0.
    balance_month_02          = 0.
    balance_month_03          = 0.
    balance_month_04          = 0.
    balance_month_05          = 0.
    balance_month_06          = 0.
    balance_month_07          = 0.
    balance_month_08          = 0.
    balance_month_09          = 0.
    balance_month_10          = 0.
    balance_month_11          = 0.
    balance_month_12          = 0.
    balance_month_13          = 0.
    current_average_balance   = 0.
    current_balance           = 0.
    current_activity_balance  = 0.
    current_aggregate_balance = 0.
    average_balance_ytd       = 0.
    count                     = 0.
    t_acum                    = 0.
    conteo                    = 1.
    conteo2                   = 1.
    ceros                     = '00'.
    *THIS IS A STRUCTURE NAMED E_SKAT. WITH THE TWO FIELDS NAMED SAKNR     *
    *AND TXT20.                                                            *
    TYPES: BEGIN OF e_skat,
             ktopl LIKE skat-ktopl,
             saknr LIKE skat-saknr,
             txt20 LIKE skat-txt20,
           END OF e_skat.
    *         SORT THE STRUCTURE IN ORDER FOR BEST PERFORMANCE             *
    DATA it_skat TYPE SORTED TABLE OF e_skat
         WITH UNIQUE KEY saknr WITH HEADER LINE.
    DATA: wa_skat                  LIKE LINE OF it_skat.
    *           CONSTANT DEFINITIONS (HAVE THE SAME VALUE EVER)            *
    CONSTANTS:
          etype                     TYPE zetype  VALUE 'INTER',       "Utilizada con la funcion de error
          innum                     TYPE zintnum VALUE 'ZFINFII00',       "Utilizada con la funcion de error
          inname                    TYPE zinname VALUE 'Sendero and Cognos Interfase', "Utilizada con la funcion de error
          c_cuenta(10)              TYPE c VALUE '0000270011',
          c_ol(2)                   TYPE c VALUE '0L',
          c_chart(4)                TYPE c VALUE 'CAPI',              "Chart Of Accounts
          c_ceros(17)               TYPE n VALUE '00000000000000.00', "ceros
          acct_cog(10)              TYPE n VALUE '0000270011',        "Numero de cta. que se busca en COGNOS.
          capi(4)                   TYPE c VALUE 'CAPI'.
    *                PARAMETROS de entrada para el usuario.                *
    SELECTION-SCREEN BEGIN OF BLOCK bl1 WITH FRAME TITLE text-001.
    PARAMETERS:
               p_date   TYPE sy-datum DEFAULT sy-datum.       "Fecha de corrida
    IF p_date IS INITIAL.
      p_date = sy-datum.
    ENDIF.
    *     PARAMETEROS DE ENTRADA POR MEDIO DE RANGOS PARA EL USUARIO       *
    SELECT-OPTIONS:
                p_bukrs FOR faglflext-rbukrs.
    SELECTION-SCREEN END OF BLOCK bl1.
    *IF THE USER SELECT THIS CHECK BOX WITH A CHECK MARK THE PROGRAM       *
    *SUBMIT THIS INTERFACE TO.                                             *
    SELECTION-SCREEN BEGIN OF BLOCK bl2 WITH FRAME TITLE text-002.
    PARAMETERS:
              p_cognos    TYPE c AS CHECKBOX.
    SELECTION-SCREEN END OF BLOCK bl2.
    * This statement calls the subroutine specified, SENDERO or COGNOS     *
    IF p_cognos IS INITIAL.
      PERFORM sendero.
    ELSE.
      PERFORM cognos.
    ENDIF.
    EXIT.
    *                      SENEDERO INTERFACE                              *
    FORM sendero.
    *ESTE SELECT EXTRAE LA DATA DE LA TABLA FAGFLEXT Y SKAT
      DATA: msgdetails     TYPE zgl_sendero_file_dt_tab.
      DATA: wa_msgdetails  LIKE LINE OF msgdetails.
      SELECT a~ryear a~rpmax a~rtcur a~racct a~rbukrs a~prctr
             a~kslvt a~ksl01 a~ksl02 a~ksl03 a~ksl04 a~ksl05
             a~ksl06 a~ksl07 a~ksl08 a~ksl09 a~ksl10 a~ksl11
             a~ksl12 a~ksl13 a~ksl14 a~ksl15 a~ksl16 b~saknr
             b~txt20 b~ktopl
            FROM  faglflext AS a INNER JOIN skat AS b ON a~racct = b~saknr AND a~rclnt = b~mandt
            CLIENT SPECIFIED INTO CORRESPONDING FIELDS OF TABLE t_itab1
        WHERE  a~rclnt = sy-mandt
          AND  a~rbukrs IN p_bukrs
          AND  a~rldnr  = '0L'
          AND  a~ryear  = p_date+0(4)
          AND  b~spras  EQ sy-langu
          AND  b~ktopl  EQ 'CAPI'.
    *SI NO ENCUENTRA DATA EN LA TABLA FAGLFLEXT ENVIA EL MENSAJE DE ERROR
    *A LA TABLA DE ERROR.
      IF sy-subrc <> 0.
        MOVE 'No data found in FLAGLFLEXT or ZAVG_BAL_TABLE for this process.'(e01) TO emsg.
    *    PERFORM call_error_function USING emsg.
    *    PERFORM call_log_function_send.
        MESSAGE: emsg TYPE 'E'.
      ENDIF.
    *EN ESTE SELECT SACO LA DESCRIPCION DE LA CUENTA
      SORT t_itab1 BY racct ASCENDING.
      DELETE t_itab1 WHERE racct = ''.
      SORT t_itab1 BY prctr ASCENDING.
      CLEAR t_itab1.
      READ TABLE t_itab1 INTO wa_low  INDEX 1 .
      DESCRIBE TABLE t_itab1 LINES firstline.
      READ TABLE t_itab1 INTO wa_high INDEX firstline.
      IF wa_high-prctr = 'DUMMY'.                      "SI EL ULTIMO RECORD CONTIENE ALGUN 'DUMMY' ESCOJER EL RECORD DE ARRIBA.
        firstline = firstline - 1.                     "CONTIENE EL NUMERO DEL INDICE.
        READ TABLE t_itab1 INTO wa_high INDEX firstline.
      ENDIF.
      profit-sign    = 'I'.
      profit-option  = 'BT'.
      profit-low     = wa_low-prctr.
      profit-high    = wa_high-prctr.
      APPEND profit.
    *COMPUTOS PARA CALCULAR EL ULTIMO DIA DEL MES.
      fecha       = p_date.
      numero_mes = p_date+4(2).                       "PASO NUMERO DEL MES A VARIABLE.
      p_date+4(2) = p_date+4(2) - numero_mes.         "LE RESTO EL MISMO MES A LA FECHA PARA COMENZAR EL CONTEO DESDE EL MES 1.
      DO numero_mes TIMES.                           "SE VA A EJECUTAR LAS MISMAS VECES DEL NUMERO DEL MES.
        p_date+4(2) = p_date+4(2) + 1.                  "SE INCREMENTA EL NUMERO DEL MES.
        CALL FUNCTION 'SG_PS_GET_LAST_DAY_OF_MONTH'    "Obtiene el ultimo numero del mes.
          EXPORTING
            day_in            = p_date
          IMPORTING
            last_day_of_month = last_day
          EXCEPTIONS
            day_in_not_valid  = 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.
        IF fecha = p_date.
          fecha = fecha - 1.   "le resta a fecha -1 para que busque en la tabla zavg_bal_table el record del dia anterior.
          end_month-sign    = 'I'.
          end_month-option  = 'EQ'.
          end_month-low     = fecha.
          APPEND end_month.
        ELSE.
          end_month-sign    = 'I'.
          end_month-option  = 'EQ'.
          end_month-low     = last_day.
          APPEND end_month.
        ENDIF.
      ENDDO.
      SORT end_month BY low ASCENDING.
      SELECT bukrs racct prctr day_a per_day average agregate accumulate average_sap
        FROM zavg_bal_table CLIENT SPECIFIED APPENDING TABLE t_zavg
        WHERE mandt = sy-mandt
          AND bukrs IN p_bukrs
          AND  day_a <= sy-datum
          AND  prctr IN profit.
      SORT t_itab1 BY rbukrs racct prctr.
      SORT t_zavg  BY  bukrs racct prctr day_a.
    *IMPRESION Y ENVIO DE LOS DATOS REQUERIDOS
    *Estos If verifican el mes que se esta ejecutando por el usuario para cambiarselo a la variable que identifica el fin de mes.
      IF p_date+4(2) = jan_fin+4(2).
        jan_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = feb_fin+4(2).
        feb_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = mar_fin+4(2).
        mar_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = apr_fin+4(2).
        apr_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = may_fin+4(2).
        may_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = jun_fin+4(2).
        jun_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = jul_fin+4(2).
        jul_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = aug_fin+4(2).
        aug_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = sep_fin+4(2).
        sep_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = oct_fin+4(2).
        oct_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = nov_fin+4(2).
        nov_fin+6(2) = p_date+6(2).
      ENDIF.
      IF p_date+4(2) = dec_fin+4(2).
        dec_fin+6(2) = p_date+6(2).
      ENDIF.
    *Comienza primer loop en el programa a t_itab1 que es la tabla interna que contiene los datos de faglflext.
      LOOP AT t_itab1 INTO wa_itab WHERE racct  NE ''.
        AT NEW prctr.  "Limpia las variables que se muestran en el clear cada ves que comienza un nuevo profit center.
          CLEAR: itab_kslvt, itab_ksl01, itab_ksl02, itab_ksl03, itab_ksl04, itab_ksl05, itab_ksl06, itab_ksl07, itab_ksl08,
                 itab_ksl09, itab_ksl10, itab_ksl11, itab_ksl12, itab_ksl13, itab_ksl14, itab_ksl15, itab_ksl16,
                 itab_bal00, itab_bal01, itab_bal02, itab_bal03, itab_bal04, itab_bal05, itab_bal06, itab_bal07,
                 itab_bal08, itab_bal09, itab_bal10, itab_bal11, itab_bal12, itab_bal13, itab_bal14, itab_bal15,
                 itab_bal16.
        ENDAT.
    *Se le pasa a la variable itab_ksl## el valor del mes que contenga flext.
        itab_kslvt = itab_kslvt + wa_itab-kslvt. itab_ksl01 = itab_ksl01 + wa_itab-ksl01. itab_ksl02 = itab_ksl02 + wa_itab-ksl02.
        itab_ksl03 = itab_ksl03 + wa_itab-ksl03. itab_ksl04 = itab_ksl04 + wa_itab-ksl04.
        itab_ksl05 = itab_ksl05 + wa_itab-ksl05. itab_ksl06 = itab_ksl06 + wa_itab-ksl06.
        itab_ksl07 = itab_ksl07 + wa_itab-ksl07. itab_ksl08 = itab_ksl08 + wa_itab-ksl08.
        itab_ksl09 = itab_ksl09 + wa_itab-ksl09. itab_ksl10 = itab_ksl10 + wa_itab-ksl10.
        itab_ksl11 = itab_ksl11 + wa_itab-ksl11. itab_ksl12 = itab_ksl12 + wa_itab-ksl12.
        itab_ksl13 = itab_ksl13 + wa_itab-ksl13. itab_ksl14 = itab_ksl14 + wa_itab-ksl14.
        itab_ksl15 = itab_ksl15 + wa_itab-ksl15. itab_ksl16 = itab_ksl16 + wa_itab-ksl16.
    *En estas variables va acumulando el valor por mes. Osea, va sumando todo lo que tenga de ese mes por profit center. Al venir un profit
    *nuevo esta se limpia.
        itab_bal00 = itab_bal00 + wa_itab-kslvt. itab_bal01 = itab_bal01 + wa_itab-ksl01. itab_bal02 = itab_bal02 + wa_itab-ksl02.
        itab_bal03 = itab_bal03 + wa_itab-ksl03. itab_bal04 = itab_bal04 + wa_itab-ksl04.
        itab_bal05 = itab_bal05 + wa_itab-ksl05. itab_bal06 = itab_bal06 + wa_itab-ksl06.
        itab_bal07 = itab_bal07 + wa_itab-ksl07. itab_bal08 = itab_bal08 + wa_itab-ksl08.
        itab_bal09 = itab_bal09 + wa_itab-ksl09. itab_bal10 = itab_bal10 + wa_itab-ksl10.
        itab_bal11 = itab_bal11 + wa_itab-ksl11. itab_bal12 = itab_bal12 + wa_itab-ksl12.
        itab_bal13 = itab_bal13 + wa_itab-ksl13. itab_bal14 = itab_bal14 + wa_itab-ksl14.
        itab_bal15 = itab_bal15 + wa_itab-ksl15. itab_bal16 = itab_bal16 + wa_itab-ksl16.
        ryear = wa_itab-ryear.
        CLEAR t_zavg.
        sy-subrc = 0.
        numero_de_cta   = wa_itab-racct.
        company_code    = wa_itab-rbukrs.
        profit_center   = wa_itab-prctr.
        currency_code   = wa_itab-rtcur.
        descripcion     = wa_itab-txt20.
    *Segundo loop a realizarce. Este utiliza la tabla interna: t_zavg la cual contiene los datos extraidos de zavg_bal_table.
        LOOP AT t_zavg INTO wa_zavg WHERE bukrs = wa_itab-rbukrs AND racct = wa_itab-racct AND prctr = wa_itab-prctr.
          AT NEW prctr.  "Al cambiar el profit center limpia las variables que se encuentran en el clear.
            CLEAR: average_month_01, average_month_02, average_month_03, average_month_04, average_month_05,
             average_month_06, average_month_07, average_month_08, average_month_09, average_month_10, average_month_11,
             average_month_12, average_month.
          ENDAT.
    *Dependiendo del mes que contiene el record de la tabla t_zavg este va acumulando el average_month.
          IF wa_zavg-day_a+4(2) = '01'.
            average_month_01   = average_month_01 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '02'.
            average_month_02   = average_month_02 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '03'.
            average_month_03   = average_month_03 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '04'.
            average_month_04   = average_month_04 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '05'.
            average_month_05   = average_month_05 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '06'.
            average_month_06   = average_month_06 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '07'.
            average_month_07   = average_month_07 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '08'.
            average_month_08   = average_month_08 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '09'.
            average_month_09   = average_month_09 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '10'.
            average_month_10   = average_month_10 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '11'.
            average_month_11   = average_month_11 + wa_zavg-accumulate.
          ENDIF.
          IF wa_zavg-day_a+4(2) = '12'.
            average_month_12   = average_month_12 + wa_zavg-accumulate.
          ENDIF.
    *Este if verifica que cuando el record que se esta verificando sea con fecha de fin de mes calcule el resto del codigo que se encuentra debajo.
          IF wa_zavg-day_a = jan_fin OR wa_zavg-day_a = feb_fin OR wa_zavg-day_a = mar_fin OR wa_zavg-day_a = apr_fin OR wa_zavg-day_a = may_fin OR wa_zavg-day_a = jun_fin OR
          wa_zavg-day_a = jul_fin OR wa_zavg-day_a = aug_fin OR wa_zavg-day_a = sep_fin OR wa_zavg-day_a = oct_fin OR
          wa_zavg-day_a = nov_fin OR wa_zavg-day_a = dec_fin.
            aggregate_month =  wa_zavg-agregate.
            day_a  = wa_zavg-day_a.
    *Calcula el aggregate_month dependiendo de la fecha del record que se esta procesando.
            IF wa_zavg-day_a+4(2) = '01'.
              aggregate_month_01 =  wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '02'.
              aggregate_month_02 =  wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '03'.
              aggregate_month_03 = wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '04'.
              aggregate_month_04 =  wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '05'.
              aggregate_month_05 =  wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '06'.
              aggregate_month_06 =  wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '07'.
              aggregate_month_07 =  wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '08'.
              aggregate_month_08 =  wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '09'.
              aggregate_month_09 =  wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '10'.
              aggregate_month_10 =  wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '11'.
              aggregate_month_11 =  wa_zavg-agregate.
            ENDIF.
            IF wa_zavg-day_a+4(2) = '12'.
              aggregate_month_12 =  wa_zavg-agregate.
            ENDIF.
          ENDIF.
    *Este if verifica que cuando el record que se esta verificando sea con fecha de fin de mes calcule el resto del codigo que se encuentra debajo.
          IF wa_zavg-day_a+4(4) = jan_fin+4(4) OR wa_zavg-day_a+4(4) = feb_fin+4(4) OR wa_zavg-day_a+4(4) = febb_fin+4(4) OR wa_zavg-day_a+4(4) = mar_fin+4(4) OR
             wa_zavg-day_a+4(4) = apr_fin+4(4) OR wa_zavg-day_a+4(4) = may_fin+4(4) OR wa_zavg-day_a+4(4) = jun_fin+4(4) OR wa_zavg-day_a+4(4) = jul_fin+4(4) OR
             wa_zavg-day_a+4(4) = aug_fin+4(4) OR wa_zavg-day_a+4(4) = sep_fin+4(4) OR wa_zavg-day_a+4(4) = oct_fin+4(4) OR wa_zavg-day_a+4(4) = nov_fin+4(4) OR
             wa_zavg-day_a+4(4) = dec_fin+4(4).
    *Calcula la division entre la cantidad acumulada por mes y la fecha del fin de mes.
            IF average_month_01 IS NOT INITIAL.
              porciento1 = average_month_01 / jan_fin+6(2).
              average_month   = porciento1.
            ENDIF.
            IF average_month_02 IS NOT INITIAL.
              porciento2 = average_month_02 / feb_fin+6(2).
              average_month   = porciento2.
            ENDIF.
            IF average_month_03 IS NOT INITIAL.
              porciento3 = average_month_03 / mar_fin+6(2).
              average_month   = porciento3.
            ENDIF.
            IF average_month_04 IS NOT INITIAL.
              porciento4 = average_month_04 / apr_fin+6(2).
              average_month   = porciento4.
            ENDIF.
            IF average_month_05 IS NOT INITIAL.
              porciento5 = average_month_05 / may_fin+6(2).
              average_month   = porciento5.
            ENDIF.
            IF average_month_06 IS NOT INITIAL.
              porciento6 = average_month_06 / jun_fin+6(2).
              average_month   = porciento6.
            ENDIF.
            IF average_month_07 IS NOT INITIAL.
              porciento7 = average_month_07 / jul_fin+6(2).
              average_month   = porciento7.
            ENDIF.
            IF average_month_08 IS NOT INITIAL.
              porciento8 = average_month_08 / aug_fin+6(2).
              average_month   = porciento8.
            ENDIF.
            IF average_month_09 IS NOT INITIAL.
              porciento9 = average_month_09 / sep_fin+6(2).
              average_month   = porciento9.
            ENDIF.
            IF average_month_10 IS NOT INITIAL.
              porciento10 = average_month_10 / oct_fin+6(2).
              average_month   = porciento10.
            ENDIF.
            IF average_month_11 IS NOT INITIAL.
              porciento11 = average_month_11 / nov_fin+6(2).
              average_month   = porciento11.
            ENDIF.
            IF average_month_12 IS NOT INITIAL.
              porciento12 = average_month_12 / dec_fin+6(2).
              average_month   = porciento12.
            ENDIF.
    *Cuando la fecha que esta entrando el usuario es la misma a la del record que se esta procesando en ese momento ejecuta el siguiente IF.
            IF p_date+4(4) = wa_zavg-day_a+4(4).
              current_average_balance   =  average_month.
              current_aggregate_balance =  aggregate_month.
              average_balance_ytd       =  average_month.
            ENDIF.
          ENDIF.
        ENDLOOP.
        AT END OF prctr.
          IF sy-subrc = 0.
    *ESTAS VARIABLES SE ESTAN PASANDO A UNA VARIABLE NORMAL YA QUE SI SE DEJAN DENTRO DEL WORK AREA (WA) LE PONE ASTERISCOS.
    *LOS IF QUE SE DEMUESTRAN ABAJO SON PARECIDOS A LOS UTILIZADOS EN LA   *
    *PARTE POSTERIOR LO UNICO QUE LA FECHA UTILIZADA NO ES EXTRAIDA DE LA  *
    *TABLA, ES LA QUE EL USUARIO INSERTA DENTRO DEL PARAMETRO.             *
            IF p_date+4(2) >= '01'.
              COMPUTE: balance_month_01 =   itab_bal00 + itab_bal01.
            ENDIF.
            IF p_date+4(2) >= '02'.
              COMPUTE: balance_month_02 = itab_bal00 + itab_bal01 + itab_bal02.
            ENDIF.
            IF p_date+4(2) >= '03'.
              COMPUTE: balance_month_03 = itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03.
            ENDIF.
            IF p_date+4(2) >= '04'.
              COMPUTE: balance_month_04 = itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04.
            ENDIF.
            IF p_date+4(2) >= '05'.
              COMPUTE: balance_month_05 = itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04 + itab_bal05.
            ENDIF.
            IF p_date+4(2) >= '06'.
              COMPUTE: balance_month_06 =  itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04 + itab_bal05 + itab_bal06.
            ENDIF.
            IF p_date+4(2) >= '07'.
              COMPUTE: balance_month_07 =  itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04 + itab_bal05 + itab_bal06 + itab_bal07.
            ENDIF.
            IF p_date+4(2) >= '08'.
              COMPUTE: balance_month_08 =  itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04 + itab_bal05 + itab_bal06 + itab_bal07 + itab_bal08.
            ENDIF.
            IF p_date+4(2) >= '09'.
              COMPUTE: balance_month_09 =  itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04 + itab_bal05 + itab_bal06 + itab_bal07 + itab_bal08 + itab_bal09.
            ENDIF.
            IF p_date+4(2) >= '10'.
              COMPUTE: balance_month_10 =  itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04 + itab_bal05 + itab_bal06 + itab_bal07 + itab_bal08 + itab_bal09 + itab_bal10.
            ENDIF.
            IF p_date+4(2) >= '11'.
              COMPUTE: balance_month_11 = itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04 + itab_bal05 + itab_bal06 + itab_bal07 + itab_bal08 + itab_bal09 + itab_bal10 + itab_bal11.
            ENDIF.
            IF p_date+4(2) >= '12'.
              COMPUTE: balance_month_12 =  itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04 + itab_bal05 + itab_bal06 + itab_bal07 + itab_bal08 + itab_bal09 + itab_bal10 + itab_bal11 + itab_bal12.
            ENDIF.
            IF p_date+4(2) >= '13'.
              COMPUTE: balance_month_13 = itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04 + itab_bal05 + itab_bal06 + itab_bal07 + itab_bal08 + itab_bal09 + itab_bal10 + itab_bal11 + itab_bal12 + itab_bal13.
            ENDIF.
          COMPUTE: current_balance =  + itab_bal00 + itab_bal01 + itab_bal02 + itab_bal03 + itab_bal04 + itab_bal05 + itab_bal06 + itab_bal07 + itab_bal08 + itab_bal09 + itab_bal10 + itab_bal11 + itab_bal12 + itab_bal13 + itab_bal14 + itab_bal15 + itab_bal16.
    *Computo para el activity balance.
            IF p_date+4(2) = '01'.
              current_activity_balance =   itab_ksl01.
            ENDIF.
            IF p_date+4(2) = '02'.
              current_activity_balance =   itab_ksl02.
            ENDIF.
            IF p_date+4(2) = '03'.
              current_activity_balance =   itab_ksl03.
            ENDIF.
            IF p_date+4(2) = '04'.
              current_activity_balance =   itab_ksl04.
            ENDIF.
            IF p_date+4(2) = '05'.
              current_activity_balance =   itab_ksl05.
            ENDIF.
            IF p_date+4(2) = '06'.
              current_activity_balance =   itab_ksl06.
            ENDIF.
            IF p_date+4(2) = '07'.
              current_activity_balance =   itab_ksl07.
            ENDIF.
            IF p_date+4(2) = '08'.
              current_activity_balance =   itab_ksl08.
            ENDIF.
            IF p_date+4(2) = '09'.
              current_activity_balance =   itab_ksl09.
            ENDIF.
            IF p_date+4(2) = '10'.
              current_activity_balance =   itab_ksl10.
            ENDIF.
            IF p_date+4(2) = '11'.
              current_activity_balance =   itab_ksl11.
            ENDIF.
            IF p_date+4(2) = '12'.
              current_activity_balance =   itab_ksl12.
            ENDIF.
    *LE RESTA 1 AL AÑO CORRIENTE PARA VERIFICAR LUEGO SI EXISTE INFORMACION*
    *DE AÑOS ANTERIORES.                                                   *
            ano = ryear - 1.
    *               Get the values of the past year.                    *
            ano =  p_date+0(4) - 1.
            IF ryear = ano.
              wa_msgdetails-activity_previous_year = itab_ksl12.
    *     balance_previous_year = wa_msgdetails-balance_previous_year.  *
              wa_msgdetails-average_previous_year  = average_month_12.
              wa_msgdetails-aggreg_previous_year   = aggregate_month_12.
            ELSE.
    *If the table don't have data the variables get '0000000000000'.    *
              wa_msgdetails-activity_previous_year          = '00000000000000.00'.
              wa_msgdetails-average_previous_year           = '00000000000000.00'.
              wa_msgdetails-aggreg_previous_year            = '00000000000000.00'.
              AT LAST.
                wa_msgdetails-balance_previous_year           = '00000000000000.00'.
                wa_msgdetails-balance_previous_year           = itab_kslvt +
                                                                itab_ksl01 +
                                                                itab_ksl02 +
                                                                itab_ksl03 +
                                                                itab_ksl04 +
                                                                itab_ksl05 +
                                                                itab_ksl06 +
                                                                itab_ksl07 +
                                                                itab_ksl08 +
                                                                itab_ksl09 +
                                                                itab_ksl10 +
                                                                itab_ksl11 +
                                                                itab_ksl12.
              ENDAT.
            ENDIF.
            wa_msgdetails-account             = numero_de_cta.
            wa_msgdetails-company             = company_code.
            wa_msgdetails-cost_center         = profit_center.
            wa_msgdetails-currency_code       = currency_code.
            wa_msgdetails-account_description = descripcion.
            wa_msgdetails-activity_month_01   = itab_ksl01.
            wa_msgdetails-average_month_01    = porciento1.
            wa_msgdetails-aggreg_month_01     = aggregate_month_01.
            wa_msgdetails-activity_month_02   = itab_ksl02.
            wa_msgdetails-average_month_02    = porciento2.
            wa_msgdetails-aggreg_month_02     = aggregate_month_02.
            wa_msgdetails-activity_month_03   = itab_ksl03.
            wa_msgdetails-average_month_03    = porciento3.
            wa_msgdetails-aggreg_month_03     = aggregate_month_03.
            wa_msgdetails-activity_month_04   = itab_ksl04.
            wa_msgdetails-average_month_04    = porciento4.
            wa_msgdetails-aggreg_month_04     = aggregate_month_04.
            wa_msgdetails-activity_month_05   = itab_ksl05.
            wa_msgdetails-average_month_05    = porciento5.
            wa_msgdetails-aggreg_month_05     = aggregate_month_05.
            wa_msgdetails-activity_month_06   = itab_ksl06.
            wa_msgdetails-average_month_06    = porciento6.
            wa_msgdetails-aggreg_month_06     = aggregate_month_06.
            wa_msgdetails-activity_month_07   = itab_ksl07.
            wa_msgdetails-average_month_07    = porciento7.
            wa_msgdetails-aggreg_month_07     = aggregate_month_07.
            wa_msgdetails-activity_month_08   = itab_ksl08.
            wa_msgdetails-average_month_08    = porciento8.
            wa_msgdetails-aggreg_month_08     = aggregate_month_08.
            wa_msgdetails-activity_month_09   = itab_ksl09.
            wa_msgdetails-average_month_09    = porciento9.
            wa_msgdetails-aggreg_month_09     = aggregate_month_09.
            wa_msgdetails-activity_month_10   = itab_ksl10.
            wa_msgdetails-average_month_10    = porciento10.
            wa_msgdetails-aggreg_month_10     = aggregate_month_10.
            wa_msgdetails-activity_month_11   = itab_ksl11.
            wa_msgdetails-average_month_11    = porciento11.
            wa_msgdetails-aggreg_month_11     = aggregate_month_11.
            wa_msgdetails-activity_month_12   = itab_ksl12.
            wa_msgdetails-average_month_12    = porciento12.
            wa_msgdetails-aggreg_month_12     = aggregate_month_12.
            wa_msgdetails-activity_month_13   = itab_ksl13.
            wa_msgdetails-average_month_13    = '00000000000000.00'.
            wa_msgdetails-aggreg_month_13     = '00000000000000.00'.
            wa_msgdetails-balance_month_01          = balance_month_01.
            wa_msgdetails-balance_month_02          = balance_month_02.
            wa_msgdetails-balance_month_03          = balance_month_03.
            wa_msgdetails-balance_month_04          = balance_month_04.
            wa_msgdetails-balance_month_05          = balance_month_05.
            wa_msgdetails-balance_month_06          = balance_month_06.
            wa_msgdetails-balance_month_07          = balance_month_07.
            wa_msgdetails-balance_month_08          = balance_month_08.
            wa_msgdetails-balance_month_09          = balance_month_09.
            wa_msgdetails-balance_month_10          = balance_month_10.
            wa_msgdetails-balance_month_11          = balance_month_11.
            wa_msgdetails-balance_month_12          = balance_month_12.
            wa_msgdetails-balance_month_13          = balance_month_13.
            wa_msgdetails-current_balance           = current_balance.
            wa_msgdetails-current_activity_balance  = current_activity_balance.
            CLEAR: porciento1, porciento2, porciento3, porciento4, porciento5, porciento6, porciento7, porciento8, porciento9, porciento10, porciento11,
                   porciento12, average_month.
    *se multiplican las siguientes variables que contienen cantidades por -1 cuando el primer numero de la cta. es igual a
    * 5, 6, 7, ó 8.
            IF numero_de_cta+4(1) = '5' OR numero_de_cta+4(1) = '6' OR numero_de_cta+4(1) = '7' OR numero_de_cta+4(1) = '8'.
              IF wa_msgdetails-current_balance IS NOT INITIAL.
                wa_msgdetails-current_balance = wa_msgdetails-current_balance * -1.
              ENDIF.
              IF wa_msgdetails-activity_previous_year IS NOT INITIAL.
                wa_msgdetails-activity_previous_year = wa_msgdetails-activity_previous_year * -1.
              ENDIF.
              IF wa_msgdetails-average_previous_year IS NOT INITIAL.
                wa_msgdetails-average_previous_year = wa_msgdetails-average_previous_year * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_previous_year IS NOT INITIAL.
                wa_msgdetails-aggreg_previous_year = wa_msgdetails-aggreg_previous_year * -1.
              ENDIF.
              IF wa_msgdetails-balance_previous_year IS NOT INITIAL.
                wa_msgdetails-balance_previous_year = wa_msgdetails-balance_previous_year * -1.
              ENDIF.
              IF wa_msgdetails-current_activity_balance IS NOT INITIAL.
                wa_msgdetails-current_activity_balance = wa_msgdetails-current_activity_balance * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_01 IS NOT INITIAL.
                wa_msgdetails-activity_month_01 = wa_msgdetails-activity_month_01 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_01 IS NOT INITIAL.
                wa_msgdetails-balance_month_01 = wa_msgdetails-balance_month_01 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_01 IS NOT INITIAL.
                wa_msgdetails-average_month_01 = wa_msgdetails-average_month_01 * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_month_01 IS NOT INITIAL.
                wa_msgdetails-aggreg_month_01 = wa_msgdetails-aggreg_month_01 * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_02 IS NOT INITIAL.
                wa_msgdetails-activity_month_02 = wa_msgdetails-activity_month_02 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_02 IS NOT INITIAL.
                wa_msgdetails-balance_month_02 = wa_msgdetails-balance_month_02 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_02 IS NOT INITIAL.
                wa_msgdetails-average_month_02 = wa_msgdetails-average_month_02 * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_month_02 IS NOT INITIAL.
                wa_msgdetails-aggreg_month_02 = wa_msgdetails-aggreg_month_02 * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_03 IS NOT INITIAL.
                wa_msgdetails-activity_month_03 = wa_msgdetails-activity_month_03 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_03 IS NOT INITIAL.
                wa_msgdetails-balance_month_03 = wa_msgdetails-balance_month_03 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_03 IS NOT INITIAL.
                wa_msgdetails-average_month_03 = wa_msgdetails-average_month_03 * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_month_03 IS NOT INITIAL.
                wa_msgdetails-aggreg_month_03 = wa_msgdetails-aggreg_month_03 * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_04 IS NOT INITIAL.
                wa_msgdetails-activity_month_04 = wa_msgdetails-activity_month_04 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_04 IS NOT INITIAL.
                wa_msgdetails-balance_month_04 = wa_msgdetails-balance_month_04 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_04 IS NOT INITIAL.
                wa_msgdetails-average_month_04 = wa_msgdetails-average_month_04 * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_month_04 IS NOT INITIAL.
                wa_msgdetails-aggreg_month_04 = wa_msgdetails-aggreg_month_04 * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_05 IS NOT INITIAL.
                wa_msgdetails-activity_month_05 = wa_msgdetails-activity_month_05 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_05 IS NOT INITIAL.
                wa_msgdetails-balance_month_05 = wa_msgdetails-balance_month_05 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_05 IS NOT INITIAL.
                wa_msgdetails-average_month_05 = wa_msgdetails-average_month_05 * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_month_05 IS NOT INITIAL.
                wa_msgdetails-aggreg_month_05 = wa_msgdetails-aggreg_month_05 * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_06 IS NOT INITIAL.
                wa_msgdetails-activity_month_06 = wa_msgdetails-activity_month_06 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_06 IS NOT INITIAL.
                wa_msgdetails-balance_month_06 = wa_msgdetails-balance_month_06 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_06 IS NOT INITIAL.
                wa_msgdetails-average_month_06 = wa_msgdetails-average_month_06 * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_month_06 IS NOT INITIAL.
                wa_msgdetails-aggreg_month_06 = wa_msgdetails-aggreg_month_06 * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_07 IS NOT INITIAL.
                wa_msgdetails-activity_month_07 = wa_msgdetails-activity_month_07 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_07 IS NOT INITIAL.
                wa_msgdetails-balance_month_07 = wa_msgdetails-balance_month_07 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_07 IS NOT INITIAL.
                wa_msgdetails-average_month_07 = wa_msgdetails-average_month_07 * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_month_07 IS NOT INITIAL.
                wa_msgdetails-aggreg_month_07 = wa_msgdetails-aggreg_month_07 * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_08 IS NOT INITIAL.
                wa_msgdetails-activity_month_08 = wa_msgdetails-activity_month_08 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_08 IS NOT INITIAL.
                wa_msgdetails-balance_month_08 = wa_msgdetails-balance_month_08 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_08 IS NOT INITIAL.
                wa_msgdetails-average_month_08 = wa_msgdetails-average_month_08 * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_month_08 IS NOT INITIAL.
                wa_msgdetails-aggreg_month_08 = wa_msgdetails-aggreg_month_08 * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_09 IS NOT INITIAL.
                wa_msgdetails-activity_month_09 = wa_msgdetails-activity_month_09 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_09 IS NOT INITIAL.
                wa_msgdetails-balance_month_09 = wa_msgdetails-balance_month_09 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_09 IS NOT INITIAL.
                wa_msgdetails-average_month_09 = wa_msgdetails-average_month_09 * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_month_09 IS NOT INITIAL.
                wa_msgdetails-aggreg_month_09 = wa_msgdetails-aggreg_month_09 * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_10 IS NOT INITIAL.
                wa_msgdetails-activity_month_10 = wa_msgdetails-activity_month_10 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_10 IS NOT INITIAL.
                wa_msgdetails-balance_month_10 = wa_msgdetails-balance_month_10 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_10 IS NOT INITIAL.
                wa_msgdetails-average_month_10 = wa_msgdetails-average_month_10 * -1.
              ENDIF.
              IF wa_msgdetails-aggreg_month_10 IS NOT INITIAL.
                wa_msgdetails-aggreg_month_10 = wa_msgdetails-aggreg_month_10 * -1.
              ENDIF.
              IF wa_msgdetails-activity_month_11 IS NOT INITIAL.
                wa_msgdetails-activity_month_11 = wa_msgdetails-activity_month_11 * -1.
              ENDIF.
              IF wa_msgdetails-balance_month_11 IS NOT INITIAL.
                wa_msgdetails-balance_month_11 = wa_msgdetails-balance_month_11 * -1.
              ENDIF.
              IF wa_msgdetails-average_month_11 IS NOT INITIAL.
                wa_msgdetails-average_month_11 = wa_msgdetails-average_month_11 *

    Hi,
    Are the month-ends (jan_fin etc) stored in the system? There are many variable declarations and if statements that could probably be eliminated if that is the case.  More efficient use of storing those variables in internal tables so that the data is only used when needed.
    Warren

  • Problems with Nvidia 320.49 and Windows 8.1

    I am having problems with my HP Envy with windows 8.1... Nvidia driver keeps crashing.
    Took the unit to Best Buy and we determined it was with the 320.49 driver - we are
    able to reinstall it, and it will usually last for a few hours before it fails again.  When
    it fails, the resolution reverts to 1024 x XX... not the 1920 x 1260 when it works
    right... very frustrating, but I need to know if the card needs replacement, or if there
    is a fix from Nvidia... Contacted Nvidia and did not get anywhere with them.... can anyone
    help??

    Thank you for the additional information.
    If it is an HP OEM video card, this is the reason that it is not working with the retail nVidia driver.  HP has their motherboards and video cards made to their specs.  Only the drivers developed by them will work with their cards.
    Here are the drivers available for Win 8.1 on the Software & driver download page.
    Please click the "Thumbs up + button" if I have helped you and click "Accept as Solution" if your problem is solved.
    Signature:
    HP TouchPad - 1.2 GHz; 1 GB memory; 32 GB storage; WebOS/CyanogenMod 11(Kit Kat)
    HP 10 Plus; Android-Kit Kat; 1.0 GHz Allwinner A31 ARM Cortex A7 Quad Core Processor ; 2GB RAM Memory Long: 2 GB DDR3L SDRAM (1600MHz); 16GB disable eMMC 16GB v4.51
    HP Omen; i7-4710QH; 8 GB memory; 256 GB San Disk SSD; Win 8.1
    HP Photosmart 7520 AIO
    ++++++++++++++++++
    **Click the Thumbs Up+ to say 'Thanks' and the 'Accept as Solution' if I have solved your problem.**
    Intelligence is God given; Wisdom is the sum of our mistakes!
    I am not an HP employee.

Maybe you are looking for

  • Pluging the iphone to Win7 iTunes

    hi every one. i have an iTunes installed and working good on my home PC with WinXP. I bought a new laptop with Windows 7 and I want to install the iTunes there and connect my iphone to it, how do i do it, So all my information will be saved?

  • MacbookPro 17 end 2006 compared to Macbook Pro 13

    Hello How is the MacbookPro 13 / 2,4 / Geforce 320M compared to the Macbook Pro 17 / 2,33 / Ati X1600XT / rev 2,1 / end 2006 ? And specially, is the graphic card really better ? Thank you Message was edited by: LaurentR2D2

  • Configure SSL Throughout Portal in 10.1.2.0.2

    My installation is going to contain both the Infrastructure (IM, SSO) as well as the Middle-tier (Portal) and I want to later configure SSL. Oracle says in the documentation that the servername must be different for each home. I'm thinking that I wil

  • Photoshop Elements 10 + Premiere nur für Windows 7 - 64 bit???

    Hallo, einen Tag nach meiner Bestellung war das Päckchen schon da, und auf der Verpackung steht extra hervorgehoben, daß Premiere Elements  nur mit 64 bit läuft, obwohl ich das vorher bei den Voraussetzungen etwas anders verstanden habe. Wenn das abe

  • How to retrieve Facebook pictures when I deleted them from iPhoto?

    Hi. I'm new to Mac and not very techy. Anyway, I synced my Facebook account to iPhoto and for some reason, I thought that iPhoto was just a back up of my facebook photos. I deleted the facebook pictures on iPhoto and now, I have lost all of my Facebo