Taking a screenshot of StageWebView for websites running a plugin?

I've been trying to take a screenshot of an instance of StageWebView for websites with embedded SWF and PDF content on the Android. The method drawViewPortToBitmapData works fine for regular websites after enabling hardware acceleration in the manifest.
//create a bitmap from the webview and display it
var bitmap_data:BitmapData = new BitmapData(stage.stageWidth - 2*WEBVIEWOFFSET, stage.stageHeight - 40 - WEBVIEWOFFSET);
webView.drawViewPortToBitmapData(bitmap_data); 
//remove webview and display snapshot
webView.stage = null;
var webViewBitmap:Bitmap = new Bitmap(bitmap_data);
addChild(webViewBitmap);
The previous code works for embedded content only on the emulator in the Flash IDE. The image is generated  in the folder I specified in Windows but on the Android a blank image is created instead.
The API states "The behavior of this method is not guaranteed for pages that contain plugin content (such as embedded PDF and SWF files)."
http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/media/StageWebVie w.html#drawViewPortToBitmapData%28%29
I tried using Context3D instead:
var stage3D:Stage3D = webView.stage.stage3Ds[0];
stage3D.addEventListener(Event.CONTEXT3D_CREATE, context3dCreated);
stage3D.requestContext3D(Context3DRenderMode.AUTO);
function context3dCreated(evt:Event ):void {
    //context 3d creation handler
    var bitmap_data:BitmapData = new BitmapData(stage.stageWidth - 2*WEBVIEWOFFSET, stage.stageHeight - 40 - WEBVIEWOFFSET);
    var renderContext:Context3D = Stage3D(evt.target).context3D;
    trace("3D driver: " + renderContext.driverInfo);
    renderContext.drawToBitmapData(bitmap_data);
    renderContext.present();
    //remove webview and display snapshot
    webView.stage = null;
    var webViewBitmap:Bitmap = new Bitmap(bitmap_data);
    addChild(webViewBitmap);      
but this approach only generates blank images on both the emulator and the device.
Does anybody know of a way to take a screenshot from a StageWebView displaying embedded SWF or PDF content? or is there a free native extension that can trigger the screenshot in Android (power + home)?

andylow wrote:
When I press shift + command + 4, I always go into this highlight-for-screenshot mode (good). However, if I'm attempting to screenshot something in a VMWare session, when I press my left mouse button to start highlighting, I can still manipulate the applications running in it. Ex: I press shift + command + 4, my mouse pointer changes, I then start my screen highlight by beginning over the top of the close button on an application. That application will close because I've clicked the close button.
This may not help, but what if you start creating the screenshot rectangle in a different corner than the upper left?

Similar Messages

  • Statistics for websites running on OS X Server?

    I'm curious what you all are using for website statistics. At work we use Google Analytics and it seems pretty good, and in the past I've played with AWStats but had some configuration hassles.
    Are there any good web stats plug-ins for OS X Server, or do you all use Google Analytics?

    We use Summary from Summary.net and have been quite happy with its performance and usability / configuration.

  • Taking a screenShot/Snapshot programmatically for iOS7 gives me an error

    I am writing the code for capturing the screenShot of what I see on my screen when I press a button in Unity.
    I am writing the following code :
    ScreenCapture.h
    #import <Foundation/Foundation.h>
    #import <UIKit/UIKit.h>
    #import "QuartzCore/QuartzCore.h"
    @interface ScreenCaptureDelegate : UIViewController {
    - (IBAction)ScreenShot;
    @end
    AND
    ScreenCapture.mm
    #import "ScreenCapture.h"
    #import "QuartzCore/QuartzCore.h"
    @implementation ScreenCaptureDelegate
    - (IBAction)ScreenShot {
        UIGraphicsBeginImageContext(self.view.bounds.size);
        [self.view drawViewHierarchyInRect:self.view.frame afterScreenUpdates:NO];
        UIImage *screenshotimage = UIGraphicsGetImageFromCurrentImageContext();
        UIGraphicsEndImageContext();
        UIImageWriteToSavedPhotosAlbum(screenshotimage, nil, nil, nil);
    @end
    static ScreenCaptureDelegate *delegateObject = nil;
    // When native code plugin is implemented in .mm / .cpp file, then functions
    // should be surrounded with extern "C" block to conform C function naming rules
    extern "C" {
        void _showPopUp(const char* Picture)
            [delegateObject ScreenShot];
    When I run this on the ipad I only get blank images.I have updated my ipad to use ios7.
    I even tried with the renderInContext command, even there I get blank images. So i tried with the drawViewHierarchyInRect   .
    I even used the snapshotViewAfterScreenUpdates but here I dont even get a blank image.
    Am i going wrong somewhere?

    Hi
    You should replace [self.view drawViewHierarchyInRect:self.view.frame afterScreenUpdates:NO]; to [self.view drawViewHierarchyInRect:self.bounds afterScreenUpdates:NO];

  • Site Builder - Time it Takes for Website to be Fully Constructe​d and Running

    Would someone know how long process takes for website to be fully constructed and running once it has been published? Thank you.

    It should be give or take 15 minutes from the time you press Publish to when it's actually online.
    ========
    The first to bring me 1Gbps Fiber for $30/m wins!

  • Firefox crashes when opened through the option "Safe Run for Websites" through Kaspersky Internet Security 2012

    Safe Run for Websites in Kaspersky Internet Security 2012 is for browsing websites without the attack of phising sites from storing the date or key strokes. While accessing my online bank account through the said safe run, firefox crashes with an alert msg. by Kaspersky saying "could not initialize the application's security component. The most likely cause is problems with files in your application's profile directory. Please check that this directory has no read/write restrictions and your hard disk is not full or close to full. It is recommended that you exit the application and fix the problem. If you continue to use this session, you might see incorrect application behaviour when accessing security features." How to solve this technical problem? If anybody has a solution, kindly send the same to my email ID : [email protected]

    Kaspersky 2012 not compatible with Firefox 9 yet, can you also notify Kaspersky Techsupport and Kaspersky forum about this issue?
    * http://forum.kaspersky.com/index.php?showforum=4
    * http://support.kaspersky.com/helpdesk.html
    if the problem is Kaspersky related, they will fix it through patch via database update

  • Torch - Browser Questions: Formatting and Passwords for websites

    I had a Curve 8300 for 3 years and just got the Torch a week ago.
    1.  I often have trouble getting websites to format to the screen.  Usually (but not always), if I click the trackpad while the magnifying glass is on the website, it will work.  Again, usually - but not always.  Is there a way that I can consistently get websites to format to the screen?  What is the easiest way to do that?
    2.  I have a message board that I frequently read and post on.  I can't seem to do it from my Torch.  Here is what happens:
    -Site asks me for my login.
    -I login.
    -I type in my post and push the post button.
    -It again asks me for my login.
    -It won't even accept my whole post, just a word or two of it.
    NEVER had this problem on my Curve.  Can't figure out the solution.  Is there a way to stay logged in to the site permanently?  I've never seen any prompts for it.  And anyone know why my posts aren't taking?
    Thanks VERY MUCH for any help anyone can give.

    Make sure that you do not run Firefox in (permanent) Private Browsing mode (Never Remember History).
    *https://support.mozilla.org/kb/Private+Browsing
    *Tools > Options > Privacy > Firefox will: "Use custom settings for history"
    *Deselect: [ ] "Always use private browsing mode"
    Start Firefox in <u>[[Safe Mode|Safe Mode]]</u> to check if one of the extensions (Firefox/Firefox/Tools > Add-ons > Extensions) or if hardware acceleration is causing the problem (switch to the DEFAULT theme: Firefox/Firefox/Tools > Add-ons > Appearance).
    *Do NOT click the Reset button on the Safe Mode start window.
    *https://support.mozilla.org/kb/Safe+Mode
    *https://support.mozilla.org/kb/Troubleshooting+extensions+and+themes

  • How to make adobe flash player content on websites run on safari browser of my ipad?

    How to make adobe flash player content on websites run on safari browser of my ipad?do I have to install adobe flash player on my ipad ?

    The flash add-on is not available for Safari on iOS. Never has been and in fact Adobe has ceased support for flash for mobile devices in general. Your options, depending on the specific sites:
    See if the site or sites in question have their own apps availabel in teh app store
    Look into some browsers such as Puffin adn iSwifter (there are others, I beleive). These browsers use a third server site to translate the flsh content into a form that the iPAd can use and restreams them to you. They may not work with all content.
    Use a computer capable of running flash.
    Seek a source of the conent that is designed for non flash use.

  • Compression tecniques for website use urgently needed

    Hi there
    I am creating short movies (about 2-5 mins) in Imovie HD and i want them to be downloadable from my website as a file (not streamed etc). I want the picture quality to be very good but the sound can be mono as its not as important. I need to keep file sizes to about 20mb or less. I am told that 320 x 240 is the size to go for websites - is that true?
    My problem is that both PC and Mac users will be wanting to download the movies so compatability is very important. What file type should i go for (mpg, mov, avi, wmv) and what compression should i choose for the best cross platform compatability?
    If anyone can help, i would be so grateful. If anyone has any good settings that they have tried and tested - that would be fantastic.
    Many, many thanks
    Daniel

    I would create .mov ..that's to say QuickTime.. files: every Mac user has QuickTime on their machine, and Windows users often already have it, or can be guided to simply download it.
    I've tried an assortment of compression codecs, and have found that a 'hardwired' codec-in-a-chip, rather than using software to compress, gives the fastest and sharpest results. So I run my mini-movies through an Archos recorder/player (..predecessor of the video iPod..) which encodes all incoming video in DivX format.
    This plays great in QuickTime, except for the sound, which is - by default - hidden. So I run the resultant small video file through a little free program called 'DivX Validator', which resets the sound to the proper QuickTime format.
    I then post that 'validated' compressed file on the web (..on my Homepage..) and it's playable by all versions of QuickTime, both old and new. [NOTE that only the latest QuickTime 7 seems to be able to play back videos encoded through the recent QT 7 H.264 hi-quality codec ..but DivX looks just as good, and can be played in any QT versions.]
    Here's what a DivX-encoded movie looks like.. [This is a still slideshow burned to a DVD ..when it starts.. not moving video, and DivX really does justice to the hi-quality stills. And as DivX produced a small file size, it can be downloaded quickly!]
    Other people will probably have other recommendations..

  • Alternative to Adobe Flash Player for Macs running Yosemite

    Is there a reliable and secure alternative to Adobe Flash Player for Macs running Yosemite?  I keep getting websites telling me that I can see a video because my Flash Player needs to be updated.  But I haven't wanted to install it as I've heard negative things about it and Macs.  Is there an alternative to Flash Player?  And if so, what is it and where do I find it?

    Being that Flash is very insecure, I've completely removed it from my MacBook Pro. The best alternative is to uninstall Flash from your system and download Google Chrome as it has Flash build into it and you're not vulnerable unless you're browsing in Chrome. If Safari is your main browser, as mine is, then you need to open Safari Preferences, go to Advanced and click the checkbox for 'Show Develop menu in menu bar'. Once you've done this, the Develop menu bar menu shows up and you can click it and choose 'Open Page With' and choose Chrome. It is a bit cumbersome, but it removes the vulnerability when browsing in Safari as many sites are now using HTML5. Hope this help.

  • [SOLVED] dbus error when taking a screenshot

    I can't take screenshots with the Gnome3 screenshot program. When I try to save a screenshot, I get this error message:
    Error while saving screenshot.
    Impossible to save the screenshot to file:///home/some/directory.
    Error was GDBus.Error:org.freedesktop.DBus.Error.Spawn.ChildExited: Process /usr/bin/nautilus exited with status 1.
    Please choose another location and retry.
    I found a thread with a similar problem (dbus error when taking a screenshot; the error message is different though) providing a solution, but I can't try that solution because I don't have a /etc/X11/xorg.conf.d/20-intel.conf file.
    How can I fix this?
    Last edited by cryptkeeper (2012-03-05 08:12:36)

    Damn, I found the solution (or better: source) of the problem... The error messages states that /usr/bin/nautilus exits with error something-something, and after thinking about that for some seconds it came to my mind that I replaced /usr/bin/nautilus with a softlink (ln -s) to /usr/bin/thunar because I didn't find a better way to totally replace Nautilus with Thunar...
    Thanks for trying to help anyway!

  • I am running my first time machine backup onto a Western Digital MyBook Live.  It is taking forever.  Is there antivirus software running in the background or any other settings I need to change to speed it up?  Also I am on a wireless network.

    I am running my first time machine backup onto a Western Digital MyBook Live.  It is taking forever.  Is there antivirus software running in the background or any other settings I need to change to speed it up?  Also I am on a wireless network.

    The initial Time Machine backup can certainly take a long time over wireless. Days, possibly. It's impossible for anyone here to be able to predict how long it will take, and wireless environmental conditions can change at any time.
    Is there antivirus software running in the background
    Only you can determine that. If you're using third party AV software, anything is possible.
    NAS devices may not be compatible with Time Machine, regardless of what their manufacturers may claim. Even after the Time Machine backup completes, your backup may be unreliable. You may not discover that until you need to rely upon the backup for some reason, and corruption can occur months or years from now.
    Time Machine supports the following backup configurations:
    A locally mounted volume
    Time Capsule
    A volume resident on a USB hard disk connected directly to a Time Capsule or current production AirPort Extreme Base Station.
    That's it. Any configuration other than the above list places you in an experimental category. If your backup fails, you're on your own.

  • HT201361 After taking the screenshot clicking on my trackpad just acting like right mouse click or 2 finger click. Could you help!

    After taking a screenshot command + Shift + 4, clicking on my trackpad is like right mouse click or 2 finger click. Please help!

    Maybe your trackpad battery is running low? If not I would suggest just restarting your Mac. Post again if those things don't fix your problem and some more involved problem-solving can be attempted.

  • I am a new mac user and I switch to mac due to the graphics that it brings. I do website in pc and I heard iweb is the best.NOW i heard that iweb will be discontinue. so what is the best application there for website using MAC OSX lion?

    I am a new mac user and I switch to mac due to the graphics that it brings. I do website in pc and I heard iweb is the best.NOW i heard that iweb will be discontinue. so what is the best application there for website using MAC OSX lion?

    It is now confirmed  that iWeb, and iDVD, has been discontinued by Apple. This is evidenced by the fact that new Macs are shipping with iLife 11 installed but without iWeb and iDVD.
    On June 30, 2012 MobileMe will be shutdown. However, iWeb will still continue to work but without the following:
    Features No Longer Available Once MobileMe is Discontinued:
    ◼ Password protection
    ◼ Blog and photo comments
    ◼ Blog search
    ◼ Hit counter
    ◼ MobileMe Gallery
    All of these features can be replaced with 3rd party options.
    I found that if I published my site to a folder on my hard drive and then uploaded with a 3rd party FTP client subscriptions to slideshows and the RSS feed were broken.  If I published directly from iWeb to the FPT server those two features continued to work correctly.
    There's another problem and that's with iWeb's popup slideshows.  Once the MMe servers are no longer online the popup slideshow buttons will not display their images.
    Click to view full size
    However, Roddy McKay and I have figured out a way to modify existing sites with those slideshows and iWeb itself so that those images will display as expected once MobileMe servers are gone.  How to is described in this tutorial: #26 - How to Modify iWeb So Popup Slideshows Will Work After MobileMe is Discontinued.
    It now appears that the iLife suite of applications offered on disc is now a discontinued product and the remaining supported iApps will only be available thru the App Store from now on. However, the iLife 11 boxed version that is still available at the online Apple Store (Store button at the top of the page) and those still on the shelves of retailers will include iWeb and iDVD. Those two apps were listed in small, gray text on the iLife 11 box that I bought.
    Personally, if I didn't already have a copy I would purchase one to have it for reinstallation purposes if ever needed.
    This might be of some interest to you at this time: Life After MobileMe.
    OT

  • Generic extractor FM : taking 5-6 hours time for 3 months to BW urgent:

    Dear experts,
    I have designed a FM for generic extraction , which is taking 5-6 hoours time for 3 months data i.e 24 lakhs records to BW up to PSA .
    i have given the coding below plz provide any modifications to improve the performance.....
    FUNCTION zhr_att_analysis.
    ""Local Interface:
    *"  IMPORTING
    *"     VALUE(I_REQUNR) TYPE  SRSC_S_IF_SIMPLE-REQUNR
    *"     VALUE(I_DSOURCE) TYPE  SRSC_S_IF_SIMPLE-DSOURCE OPTIONAL
    *"     VALUE(I_MAXSIZE) TYPE  SRSC_S_IF_SIMPLE-MAXSIZE OPTIONAL
    *"     VALUE(I_INITFLAG) TYPE  SRSC_S_IF_SIMPLE-INITFLAG OPTIONAL
    *"     VALUE(I_REMOTE_CALL) TYPE  SBIWA_FLAG DEFAULT SBIWA_C_FLAG_OFF
    *"  TABLES
    *"      I_T_SELECT TYPE  SBIWA_T_SELECT OPTIONAL
    *"      I_T_FIELDS TYPE  SBIWA_T_FIELDS OPTIONAL
    *"      E_T_DATA STRUCTURE  ZHR_ATT_MAIN OPTIONAL
    *"  EXCEPTIONS
    *"      NO_MORE_DATA
    *"      ERROR_PASSED_TO_MESS_HANDLER
    Auxiliary Selection criteria structure
      DATA: l_s_select TYPE sbiwa_s_select.
    Maximum number of lines for DB table
      STATICS: l_maxsize TYPE sbiwa_s_interface-maxsize.
    Select ranges
      RANGES: l_r_pernr FOR pa9004-pernr,
              l_r_bukrs FOR pa0001-bukrs,
              l_r_persg FOR pa0001-persg,
              l_r_begda FOR pa9004-begda,
              l_r_persk FOR pa0001-persk.
    Maximum number of lines for DB table
      STATICS: s_s_if TYPE srsc_s_if_simple,
    counter
              s_counter_datapakid LIKE sy-tabix,
    cursor
              s_cursor TYPE cursor.
    *"Declaration of store data
    TYPES : BEGIN OF ty_9004,
             pernr TYPE persno,
             endda TYPE endda,
             begda TYPE begda,
             zrs TYPE zrs,
             zstorecode TYPE zstorecode,
            END OF ty_9004.
    *"Declaration of employee data
      TYPES : BEGIN OF ty_0001,
              pernr TYPE pernr_d,
              endda TYPE endda,
              begda TYPE begda,
             AEDTM TYPE AEDAT,
              bukrs TYPE bukrs,
              persg TYPE persg,
              persk TYPE persk,
              END OF ty_0001.
    *"Declaration of expected mandays
      TYPES : BEGIN OF ty_0000,
              pernr TYPE persno,
              endda TYPE endda,
              begda TYPE begda,
              aedtm TYPE aedat,
              stat2 TYPE stat2,
              massn TYPE massn,
              END OF ty_0000.
    *"Declaration of man days swiped
      TYPES : BEGIN OF ty_teven,
              pernr TYPE pernr_d,
              ldate TYPE ldate,
              satza TYPE retyp,
              aedtm TYPE aedat,
              counter_swiped TYPE i,
              END OF ty_teven.
    *"Declaration of Man days regularized
      TYPES : BEGIN OF ty_2002,
              pernr TYPE pernr_d,
              subty TYPE subty,
              endda TYPE endda,
              begda TYPE begda,
              aedtm TYPE aedat,
              END OF ty_2002.
    *"Declaration of Man days lostdue to leave
      TYPES : BEGIN OF ty_2001,
              pernr TYPE pernr_d,
              subty TYPE subty,
              endda TYPE endda,
              begda TYPE begda,
              aedtm TYPE aedat,
              END OF ty_2001.
    *****Declaration of weekly off
      TYPES : BEGIN OF ty_2003,
              pernr TYPE pernr_d,
              subty TYPE subty,
              endda TYPE endda,
              begda TYPE begda,
              aedtm TYPE aedat,
              tprog TYPE tprog,
              END OF ty_2003.
    Auxiliary Selection criteria structure
      DATA :
            it_0001 TYPE TABLE OF ty_0001,
            wa_0001 TYPE ty_0001,
            it_0000 TYPE TABLE OF ty_0000,
            wa_0000 TYPE ty_0000,
            it_teven TYPE TABLE OF ty_teven,
            wa_teven TYPE ty_teven,
            it_2002 TYPE TABLE OF ty_2002 ,
            wa_2002 TYPE ty_2002,
            it_2001 TYPE TABLE OF ty_2001,
            wa_2001 TYPE ty_2001,
            it_2003 TYPE TABLE OF ty_2003,
            wa_2003 TYPE ty_2003,
            wa_target TYPE zhr_att_main.
      DATA : date  TYPE dats,
      doj TYPE dats,
      dol TYPE dats,
      date1 TYPE dats,
      date2 TYPE dats,
             counter(9)  TYPE n.
    Initialization mode (first call by SAPI) or data transfer mode
    (following calls) ?
      IF i_initflag = sbiwa_c_flag_on.
    Initialization: check input parameters
                    buffer input parameters
                    prepare data selection
    Check DataSource validity
        CASE i_dsource.
          WHEN 'ZHR_ATT_ANALYSIS'.
          WHEN OTHERS.
            IF 1 = 2. MESSAGE e009(r3). ENDIF.
            log_write 'E'                  "message type
                      'R3'                 "message class
                      '009'                "message number
                      i_dsource            "message variable 1
                      ' '.                 "message variable 2
            RAISE error_passed_to_mess_handler.
        ENDCASE.
        APPEND LINES OF i_t_select TO s_s_if-t_select.
    Fill parameter buffer for data extraction calls
        s_s_if-requnr    = i_requnr.
        s_s_if-dsource   = i_dsource.
        s_s_if-maxsize   = i_maxsize.
    Fill field list table for an optimized select statement
    (in case that there is no 1:1 relation between InfoSource fields
    and database table fields this may be far from beeing trivial)
        APPEND LINES OF i_t_fields TO s_s_if-t_fields.
      ELSE.                 "Initialization mode or data extraction ?
    Data transfer: First Call      OPEN CURSOR + FETCH
                   Following Calls FETCH only
    First data package -> OPEN CURSOR
        IF s_counter_datapakid = 0.
          LOOP AT s_s_if-t_select INTO l_s_select WHERE fieldnm = 'PERNR'.
            MOVE-CORRESPONDING l_s_select TO l_r_pernr.
            APPEND l_r_pernr.
          ENDLOOP.
          LOOP AT s_s_if-t_select INTO l_s_select WHERE fieldnm = 'BUKRS'.
            MOVE-CORRESPONDING l_s_select TO l_r_bukrs.
            APPEND l_r_bukrs.
          ENDLOOP.
          LOOP AT s_s_if-t_select INTO l_s_select WHERE fieldnm = 'PERSG'.
            MOVE-CORRESPONDING l_s_select TO l_r_persg.
            APPEND l_r_persg.
          ENDLOOP.
          LOOP AT s_s_if-t_select INTO l_s_select WHERE fieldnm = 'BEGDA'.
            MOVE-CORRESPONDING l_s_select TO l_r_begda.
            APPEND l_r_begda.
          ENDLOOP.
          LOOP AT s_s_if-t_select INTO l_s_select WHERE fieldnm = 'PERSK'.
            MOVE-CORRESPONDING l_s_select TO l_r_persk.
            APPEND l_r_persk.
          ENDLOOP.
          OPEN CURSOR WITH HOLD s_cursor FOR
    populate only store code employess does not have empty store codes
            SELECT apernr bpernr bendda bbegda bbukrs bpersg b~persk FROM pa9004 AS a INNER JOIN pa0001 AS b
                    ON  apernr = bpernr
                     WHERE a~pernr IN l_r_pernr AND
                          a~zstorecode <> ''    AND
                          bukrs IN l_r_bukrs  AND
                          persg IN l_r_persg AND
                          persk IN l_r_persk.
        ENDIF.
    Fetch records into interface table.
      named E_T_'Name of extract structure'.
        FETCH NEXT CURSOR s_cursor
                   APPENDING CORRESPONDING FIELDS
                   OF TABLE  it_0001
                   PACKAGE SIZE s_s_if-maxsize.
        IF sy-subrc <> 0.
          CLOSE CURSOR s_cursor.
          RAISE no_more_data.
        ELSE.
         break-point.
          IF l_r_begda-high = '00000000' AND l_r_begda-low = '00000000'.
            date1 = sy-datum - 1.
            date2 = sy-datum - 1.
          ELSE.
            date1 = l_r_begda-low .
            date2 = l_r_begda-high.
          ENDIF.
          SORT it_0001 BY pernr persg begda endda bukrs.
          DELETE it_0001 WHERE persg NE 'T' AND
                               persg NE 'K' AND
                               persg NE 'P' AND
                               persg NE 'W'.
          DELETE ADJACENT DUPLICATES FROM it_0001 COMPARING pernr begda endda bukrs.
    populate all the employees that are active in pa9004.
          IF NOT it_0001[] IS INITIAL.
            SELECT pernr endda begda aedtm massn FROM pa0000
                   INTO CORRESPONDING FIELDS OF TABLE it_0000
                   FOR ALL ENTRIES IN it_0001
                   WHERE pernr = it_0001-pernr
                     AND ( massn = 'A1' OR massn = '00' OR massn = 'A6' OR massn = 'A3' ).
            SORT it_0000 BY pernr begda DESCENDING.
          ENDIF.
    populate SWIPED MAN DAYS data
          IF NOT it_0001[] IS INITIAL.
            SELECT pernr ldate satza aedtm FROM teven
               INTO CORRESPONDING FIELDS OF  TABLE it_teven
               FOR ALL ENTRIES IN it_0001
               WHERE pernr = it_0001-pernr AND
                                 satza = 'P01'
                                 AND ldate IN l_r_begda.
            SORT it_teven BY pernr ldate.
          ENDIF.
    **populate REGULARIZATION DAYS data
          IF NOT it_0001[] IS INITIAL.
            SELECT pernr subty endda begda aedtm FROM pa2002
              INTO CORRESPONDING FIELDS OF  TABLE it_2002
               FOR ALL ENTRIES IN it_0001
               WHERE pernr = it_0001-pernr
                AND  begda >= date1
                AND endda <= date2 .
            SORT it_2002 BY pernr begda endda.
          ENDIF.
    **populate LEAVE DAYS data
          IF NOT it_0001[] IS INITIAL.
            SELECT pernr subty endda begda aedtm FROM pa2001
              INTO CORRESPONDING FIELDS OF   TABLE it_2001
               FOR ALL ENTRIES IN it_0001
               WHERE pernr = it_0001-pernr
                AND  begda >= date1
                AND endda <= date2  .
            SORT it_2001 BY pernr begda endda .
          ENDIF.
    **populate WEEKLY OFF data
          IF NOT it_0001[] IS INITIAL.
            SELECT pernr subty endda begda aedtm tprog FROM pa2003
              INTO CORRESPONDING FIELDS OF  TABLE it_2003
                 FOR ALL ENTRIES IN it_0001
                 WHERE pernr = it_0001-pernr AND
                              tprog = 'OFF'
                               AND  begda >= date1
                               AND endda <= date2  .
            SORT it_2003 BY pernr begda endda.
          ENDIF.
          date = sy-datum.
    ********added changes on 06.04.2008**************action type & date dependent extaction****
    loop over it_0001 table
         BREAK-POINT.
          LOOP AT it_0001 INTO wa_0001.
           if sy-tabix = 1.
            counter = 0.
    for expected mandays
            LOOP AT it_0000 INTO wa_0000 WHERE pernr = wa_0001-pernr .
              IF wa_0000-massn = 'A1' OR wa_0000-massn = '00' OR wa_0000-massn = 'A3'.
                doj = wa_0000-begda.
               if wa_0000-endda = '99991231'.
              date2  = sy-datum.
               else.
                dol = date2.
               endif.
              ELSEIF wa_0000-massn = 'A6'.
                dol = wa_0000-begda.
              ENDIF.
            ENDLOOP.
            IF  date1 <= wa_0001-begda AND date2 <= wa_0001-endda AND date2 >= wa_0001-begda AND date1 <= wa_0001-endda.
              counter = date2 - wa_0001-begda .
              counter = counter + 1.
              date = wa_0001-begda - 1.
            ELSEIF date1 >= wa_0001-begda  AND date2 >= wa_0001-endda AND date2 >= wa_0001-begda AND date1 <= wa_0001-endda.
              counter =  wa_0001-endda - date1.
              counter = counter + 1.
              date = date1 - 1.
            ELSEIF date1 >= wa_0001-begda AND date2 <= wa_0001-endda AND  date2 >= wa_0001-begda AND date1 <= wa_0001-endda.
              counter = date2  - date1.
              counter = counter + 1.
              date = date1 - 1.
            ELSEIF  date1 <= wa_0001-begda AND  date2 >= wa_0001-endda AND date2 >= wa_0001-begda AND date1 <= wa_0001-endda.
              counter = wa_0001-endda - wa_0001-begda.
              counter = counter + 1.
              date =  wa_0001-begda - 1.
            ELSE.
              CONTINUE.
            ENDIF.
    ********completed changes on 06.04.2008**************action type & date dependent extaction**
    split records from date of joining to till date
            DO counter  TIMES.
              CLEAR : wa_teven , wa_target.
              date = date + 1.
              wa_target-date1 = date.
              wa_target-pernr = wa_0001-pernr.
              wa_target-bukrs = wa_0001-bukrs.
              wa_target-persg = wa_0001-persg.
              wa_target-persk = wa_0001-persk.
    for expected mandays count
              IF wa_target-date1 >= doj AND wa_target-date1 <= dol.
                wa_target-expectedmandays = 1.
                wa_target-aedtm = wa_0000-aedtm.
    for swiped mandays
                READ TABLE it_teven INTO wa_teven WITH KEY pernr = wa_target-pernr
                                                           ldate = wa_target-date1 BINARY SEARCH.
                IF sy-subrc = 0.
                  wa_target-swiped_days = 1.
                  wa_target-aedtm = wa_teven-aedtm.
                ENDIF.
    for regularized days
                LOOP AT it_2002 INTO wa_2002 WHERE pernr = wa_target-pernr
                   AND  ( endda GE wa_target-date1 AND begda LE wa_target-date1 ).
                  wa_target-reg_days  = 1.
                  wa_target-subty2 = wa_2002-subty.
                  wa_target-aedtm = wa_2002-aedtm.
                ENDLOOP.
    for leave days
                LOOP AT it_2001 INTO wa_2001 WHERE pernr = wa_target-pernr
                   AND  ( endda GE wa_target-date1 AND begda LE wa_target-date1 ).
                  wa_target-leave_days  = 1.
                  wa_target-subty1 = wa_2001-subty.
                  wa_target-aedtm = wa_2001-aedtm.
                ENDLOOP.
    for weekly off days
                LOOP AT it_2003 INTO wa_2003 WHERE pernr = wa_target-pernr
                   AND  ( endda GE wa_target-date1 AND begda LE wa_target-date1 ).
                  wa_target-off_days   = 1.
                  wa_target-aedtm = wa_2003-aedtm.
                ENDLOOP.
    append work area to e_t_data
                APPEND wa_target TO  e_t_data.
              ENDIF.
            ENDDO.
          ENDLOOP.
    clear internal tables
          CLEAR :  it_0000 , it_0001 , it_2001 , it_2002 , it_2003 , it_teven.
        ENDIF.
        s_counter_datapakid = s_counter_datapakid + 1.
      ENDIF.   "Initialization mode or data extraction ?
    ENDFUNCTION.

    Hi Guys
    I can have both your cases looked into for you.
    Please send me an email using the contact us form in my profile. The address for this form in the section 'about me'.
    Thanks
    Stuart
    BTCare Community Mod
    If we have asked you to email us with your details, please make sure you are logged in to the forum, otherwise you will not be able to see our ‘Contact Us’ link within our profiles.
    We are sorry that we are unable to deal with service/account queries via the private message(PM) function so please don't PM your account info, we need to deal with this via our email account :-)

  • Open Purchase Orders not considered as requirement for MRP Run

    Hi ,
    We are facing a issue of Open Purchase orders not appeared in Stock requirements list and also it is not considered as requirement for MRP Run against reservation.
    As aresult for a reservation demand of 10 units we are ending with Open POs 10 units and a additional planned order 10 units.
    Material Type : ERSA
    MRP Type : PD (or VB)
    Lot size : EX (  HB if MRP Type is VB)
    Could you please throw some light to correct our settings to MRP to consider Open POs?
    Saravanan

    Can you check to see if there is a re-order point set up for this materia? That could be causing the problem too.

Maybe you are looking for

  • How can i print on the both sides of the paper on printer 5520

    how can i print on the both sides of the paper on printer 5520 when printing too many papers?

  • Aurora update wont install

    Aurora is trying to install update 30.0a2. It downloads a 3.4 mB file but the install fails. It then downloads the 36mb file which still wont install. If I try and download from scratch I run the file firefox-30.0a2.en_US.win32.installer-stub.exe. Wh

  • Oracle User in Solaris

    Hi, I created oracle user in solaris . If I switch from root to oracle it's not asking the oracle user password and direcly going to $ prompt when I type the command who in $ promot its showing root , Why? $ who am i root ->here its should be show th

  • How stored procedure get executed when called from java

    When we create a stored procedure or function in oracle, it is compiled and stored there. From java when we call them no compilation is performed its a simple call. When a function or stored procedure is invoked from multiple instance of java objects

  • Viewing lan sites hosted on macbook pro (apache) via wifi router

    Hi, thanks for stopping by. Hope you can help. I've my macbook pro (Lion) set up to serve several websites locally. In the httpd-vhosts.config I've got the addresses set up: <VirtualHost *:80> etc., ServerAlias site.localhostname.lan </VirtualHost> I