New HDD Data Doubler Error formating

Brought new HDD and replaced CD ROM with it using data doubler.
When restarted, pop up message shown for INITIALISE disk or ignore. Upon selecting initialise it doesn't do anything.
Just simply opens Disk Utility. When tried to make partitions, it gives WIPING ERROR. when tried to format same error.
when tried formating from windows 8.1, formating failed. How can i use this HDD. It shows on both OS but none of them are using it.

It's a feature of modern 2.5" harddisks , the disk parks the head when its been inactive for a while, to avoid damage , uses less power , and reduces the heat etc gives the harddisk a better looking spec sheet , its meant to park its head after being inactive for a long time around an hour with proper management from the bios/os of the head parking feature, because there is nothing to manage this feature in hp's bios or os the disk parks the head about every minute for no reason then after 1 second the head goes back on the disk thats 1 load/unload cycle , it also effects performance as the head has to find its place back on the disk , load times will decrease by alot , videos will stutter the first few secs, i have the same problem but not as bad after 130 hours i had a count of around 1,250 load/unloads , different brands of disk have different idle timers plus i use utorrent which stops the harddisk from idling so much, there are a couple of solutions, you can find a tool to update/mod the harddisk firmware to increase the idle timer ( i decided against this as you can permently brake the harddrive and void the warrenty) , contact hp and request a bios update with proper management or the harddisk head parking feature i.e tell the harddisk it is idle after an hour, the temperary solutions are download hd tune and run it all the time this stops the harddisk from parking its head as it doesn't let it go idle , or the solution i am using at the moment download a programme called HDD scan , everytime you turn on/off  you have to run the prog go to tasks/features/ide features set the advance power management from its default value to 254 then press set, no more unnessary load/unloads, downside is the disk runs a couple of 0c hotter mine still never goes above 40c even under full load thanks to a active cooling pad, also its less well protected against shock.

Similar Messages

  • Data Doubler - Format for both OSX and Windows 7 to read/write?

    Hello! I have a Mid-2012 MacBook Pro 13" and I've ordered the OWC Data Doubler with a 1.5TB HDD to put into the optical bay. I have a couple of questions.
    1. What format should I use for the HDD to allow both my OSX and Windows 7 sides read and write to it? I have a Bootcamp partition, but if it's possible I'd like for both OSX and W7 to be able to read and write to this drive. That way, when I'm in OSX I can view iTunes and media, but if I'm in W7 I can still have the same access. That way, I don't have to worry about "Oh, I downloaded this on the windows side ... I have to figure out how to get it over to the mac side" (or vice versa). Essentially allowing the 1.5TB HDD to be a "go between" for the two.
    2. This is a minor question, but will the eject button do something to the HDD if it gets pressed when the optical drive is out and the HDD/Data Doubler is in? I don't plan on pressing it, but I was wondering if I need to dig into terminal (or somewhere else) to "disable" the button or maybe just reassign it so that instead of ejecting it does some other function?
    I have heard of "MacDrives" for Windows, but I haven't used it. If this is a better option (to put the HDD into Mac OS Extended Journaled and use an application to allow W7 to read/write) that's fine.
    I am putting in the 1.5TB HDD. The end goal, if possible, is to allow the Windows 7 side to read/write to it. As long as it's not a "hacked together" method, I do not mind what way it's done.
    Any thoughts? I appreciate it!

    Use Winclone for the Windows partition and CCC for the OSX partition.

  • Data doubler, where to put the SSD

    Hi,
    I'm planning to buy a Data Doubler for my Macbook, is which bay should I put the SSD?
    I have heard that it is best to leave the HDD in its original place, because the vibration could damage the computer in the data doubler, but I have also heard that the SSD in the data doubler (where the OS will be, of course) caused some problem when waking the computer up since the Mac Os does'nt check this SATA port.
    So..
    A) HDD->Orignal bay, SSD->data doubler
    B)SSD->original bay, HDD->data doubler
    What do you think?
    Thank you

    genevievefromlaval wrote:
    Thanks for your reply. The thing is I'm worried about vibrations from the HDD since the optical bay isn't made to handle them.
    In your op you said the reason you were worried about the vibrations was that they could damage the MBP. Let me assure you, every optical drive I've ever had makes far more vibration than any HD I've ever had . . . .

  • Transferring data from one HDD to a new HDD using disk utility?

    I do not have a time machine backup of my HDD.  I was wondering if it is posssible to use disk utility to restore data from the old HDD to the new HDD.  Will I need the system disks to partition the new HDD first or is this even possible.  If it is possible, will everything transfer using the Restore in disk utility?

    How to replace or upgrade a drive in a laptop
    Step One: Repair the Hard Drive and Permissions
    Boot from your OS X Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Installer menu (Utilities menu for Tiger, Leopard or Snow Leopard.) After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list.  In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive.  If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the installer.
    If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.
    Step Two: Remove the old drive and install the new drive.  Place the old drive in an external USB enclosure.  You can buy one at OWC who is also a good vendor for drives.
    Step Three: Boot from the external drive.  Restart the computer and after the chime press and hold down the OPTION key until the boot manager appears.  Select the icon for the external drive then click on the downward pointing arrow button.
    Step Four: New Hard Drive Preparation
      1. Open Disk Utility in your Utilities folder.
      2. After DU loads select your new hard drive (this is the entry with the
          mfgr.'s ID and size) from the left side list. Note the SMART status of
          the drive in DU's status area.  If it does not say "Verified" then the drive
          is failing or has failed and will need replacing.  Otherwise, click on the
          Partition tab in the DU main window.
      3. Under the Volume Scheme heading set the number of partitions from
          the drop down menu to one. Set the format type to Mac OS Extended
          (Journaled.) Click on the Options button, set the partition scheme to
          GUID  then click on the OK button. Click on the Partition button and
          wait until the process has completed.
      4. Select the volume you just created (this is the sub-entry under the
          drive entry) from the left side list. Click on the Erase tab in the DU main
          window.
      5. Set the format type to Mac OS Extended (Journaled.) Click on the
          Options button, check the button for Zero Data and click on OK to
          return to the Erase window.
      6. Click on the Erase button. The format process can take up to several
          hours depending upon the drive size.
    Step Five: Clone the old drive to the new drive
      1. Open Disk Utility from the Utilities folder.
      2. Select the destination volume from the left side list.
      3. Click on the Restore tab in the DU main window.
      4. Check the box labeled Erase destination.
      5. Select the destination volume from the left side list and drag it to the
          Destination entry field.
      6. Select the source volume from the left side list and drag it to the
          Source entry field.
      7. Double-check you got it right, then click on the Restore button.
    Destination means the new internal drive. Source means the old external drive.
    Step Six: Open the Startup Disk preferences and select the new internal volume.  Click on the Restart button.  You should boot from the new drive.  Eject the external drive and disconnect it from the computer.

  • Can't detect boot device after factory format to new HDD

    First off, I have an HP Pavilion G6 that I purchased in December 2012. Yesterday I decided to get a new HDD to upgrade it and start fresh. It's a 1TB SSD+HDD hybrid by Seagate. It installed without a hitch, and I used my HP recovery CDs to do a factory format of the disk.
    It finishes, reboots, but instead of rebooting to the HP Windows 8 setup screens, it goes to what looks like Windows 8 safe mode with a box containing the date, time, and it says something along the lines of "HP diagnostics driver installation" with an OK. Clicking that or not makes it disappear, and there's a command prompt bar at the bottom left hand corner of the screen.
    The screen changes to an HP screen that begins to install drivers. It finishes, and reboots to a black screen that says "no boot device detected, please install OS."
    I ran a check of the drive and it's fine. I swapped my regular drive back in, and it loaded up fine. In fact that's what I'm using right now to type this.
    What could be the problem here? The boot order was never changed in the BIOs. If it were the connector failing I doubt it would load the drive that's always been in the computer. Loading up the newly formatted drive in an external enclosure shows that Windows 8 is indeed on it, but on a 93GB partition even though the drive is 1TB.
    I'm at a total dead end here and no one seems to know what to do!
    This question was solved.
    View Solution.

    Hello @kylemcauliffe15,
    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 have read your post on how your notebook is displaying an error message that your new SSD is not detected as a bootable device after a factory format. 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!

  • Opinion of New HDD Formatting

    Does anyone write zeros to your new HDDs? I typically have always done this with brand new HDDs but just curious if there's any benefit to it anymore?
    Putting a new HDD in today and wondering if I should just do it (I don't mind at all) or just do the basic "erase" and format and Mac OS...

    Indeed there are benefits. First, the drive is received prepped for a different operating system and a different partition mapping scheme. You don't know when sectors may have soft errors even when factory new.
    When the drive is new take the time to do a Zero Data single pass. It's worth the extra time to prevent future problems that can include the failure of the drive to properly boot the computer or be seen as bootable. Zeroing the data is not a "stress test." It is a verification of the integrity of the drive and will repair or map out sector errors and remove any data on the platters that may prove a problem. It's not just a security precaution.

  • New HDD formatted externally but reverts when installed in MacBook Pro

    Hello! I apologize if this is really long. I'm hoping someone can help me out!
    My MacBook Pro recently crashed. I woke it from sleep one evening and was greeted with a flashing folder & question mark. I ended up using this as an excuse to upgrade  from the original 500gb HDD and purchased a new 1TB Seagate HDD (Model : STBD1000100 ) I installed the new HDD and booted from the Internet Recovery system. From there I entered Disc Utility and tried to format the HDD. No luck. When I would try to partition it how I was supposed to, it gives me an error saying it cannot create a partition or even erase the drive. After searching this site, I found a tutorial on how to do it external. I put the new HDD into a case and plugged it in via USB. From here I was able to format the HDD and even install OSX Lion (this is what my Mac came with.). After formatting and installing the operating system, I reinstalled the HDD into my Mac. I plugged in the external HDD I have been using since the crash & opened up start up disk. When the options came up, the new HDD wasn't there! I went into Disk Utility again to make sure it was at least recognizing the HDD. DU showed the hard drive but when I clicked on it, it said the drive was unformatted and the partition I had made previously was now renamed and grayed out. I can't modify it in anyway.
    Am I doing something wrong? Can someone give me the steps on how to properly do this if I am doing it wrong? Or, could it be my SATA cable?
    Thanks for reading!
    Macbook Pro-> Mid 2012
    Error Message Given in Disk Utility -> "Wiping volume data to prevent future accidental probing failed."

    If you take the new 1 TB HDD out and connect it to the MBP via USB, will it boot the MBP?  If so the internal SATA cable is in all probability the offender.  First try the poor man's approach:
    http://macperformanceguide.com/blog/2011/20110415_1_Tinfoilfix--howto.html
    If no success, then a new SATA cable will probably be required,  An Apple store genius bar appointment will confirm this.
    Ciao.

  • MBP disk0s2 IO error, but some time boot fine.. new HDD doesn't solve this problem

    Hello, Apple and all.
    Yesterday I get hung a computer after sleep (first time in half a year after replacing the Logic Board).
    After turning off and on again, notebook can't determine internal HDD, but this disk if use USB-SATA adaptor work perfectly.
    Resetting the SMC / PRAM has not solved the problem.
    Replace HDD, also has not solved the prov
    In the end, I bought a new HDD, the store I installed it and formatted.
    At home, he first worked, then it stopped again determined.
    When the laptop lid is screwed on to the bottom of the bolt is not all, the laptop works... should tighten them all, again there is an error, this time "disk0s2 IO Error"
    What could happen ?

    Could just be the cable. See https://discussions.apple.com/thread/2648100?start=45&tstart=0 .

  • CS5 Design Standard. Will not activate on new HDD following transfer from old HDD. Shows Error 213.10 Have serial number/s etc.

    I recently encountered a problem with a HDD drive. So I had to replace it with a new one. Fortunately I managed to recover the data and applications on the original drive.
    However when I transferred and installed the Adobe CS5 Design Standard suite on the new HDD it will not open any of the Adobe applications.
    It prompts an error 213.10 each time. I can't see where to deactivate or reactivate.. please advise suggested course of action.
    Also, will I be able to successfully access my previous files after the reinstallation/activation?
    Many thanks
    R

    Reinstall properly. Activation cannot work because in the technical sense it simply isn't there. You screwed it. Run teh cleaner tool if necessary and contact support to reset activations.
    Download CS5 products
    Use the CC Cleaner Tool to solve installation problems | CC, CS3-CS6
    Mylenium

  • My hdd is gone and now I have a new one without my old key - how can I get my stored data on my new hdd?

    all data on my old hdd is lost after an crash. so i changed it with a new hdd. but the old sync key is not longer available. I generated a new key so i lost all my old date stored with sync... is there any way to restore the old data from my old hdd sync key...?

    Sorry, no. The SyncKey is used for encryption / decryption during the Sync process, without the Sync Key that was used to encrypt your personal data as it was uploaded to the Sync storage server your data is worthless. Plus, when you generate a new Sync Key for an existing account, all the data that is saved on the server for that account is deleted for your security.
    Do you still have the old HDD? It may work long enough for you to extract your Firefox data, if you put that drive in a USB drive enclosure and access it as an external drive. <br />
    http://support.mozilla.com/en-US/kb/Recovering+important+data+from+an+old+profile

  • Hey yall.. I lost everything from my mac from a data encrypted error and now it won't let me download Lightroom off of the disk again onto my new mac. What should I do?

    Hey yall.. I lost everything from my mac from a data encrypted error and now it won't let me download Lightroom off of the disk again onto my new mac. What should I do?

    Hi Brennacoyle,
    Can you please share the error message that you are getting while trying to download on the new MAC ?
    Cheers,
    Kartikay Sharma

  • Problem: new entered data is saved but I am facing one error message --- no

    This is a module program for gate entry of materials(miro). This is a simple entry form which updates z tables with data entered. I have to send the new record details automatically through mail to the particular vendor email  id from where the material has been purchased.
    Problem: new entered data is saved but I am facing one error message --- no authorization to unpack list with rfc when the program is sending list through mail.
    PROGRAM  ZMMI001_GRN_ENTRY_BARCODE  MESSAGE-ID ZMM .
    *Table Declaration
    TABLES : EKKO , EKPO , LFA1 , MARC ,
             MARD , J_1IMTCHID , EKET , MSEG,
             MKPF , ZMMT001_GRN_GATE,
             ZMMT002_GRN_ITEM.
    TABLES: ADR6.
    *Table Control Declaration
    CONTROLS : TC1 TYPE TABLEVIEW USING SCREEN 1000.
    DATA: COLS LIKE LINE OF TC1-COLS.
    *Internal Table Declaration
    DATA : BEGIN OF IT_TC1 OCCURS 0,
            SEL,
            SNO(2) TYPE C,
            ITEMCODE(18) TYPE C,
            ITEMNAME(40) TYPE C,
            QUANTITY TYPE P DECIMALS 2,
            EXCISE(13) TYPE P DECIMALS 2,
           END OF IT_TC1.
    DATA : IT_TEMP_TC1 LIKE IT_TC1 OCCURS 0  WITH HEADER LINE.
    DATA:   BDCDATA LIKE BDCDATA    OCCURS 0 WITH HEADER LINE.
    DATA : IT_EKPO LIKE EKPO OCCURS 0 WITH HEADER LINE.
    DATA : IT_EKKO LIKE EKKO OCCURS 0 WITH HEADER LINE.
    DATA : IT_EKET LIKE EKET OCCURS 0 WITH HEADER LINE.
    DATA : WK_ZMMT01 LIKE ZMMT001_GRN_GATE.
    DATA : IT_ZMMT01 LIKE ZMMT001_GRN_GATE OCCURS 0 WITH HEADER LINE.
    DATA : IT_ZMMT02 LIKE ZMMT002_GRN_ITEM OCCURS 0 WITH HEADER LINE.
    DATA : BEGIN OF IT_TEMP_EKPO OCCURS 0,
            EBELN LIKE EKPO-EBELN,
            EBELP LIKE EKPO-EBELP,
            MATNR LIKE EKPO-MATNR,
           END OF IT_TEMP_EKPO.
    DATA : BEGIN OF IT_MSEG OCCURS 0,
             MBLNR LIKE MSEG-MBLNR,
             MJAHR LIKE MSEG-MJAHR,
             ZEILE LIKE MSEG-ZEILE,
             BWART LIKE MSEG-BWART,
             MATNR LIKE MSEG-MATNR,
             EBELN LIKE MSEG-EBELN,
             EBELP LIKE MSEG-EBELP,
             BUDAT LIKE MKPF-BUDAT,
             MENGE LIKE MSEG-MENGE,
            END OF IT_MSEG.
    DATA : BEGIN OF IT_TEMP_MSEG OCCURS 0,
            MBLNR LIKE MSEG-MBLNR,
            MJAHR LIKE MSEG-MJAHR,
            ZEILE LIKE MSEG-ZEILE,
            BWART LIKE MSEG-BWART,
            EBELN LIKE MSEG-EBELN,
           END OF IT_TEMP_MSEG.
    DATA : BEGIN OF IT_TEMP_MKPF OCCURS 0,
            MBLNR LIKE MKPF-MBLNR,
            MJAHR LIKE MKPF-MJAHR,
            BUDAT LIKE MKPF-BUDAT,
            BKTXT LIKE MKPF-BKTXT,
           END OF IT_TEMP_MKPF.
    *Data Declaration
    DATA : WK_SNO TYPE I,
           WK_LIFNR LIKE LFA1-LIFNR,
           WK_EBELN(10) TYPE C,
           WK_VBELN(10) TYPE C,
           WK_FKDAT TYPE D,
           WK_NAME LIKE LFA1-NAME1,
           WK_SCHNO(10) TYPE C,
           WK_CHALNO(10) TYPE C,
           WK_CHALDATE(10) TYPE C,
           WK_GRNO(10) TYPE C,
           WK_GRDATE(10) TYPE C,
           WK_VEHICLE(10) TYPE C,
           WK_CARRIER(10) TYPE C,
           WK_FREIGHT(13) TYPE P DECIMALS 2,
           WK_MDOC(3) TYPE C,
           WK_DEPT(7) TYPE C,
           WK_MODE(7) TYPE C,
           WK_BASIC(13) TYPE P DECIMALS 2,
           WK_EXCISE(13) TYPE P DECIMALS 2,
           WK_TAX(13) TYPE P DECIMALS 2,
           WK_APPVAL(13) TYPE P DECIMALS 2,
           WK_CHAL(2) TYPE C,
           WK_FORM38(9) TYPE C,
           WK_COMMENT(30) TYPE C,
           WK_MAKTX(40) TYPE C,
           WK_LINES TYPE I,
           WK_TOTAL LIKE MARD-LABST,
           WK_LGORT LIKE MARD-LGORT,
           WK_EXCISE_IND,
           WK_TOT_EXCISE LIKE EKPO-NETWR,
           WK_DIFF LIKE EKPO-NETWR,
           WK_BSTYP LIKE EKKO-BSTYP,
           WK_BSART LIKE EKKO-BSART,
           WK_DIFF_QTY LIKE EKET-MENGE,
           WK_101_QTY LIKE EKET-MENGE,
           WK_102_QTY LIKE EKET-MENGE,
           WK_122_QTY LIKE EKET-MENGE,
           WK_WERKS LIKE EKPO-WERKS,
           WK_CHAR_SNO TYPE STRING,
           WK_DATE LIKE SY-DATUM,
           WK_TIME LIKE SY-UZEIT.
    DATA : WK_DATE1 LIKE SY-DATUM,
           WK_DATE2 LIKE SY-DATUM,
           WK_FISYEAR TYPE I,
           WK_CHAR_YEAR(20) TYPE C.
    DATA : V_UCOMM TYPE SY-UCOMM,
           V_INDEX(10) TYPE   C,
           V_QUANTITY(8) TYPE C.
    **DECLARATION FOR INPUT HELP*
    TYPES : BEGIN OF VALUES,
             TXZ01 LIKE EKPO-TXZ01,
             MENGE LIKE EKPO-MENGE,
             MATNR LIKE EKPO-MATNR,
            END OF VALUES.
    TYPES : BEGIN OF VALUES1,
             EBELN LIKE EKKO-EBELN,
            END OF VALUES1.
    TYPES : BEGIN OF VALUES2,
             NAME1 LIKE LFA1-NAME1,
             LIFNR LIKE LFA1-LIFNR,
            END OF VALUES2.
    DATA: PROGNAME LIKE SY-REPID,
          DYNNUM   LIKE SY-DYNNR,
          DYNPRO_VALUES TYPE TABLE OF DYNPREAD,
          FIELD_VALUE LIKE LINE OF DYNPRO_VALUES,
          VALUES_TAB TYPE TABLE OF VALUES WITH HEADER LINE,
          VALUES_TAB1 TYPE TABLE OF VALUES1,
          VALUE_EBELN TYPE TABLE OF VALUES1.
         VALUES_TAB2 TYPE TABLE OF VALUES2.
    DATA : VALUES_TAB2 TYPE VALUES2 OCCURS 0 WITH HEADER LINE.
    DATA : RETURN_TAB  LIKE DDSHRETVAL OCCURS 0 WITH HEADER LINE.
    *nidhi
    DATA: BEGIN OF IT_LFA1 OCCURS 0,
    LIFNR LIKE LFA1-LIFNR,
    ADRNR LIKE LFA1-ADRNR,
    END OF IT_LFA1.
    DATA: BEGIN OF IT_ADR6 OCCURS 0,
          ADDRNUMBER TYPE ADR6-ADDRNUMBER,
          SMTP_ADDR  TYPE ADR6-SMTP_ADDR,
                   END OF IT_ADR6.
    *nidhi
    *&      Module  FILL_TABLE_CONTROL  OUTPUT
          text
    MODULE FILL_TABLE_CONTROL OUTPUT.
      READ TABLE IT_TEMP_TC1 INTO IT_TC1 INDEX TC1-CURRENT_LINE.
    ENDMODULE.                 " FILL_TABLE_CONTROL  OUTPUT
    *&      Module  READ_TABLE_CONTROL  INPUT
          text
    MODULE READ_TABLE_CONTROL INPUT.
    *Validation for Item code
      CLEAR : EKPO-MATNR,
              EKPO-WERKS.
    IF sy-uname = 'GATE1020'.
      IF ( SY-UNAME = 'GATE1010' OR  SY-UNAME = 'GATE1020' OR
           SY-UNAME = 'GATE1030' OR  SY-UNAME = 'GATE1040' OR
           SY-UNAME = 'GATE1050' OR  SY-UNAME = 'GATE1060' OR
           SY-UNAME = 'GATE1070' OR  SY-UNAME = 'GATE1080' OR
           SY-UNAME = 'ABAP'  ).
    **SELECT SINGLE bstyp  FROM EKKO INTO WK_BSTYP  WHERE ebeln = wk_ebeln.
    **SELECT SINGLE bsart FROM EKKO INTO WK_BSART WHERE ebeln = wk_ebeln.
        READ TABLE VALUES_TAB WITH KEY MATNR = IT_TC1-ITEMCODE.
    **ELSE.
        SELECT SINGLE MATNR WERKS
                  FROM EKPO CLIENT SPECIFIED
                  INTO (EKPO-MATNR , EKPO-WERKS )
                  WHERE MANDT = SY-MANDT AND
                  EBELN = WK_EBELN AND
                  MATNR EQ IT_TC1-ITEMCODE.
    ENDIF.
        IF SY-SUBRC NE 0 AND NOT IT_TC1-ITEMCODE IS INITIAL.
      CLEAR it_tc1.
          MESSAGE E003 WITH TEXT-002.
        ELSE.
          SELECT SINGLE MAKTX FROM MAKT
                       CLIENT SPECIFIED
                       INTO WK_MAKTX WHERE
                       MANDT = SY-MANDT AND
                       MATNR = IT_TC1-ITEMCODE AND SPRAS = SY-LANGU.
        ENDIF.
      ENDIF.
    **SELECT SINGLE bstyp  FROM EKKO INTO WK_BSTYP  WHERE ebeln = wk_ebeln.
    **SELECT SINGLE bsart FROM EKKO INTO WK_BSART WHERE ebeln = wk_ebeln.
      IF ( SY-UNAME = 'GATE1010' OR  SY-UNAME = 'GATE1020' OR
           SY-UNAME = 'GATE1030' OR  SY-UNAME = 'GATE1040' OR
           SY-UNAME = 'GATE1050' OR  SY-UNAME = 'GATE1060' OR
           SY-UNAME = 'GATE1070' OR  SY-UNAME = 'GATE1080' OR  SY-UNAME =
           'ABAP'  ).
        IF WK_BSART = 'ZLR' .
    Validation for Quantity.
          IF NOT IT_TC1-QUANTITY IS INITIAL.
            READ TABLE VALUES_TAB WITH KEY MATNR = IT_TC1-ITEMCODE.
            IF SY-SUBRC EQ 0 AND IT_TC1-QUANTITY GT VALUES_TAB-MENGE.
              MESSAGE E003 WITH TEXT-013.
            ENDIF.
          ENDIF.
        ENDIF.
      ENDIF.
    *Validation for Max.Stock Level
      CLEAR : MARC-MABST.
      SELECT SINGLE MABST FROM MARC
              CLIENT SPECIFIED
              INTO MARC-MABST
              WHERE MANDT = SY-MANDT AND
              MATNR = IT_TC1-ITEMCODE AND
              WERKS = EKPO-WERKS.
      CLEAR : MARD-LABST ,
              MARD-INSME .
    SELECT SINGLE labst insme FROM mard
              CLIENT SPECIFIED
              INTO (mard-labst , mard-insme )
              WHERE MANDT = SY-MANDT AND
              matnr = it_tc1-itemcode
              AND werks = ekpo-werks.
      SELECT  SUM( LABST ) SUM( INSME ) FROM MARD
               CLIENT SPECIFIED
               INTO (MARD-LABST , MARD-INSME )
               WHERE MANDT = SY-MANDT AND
               MATNR = IT_TC1-ITEMCODE
               AND WERKS = EKPO-WERKS.
      CLEAR : WK_TOTAL.
      WK_TOTAL = MARD-LABST + MARD-INSME + IT_TC1-QUANTITY.
      IF WK_BSART = 'ZLR'.
        IF WK_TOTAL GT MARC-MABST.
          MESSAGE E001 WITH IT_TC1-ITEMCODE.
        ENDIF.
      ENDIF.
    Appending the table control data to Internal table
      READ TABLE IT_TEMP_TC1 INDEX TC1-CURRENT_LINE.
      IT_TC1-SNO = TC1-CURRENT_LINE.
      IF SY-SUBRC EQ 0.
        MODIFY IT_TEMP_TC1 FROM IT_TC1 INDEX TC1-CURRENT_LINE.
      ELSE.
        READ TABLE IT_TEMP_TC1 WITH KEY ITEMCODE = IT_TC1-ITEMCODE.
        IF SY-SUBRC NE 0.
          IT_TC1-ITEMNAME = WK_MAKTX.
          IF IT_TC1-ITEMCODE IS INITIAL.
            CLEAR IT_TC1.
          ELSE.
            APPEND IT_TC1 TO IT_TEMP_TC1.
          ENDIF.
        ELSE.
          MESSAGE E003 WITH TEXT-004.
        ENDIF.
      ENDIF.
      CLEAR : J_1IMTCHID-J_1ICAPIND.
      SELECT SINGLE J_1ICAPIND FROM J_1IMTCHID
                    CLIENT SPECIFIED
                    INTO  J_1IMTCHID-J_1ICAPIND
                    WHERE MANDT = SY-MANDT AND
                    MATNR = IT_TC1-ITEMCODE AND
                    WERKS = EKPO-WERKS.
      IF SY-SUBRC EQ 0.
        IF J_1IMTCHID-J_1ICAPIND = 'N'.
          WK_EXCISE_IND = 'N'.
        ELSE.
          WK_EXCISE_IND = 'E'.
        ENDIF.
      ENDIF.
    ENDMODULE.                 " READ_TABLE_CONTROL  INPUT
    *&      Module  USER_COMMAND_1000  INPUT
          text
    MODULE USER_COMMAND_1000 INPUT.
      V_UCOMM = SY-UCOMM.
      CASE V_UCOMM.
        WHEN 'WK_SAVE'.
          IF WK_APPVAL > 0.
            IF ( SY-UNAME = 'STORE1010'  OR SY-UNAME = 'STORE1020' OR
                 SY-UNAME = 'STORE1030'  OR SY-UNAME = 'STORE1040' OR
                 SY-UNAME = 'STORE1050'  OR SY-UNAME = 'STORE1060' OR
                 SY-UNAME = 'STORE1070'  OR SY-UNAME = 'STORE1080'  ).
              CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
                EXPORTING
                  INPUT  = WK_VBELN
                IMPORTING
                  OUTPUT = WK_VBELN.
              SELECT * FROM EKKO INTO TABLE IT_EKKO WHERE EBELN = WK_EBELN
              AND
                                                          LOEKZ NE 'X'.
              IF SY-SUBRC EQ 0.
                READ TABLE IT_EKKO INDEX 1.
                WK_BSTYP = IT_EKKO-BSTYP.
              ENDIF.
              SELECT * FROM EKPO CLIENT SPECIFIED
              INTO TABLE IT_EKPO WHERE
              MANDT = SY-MANDT AND
              EBELN = WK_EBELN AND LOEKZ NE 'X'.
              SORT IT_EKPO BY EBELN EBELP.
              IF WK_BSTYP = 'L'.
                SELECT * FROM EKET CLIENT SPECIFIED
                INTO TABLE IT_EKET WHERE
                MANDT = SY-MANDT AND
                EBELN = WK_EBELN.
                IF SY-SUBRC EQ 0.
                  SORT IT_EKET BY EBELN EBELP ETENR.
                  LOOP AT IT_EKPO.
                    CLEAR WK_DIFF_QTY.
                    LOOP AT IT_EKET WHERE EBELN = IT_EKPO-EBELN
                                      AND EBELP = IT_EKPO-EBELP
                                      AND EINDT LE SY-DATUM.
                      WK_DIFF_QTY = WK_DIFF_QTY + IT_EKET-MENGE -
                      IT_EKET-WEMNG.
                    ENDLOOP.
                    IF WK_DIFF_QTY GT 0.
                      IT_TEMP_EKPO-EBELN = IT_EKET-EBELN.
                      IT_TEMP_EKPO-EBELP = IT_EKET-EBELP.
                      IT_TEMP_EKPO-MATNR = IT_EKPO-MATNR.
                      APPEND IT_TEMP_EKPO.
                    ENDIF.
                  ENDLOOP.
                ENDIF.
              ELSEIF WK_BSTYP = 'F'.
                SELECT * FROM EKET
                CLIENT SPECIFIED
                INTO TABLE IT_EKET
                WHERE MANDT = SY-MANDT AND
                EBELN = IT_EKPO-EBELN.
                LOOP AT IT_EKPO.
                  CLEAR : WK_DIFF_QTY.
                  READ TABLE IT_EKET WITH KEY EBELN = IT_EKPO-EBELN
                                              EBELP = IT_EKPO-EBELP.
                  IF SY-SUBRC EQ 0.
                    WK_DIFF_QTY = IT_EKPO-MENGE - IT_EKET-WEMNG.
                  ENDIF.
                  IF WK_DIFF_QTY GT 0.
                    IT_TEMP_EKPO-EBELN = IT_EKET-EBELN.
                    IT_TEMP_EKPO-EBELP = IT_EKET-EBELP.
                    IT_TEMP_EKPO-MATNR = IT_EKPO-MATNR.
                    APPEND IT_TEMP_EKPO.
                  ENDIF.
                ENDLOOP.
              ENDIF.
              SORT IT_TEMP_EKPO BY EBELN EBELP.
              PERFORM BDC_DYNPRO      USING 'SAPLMIGO' '0001'.
              PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                       '=OK_GO'.
              PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                       'GODYNPRO-PO_NUMBER'.
              PERFORM BDC_FIELD       USING 'GODYNPRO-PO_NUMBER'
                                       WK_EBELN.
              PERFORM BDC_DYNPRO      USING 'SAPLMIGO' '0001'.
              PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                       '=OK_GO'.
              IF WK_EXCISE_IND = 'E'.
                PERFORM BDC_FIELD       USING 'J_1IEXHEAD-EXNUM'
                                         WK_VBELN.
                PERFORM BDC_FIELD       USING 'J_1IEXHEAD-EXDAT'
                                        WK_FKDAT.
                PERFORM BDC_FIELD       USING 'GOHEAD-LFSNR'
                                         WK_VBELN.
              ELSE.
                PERFORM BDC_FIELD       USING 'GOHEAD-LFSNR'
                                         WK_VBELN.
              ENDIF.
              CLEAR : WK_CHAR_SNO.
              WK_CHAR_SNO = WK_SNO.
              CONDENSE WK_CHAR_SNO NO-GAPS.
              PERFORM BDC_FIELD       USING 'GOHEAD-BKTXT'
                                       WK_CHAR_SNO.
              LOOP AT IT_TEMP_TC1.
                READ TABLE IT_TEMP_EKPO WITH KEY MATNR =
                IT_TEMP_TC1-ITEMCODE.
                IF SY-SUBRC EQ 0.
                  CLEAR V_INDEX.
                  V_INDEX = SY-TABIX.
                  CONDENSE V_INDEX NO-GAPS.
                  PERFORM BDC_DYNPRO      USING 'SAPLMIGO' '0001'.
                  PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                           '=OK_GO'.
                  PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                           'GODYNPRO-DETAIL_ZEILE'.
                  PERFORM BDC_FIELD       USING 'GODYNPRO-DETAIL_ZEILE'
                  PERFORM BDC_FIELD       USING 'GODYNPRO-DETAIL_ZEILE'
                                           V_INDEX.
                  PERFORM BDC_DYNPRO      USING 'SAPLMIGO' '0001'.
                  PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                           '=OK_GO'.
                  PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                           'GOITEM-ERFMG'.
                  PERFORM BDC_FIELD       USING 'GOITEM-ERFMG'
                  CLEAR V_QUANTITY.
                  V_QUANTITY = IT_TEMP_TC1-QUANTITY.
                  CONDENSE V_QUANTITY NO-GAPS.
                  PERFORM BDC_FIELD       USING 'GOITEM-ERFMG'
                                           V_QUANTITY.
                  PERFORM BDC_FIELD       USING 'GOITEM-LSMNG'
                                          V_QUANTITY.
                perform bdc_field       using 'GOITEM-LGOBE'
                                        WK_LGORT.
                ENDIF.
              ENDLOOP.
              CALL TRANSACTION 'MIGO' USING BDCDATA
                              MODE   'E'
                              UPDATE 'L'.
              IF SY-SUBRC NE 0.
                MESSAGE E003 WITH TEXT-003.
                LOOP AT SCREEN.
                  SCREEN-INPUT = 1.
                  MODIFY SCREEN.
                ENDLOOP.
              ENDIF.
              LEAVE PROGRAM.
            ELSE.
              CLEAR : WK_TOT_EXCISE.
              IF NOT WK_EXCISE IS INITIAL.
                LOOP AT IT_TEMP_TC1.
                  READ TABLE IT_EKPO WITH KEY MATNR = IT_TEMP_TC1-ITEMCODE.
                  IF SY-SUBRC EQ 0.
                    WK_TOT_EXCISE = WK_TOT_EXCISE +
               ( ( ( IT_EKPO-NETWR / IT_EKPO-MENGE ) * 16  / 100 )
    IT_TEMP_TC1-QUANTITY ).
                  ENDIF.
                ENDLOOP.
                WK_DIFF = WK_EXCISE - WK_TOT_EXCISE.
                IF WK_DIFF LE 0.
                  WK_DIFF = -1 * WK_DIFF.
                ENDIF.
                IF WK_DIFF GE 1.
                  WK_COMMENT = 'Difference in Excise. Please Check!'.
                ENDIF.
              ENDIF.
              SELECT * FROM EKPO CLIENT SPECIFIED
              INTO TABLE IT_EKPO WHERE
              MANDT = SY-MANDT AND
              EBELN = WK_EBELN.
              IF SY-SUBRC EQ 0.
                READ TABLE IT_EKPO INDEX 1.
                WK_WERKS = IT_EKPO-WERKS.
              ENDIF.
              SELECT * FROM ZMMT001_GRN_GATE
              CLIENT SPECIFIED
              INTO TABLE IT_ZMMT01
              WHERE MANDT = SY-MANDT AND
              WERKS = WK_WERKS.
              IF SY-SUBRC EQ 0.
                SORT IT_ZMMT01 BY SERIAL DESCENDING.
                READ TABLE IT_ZMMT01 INDEX 1.
                WK_SNO = IT_ZMMT01-SERIAL + 1.
              ELSE.
                WK_SNO = 1.
              ENDIF.
              CLEAR WK_ZMMT01.
              WK_ZMMT01-MANDT = SY-MANDT.
              WK_ZMMT01-SERIAL = WK_SNO.
              WK_ZMMT01-WERKS = WK_WERKS.
              WK_ZMMT01-EBELN = WK_EBELN.
              WK_ZMMT01-LIFNR = WK_LIFNR.
              WK_ZMMT01-CHALNO = WK_CHALNO.
              WK_ZMMT01-CHALDATE = WK_CHALDATE.
              WK_ZMMT01-BILLNO = WK_VBELN.
              WK_ZMMT01-BILLDATE = WK_FKDAT.
              WK_ZMMT01-GRNUMBER = WK_GRNO.
              WK_ZMMT01-GRDATE = WK_GRDATE.
              WK_ZMMT01-VEHICLE = WK_VEHICLE.
              WK_ZMMT01-CARRIER = WK_CARRIER.
              WK_ZMMT01-FREIGHT = WK_FREIGHT.
              WK_ZMMT01-MDOC = WK_MDOC.
              WK_ZMMT01-DEPT = WK_DEPT.
              WK_ZMMT01-PAYMODE = WK_MODE.
              WK_ZMMT01-BASIC = WK_BASIC.
              WK_ZMMT01-EXCISE = WK_EXCISE.
              WK_ZMMT01-TAXAMT = WK_TAX.
              WK_ZMMT01-APPVAL = WK_APPVAL.
              WK_ZMMT01-CHALINV = WK_CHAL.
              WK_ZMMT01-FORM38 = WK_FORM38.
              WK_ZMMT01-COMMENTS = WK_COMMENT.
              WK_ZMMT01-CDATE    = SY-DATUM.
              WK_ZMMT01-CTIME    = SY-UZEIT.
              WK_ZMMT01-PERSON   = SY-UNAME.
              IF WK_FKDAT+4(2) = '04' OR
                 WK_FKDAT+4(2) = '05' OR
                 WK_FKDAT+4(2) = '06' OR
                 WK_FKDAT+4(2) = '07' OR
                 WK_FKDAT+4(2) = '08' OR
                 WK_FKDAT+4(2) = '09' OR
                 WK_FKDAT+4(2) = '10' OR
                 WK_FKDAT+4(2) = '11' OR
                 WK_FKDAT+4(2) = '12'.
                WK_DATE10(4) = WK_FKDAT0(4).
                WK_DATE1+4(2) = '04'.
                WK_DATE1+6(2) = '01'.
              ELSEIF
                 WK_FKDAT+4(2) = '01' OR
                 WK_FKDAT+4(2) = '02' OR
                 WK_FKDAT+4(2) = '03'.
                WK_FISYEAR = WK_FKDAT+0(4).
                WK_FISYEAR = WK_FISYEAR - 1.
                WK_CHAR_YEAR = WK_FISYEAR.
                CONDENSE WK_CHAR_YEAR NO-GAPS.
                WK_DATE1+0(4) = WK_CHAR_YEAR.
                WK_DATE1+4(2) = '04'.
                WK_DATE1+6(2) = '01'.
              ELSE.
              ENDIF.
    nidhi
              SELECT LIFNR ADRNR FROM LFA1 INTO TABLE IT_LFA1 WHERE LIFNR =
              WK_ZMMT01-LIFNR.
              SELECT ADDRNUMBER SMTP_ADDR FROM ADR6 INTO TABLE IT_ADR6 FOR
    ALL ENTRIES IN IT_LFA1 WHERE ADDRNUMBER = IT_LFA1-ADRNR.
              SELECT SINGLE * FROM ZMMT001_GRN_GATE
              CLIENT SPECIFIED
              WHERE MANDT = SY-MANDT AND
              WERKS = WK_WERKS AND
              LIFNR = WK_LIFNR AND
              BILLNO = WK_VBELN AND
              BILLDATE GE WK_DATE1.
              IF SY-SUBRC EQ 0.
                MESSAGE E003 WITH TEXT-006.
              ENDIF.
              CLEAR IT_ZMMT02.
              REFRESH IT_ZMMT02.
              LOOP AT IT_TEMP_TC1.
                IT_ZMMT02-MANDT = SY-MANDT.
                IT_ZMMT02-SERIAL = WK_SNO.
                IT_ZMMT02-WERKS = WK_WERKS.
                IT_ZMMT02-EBELN = WK_EBELN.
                IT_ZMMT02-ITEMCODE = IT_TEMP_TC1-ITEMCODE.
                IT_ZMMT02-DESCRIPTION = IT_TEMP_TC1-ITEMNAME.
                IT_ZMMT02-QUANTITY = IT_TEMP_TC1-QUANTITY.
                IT_ZMMT02-EXCISE = IT_TEMP_TC1-EXCISE.
                APPEND IT_ZMMT02.
                CLEAR IT_ZMMT02.
              ENDLOOP.
              IF IT_ZMMT02[] IS INITIAL.
                MESSAGE E003 WITH TEXT-007.
              ENDIF.
              IF SY-UNAME = 'GATE1010' AND WK_WERKS NE '1010'.
                MESSAGE E003 WITH TEXT-008.
              ELSEIF SY-UNAME = 'GATE1020' AND WK_WERKS NE '1020'.
                MESSAGE E003 WITH TEXT-008.
              ELSEIF SY-UNAME = 'GATE1030' AND WK_WERKS NE '1030'.
                MESSAGE E003 WITH TEXT-008.
              ELSEIF SY-UNAME = 'GATE1040' AND WK_WERKS NE '1040'.
                MESSAGE E003 WITH TEXT-008.
              ELSEIF SY-UNAME = 'GATE1050' AND WK_WERKS NE '1050'.
                MESSAGE E003 WITH TEXT-008.
              ELSEIF SY-UNAME = 'GATE1060' AND WK_WERKS NE '1060'.
                MESSAGE E003 WITH TEXT-008.
              ELSEIF SY-UNAME = 'ABAP' AND WK_WERKS NE 'ABAP'.
                MESSAGE E003 WITH TEXT-008.
              ELSEIF SY-UNAME = 'GATE1070' AND WK_WERKS NE '1070'.
                MESSAGE E003 WITH TEXT-008.
              ELSEIF SY-UNAME = 'GATE1080' AND WK_WERKS NE '1080'.
                MESSAGE E003 WITH TEXT-008.
              ENDIF.
              INSERT ZMMT001_GRN_GATE FROM WK_ZMMT01.
              INSERT ZMMT002_GRN_ITEM FROM TABLE IT_ZMMT02.
              IF SY-SUBRC EQ 0.
                COMMIT WORK.
                MESSAGE I002 WITH WK_SNO.
    ********nidhi*******************************************************
                CALL SCREEN 1001.
                CLEAR WK_LIFNR.
                CLEAR WK_EBELN.
                CLEAR WK_NAME.
                CLEAR WK_SCHNO.
                CLEAR WK_CHALNO.
                CLEAR WK_CHALDATE.
                CLEAR WK_VBELN.
                CLEAR WK_FKDAT.
                CLEAR WK_GRNO.
                CLEAR WK_GRDATE.
                CLEAR WK_VEHICLE.
                CLEAR WK_CARRIER.
                CLEAR WK_FREIGHT.
                CLEAR WK_MDOC.
                CLEAR WK_DEPT.
                CLEAR WK_MODE.
                CLEAR WK_BASIC.
                CLEAR WK_EXCISE.
                CLEAR WK_TAX.
                CLEAR WK_APPVAL.
                CLEAR WK_CHAL.
                CLEAR WK_FORM38.
                REFRESH IT_TEMP_TC1.
                CLEAR WK_FISYEAR.
                CLEAR WK_DATE1.
                CLEAR WK_CHAR_YEAR.
             CALL TRANSACTION 'ZMMI001'.
              ELSE.
                ROLLBACK WORK.
                MESSAGE E003 WITH TEXT-006.
              ENDIF.
            ENDIF.
          ELSE.
            MESSAGE E009 WITH TEXT-014.
          ENDIF.
        WHEN 'WK_EXIT'.
        WHEN 'WK_CLEAR'.
          CLEAR WK_LIFNR.
          CLEAR WK_EBELN.
          CLEAR WK_NAME.
          CLEAR WK_SCHNO.
          CLEAR WK_CHALNO.
          CLEAR WK_CHALDATE.
          CLEAR WK_VBELN.
          CLEAR WK_FKDAT.
          CLEAR WK_GRNO.
          CLEAR WK_GRDATE.
          CLEAR WK_VEHICLE.
          CLEAR WK_CARRIER.
          CLEAR WK_FREIGHT.
          CLEAR WK_MDOC.
          CLEAR WK_DEPT.
          CLEAR WK_MODE.
          CLEAR WK_BASIC.
          CLEAR WK_EXCISE.
          CLEAR WK_TAX.
          CLEAR WK_APPVAL.
          CLEAR WK_CHAL.
          CLEAR WK_FORM38.
          REFRESH IT_TEMP_TC1 .
          CLEAR WK_FISYEAR.
          CLEAR WK_DATE1.
          CLEAR WK_CHAR_YEAR.
        WHEN 'DELETE'.
          DELETE IT_TEMP_TC1 WHERE SEL = 'X'.
      ENDCASE.
    ENDMODULE.                 " USER_COMMAND_1000  INPUT
           Start new screen                                              *
    FORM BDC_DYNPRO USING PROGRAM DYNPRO.
      CLEAR BDCDATA.
      BDCDATA-PROGRAM  = PROGRAM.
      BDCDATA-DYNPRO   = DYNPRO.
      BDCDATA-DYNBEGIN = 'X'.
      APPEND BDCDATA.
    ENDFORM.                    "BDC_DYNPRO
           Insert field                                                  *
    FORM BDC_FIELD USING FNAM FVAL.
    IF FVAL <> NODATA.
      CLEAR BDCDATA.
      BDCDATA-FNAM = FNAM.
      BDCDATA-FVAL = FVAL.
      APPEND BDCDATA.
    ENDIF.
    ENDFORM.                    "BDC_FIELD
    *&      Module  STATUS_1000  OUTPUT
          text
    MODULE STATUS_1000 OUTPUT.
      SET PF-STATUS 'GRN'.
      SET TITLEBAR 'GRN'.
      PROGNAME = SY-REPID.
      DYNNUM   = SY-DYNNR.
      CLEAR: FIELD_VALUE, DYNPRO_VALUES.
      FIELD_VALUE-FIELDNAME = 'IT_TC1-ITEMCODE'.
      APPEND FIELD_VALUE TO DYNPRO_VALUES.
      FIELD_VALUE-FIELDNAME = 'WK_EBELN'.
      APPEND FIELD_VALUE TO DYNPRO_VALUES.
      FIELD_VALUE-FIELDNAME = 'WK_LIFNR'.
      APPEND FIELD_VALUE TO DYNPRO_VALUES.
      LOOP AT SCREEN.
        IF SCREEN-NAME NE 'WK_COMMENT'.
          SCREEN-INPUT = 1.
        ENDIF.
        MODIFY SCREEN.
      ENDLOOP.
      IF ( SY-UNAME = 'GATE1010' OR SY-UNAME = 'GATE1020' OR
           SY-UNAME = 'GATE1030' OR SY-UNAME = 'GATE1040' OR
           SY-UNAME = 'GATE1050' OR SY-UNAME = 'GATE1060' OR
           SY-UNAME = 'GATE1070' OR SY-UNAME = 'GATE1080' OR  SY-UNAME =
           'ABAP' ).
        LOOP AT SCREEN.
          IF SCREEN-NAME = 'WK_SNO' OR
             SCREEN-NAME = 'SNO' OR
             SCREEN-NAME = 'WK_COMMENT' .
            SCREEN-INVISIBLE = 1.
            SCREEN-ACTIVE = 0.
            SCREEN-INPUT = 0.
            SCREEN-OUTPUT = 0.
          ENDIF.
          MODIFY SCREEN.
        ENDLOOP.
        IF WK_LIFNR IS INITIAL.
          SET CURSOR FIELD 'WK_LIFNR'.
        ELSEIF WK_EBELN IS INITIAL.
          SET CURSOR FIELD 'WK_EBELN'.
        ELSEIF WK_VBELN IS INITIAL.
          SET CURSOR FIELD 'WK_VBELN'.
        ELSEIF WK_FKDAT IS INITIAL.
          SET CURSOR FIELD 'WK_FKDAT'.
        ENDIF.
      ELSE.
        IF NOT WK_SNO IS INITIAL.
          IF SY-UNAME = 'STORE1010'.
            WK_WERKS = '1010'.
          ELSEIF SY-UNAME = 'STORE1020'.
            WK_WERKS = '1020'.
          ELSEIF SY-UNAME = 'STORE1030'.
            WK_WERKS = '1030'.
          ELSEIF SY-UNAME = 'STORE1040'.
            WK_WERKS = '1040'.
          ELSEIF SY-UNAME = 'STORE1050'.
            WK_WERKS = '1050'.
          ELSEIF SY-UNAME = 'STORE1060'.
            WK_WERKS = '1060'.
          ELSEIF SY-UNAME = 'STORE1070'.
            WK_WERKS = '1070'.
          ELSEIF SY-UNAME = 'STORE1080'.
            WK_WERKS = '1080'.
          ENDIF.
          SELECT SINGLE * FROM ZMMT001_GRN_GATE INTO WK_ZMMT01
                       WHERE SERIAL = WK_SNO AND
                       WERKS = WK_WERKS.
          IF SY-SUBRC EQ 0.
            WK_WERKS = WK_ZMMT01-WERKS.
            WK_EBELN = WK_ZMMT01-EBELN.
            WK_LIFNR = WK_ZMMT01-LIFNR.
            WK_CHALNO = WK_ZMMT01-CHALNO.
            WK_CHALDATE = WK_ZMMT01-CHALDATE.
            WK_VBELN = WK_ZMMT01-BILLNO.
            WK_FKDAT = WK_ZMMT01-BILLDATE.
            WK_GRNO = WK_ZMMT01-GRNUMBER.
            WK_GRDATE = WK_ZMMT01-GRDATE.
            WK_VEHICLE = WK_ZMMT01-VEHICLE.
            WK_CARRIER = WK_ZMMT01-CARRIER.
            WK_FREIGHT = WK_ZMMT01-FREIGHT.
            WK_MDOC = WK_ZMMT01-MDOC.
            WK_DEPT = WK_ZMMT01-DEPT.
            WK_MODE = WK_ZMMT01-PAYMODE.
            WK_BASIC = WK_ZMMT01-BASIC.
            WK_EXCISE = WK_ZMMT01-EXCISE.
            WK_TAX = WK_ZMMT01-TAXAMT.
            WK_APPVAL = WK_ZMMT01-APPVAL.
            WK_CHAL = WK_ZMMT01-CHALINV.
            WK_FORM38 = WK_ZMMT01-FORM38.
            WK_COMMENT = WK_ZMMT01-COMMENTS.
            SELECT * FROM ZMMT002_GRN_ITEM INTO TABLE IT_ZMMT02
                            WHERE SERIAL = WK_SNO AND
                            WERKS = WK_WERKS.
            IF SY-SUBRC EQ 0.
              CLEAR IT_TEMP_TC1.
              REFRESH IT_TEMP_TC1.
              LOOP AT IT_ZMMT02.
                IT_TEMP_TC1-SNO = SY-TABIX.
                IT_TEMP_TC1-ITEMCODE = IT_ZMMT02-ITEMCODE.
                IT_TEMP_TC1-ITEMNAME = IT_ZMMT02-DESCRIPTION.
                IT_TEMP_TC1-QUANTITY = IT_ZMMT02-QUANTITY.
                APPEND IT_TEMP_TC1.
                CLEAR IT_TEMP_TC1.
              ENDLOOP.
            ENDIF.
          ENDIF.
          LOOP AT SCREEN.
            IF ( SCREEN-NAME NE 'WK_SNO' ) AND
               ( SCREEN-NAME NE 'WK_SAVE' ) AND
               ( SCREEN-NAME NE 'WK_CLEAR' ) AND
               ( SCREEN-NAME NE 'WK_EXIT' ).
              SCREEN-INPUT = 0.
            ENDIF.
            MODIFY SCREEN.
          ENDLOOP.
          LOOP AT TC1-COLS INTO COLS WHERE INDEX GT 0.
            COLS-SCREEN-INPUT = '0'.
            MODIFY TC1-COLS FROM COLS INDEX SY-TABIX.
          ENDLOOP.
        ENDIF.
      ENDIF.
      WK_DATE = SY-DATUM.
      WK_TIME = SY-UZEIT.
      TC1-LINES = 20.
    ENDMODULE.                 " STATUS_1000  OUTPUT
    *&      Module  EXIT_1000  INPUT
          text
    MODULE EXIT_1000 INPUT.
      CASE SY-UCOMM.
        WHEN 'BACK' OR 'CANCEL' OR 'EXIT' OR 'WK_EXIT'.
          LEAVE PROGRAM.
      ENDCASE.
    ENDMODULE.                 " EXIT_1000  INPUT
    *&      Module  ITEM_CODE  INPUT
          text
    MODULE ITEM_CODE INPUT.
      REFRESH : VALUES_TAB.
      CLEAR : VALUES_TAB.
      IF ( SY-UNAME = 'GATE1020' OR
    SY-UNAME = 'GATE1010' OR
    SY-UNAME = 'GATE1030' OR
    SY-UNAME = 'GATE1040' OR
    SY-UNAME = 'GATE1050' OR
    SY-UNAME = 'GATE1060' OR
    SY-UNAME = 'GATE1070' OR
    SY-UNAME = 'STORE1020' OR
    SY-UNAME = 'STORE1030' OR
    SY-UNAME = 'STORE1040' OR
    SY-UNAME = 'STORE1050' OR
    SY-UNAME = 'STORE1060' OR
    SY-UNAME = 'STORE1070' OR
    SY-UNAME = 'STORE1010' OR
           SY-UNAME = 'ABAP'  ).
        SELECT * FROM EKKO CLIENT SPECIFIED
        INTO TABLE IT_EKKO WHERE
        MANDT = SY-MANDT AND
        EBELN = WK_EBELN AND
        LOEKZ NE 'X'.
        IF SY-SUBRC EQ 0.
          READ TABLE IT_EKKO INDEX 1.
          WK_BSTYP = IT_EKKO-BSTYP.
          WK_BSART = IT_EKKO-BSART.
        ENDIF.
          if wk_bsart = 'ZLR'.
        SELECT * FROM EKPO CLIENT SPECIFIED
        INTO TABLE IT_EKPO WHERE
        MANDT = SY-MANDT AND
        EBELN = WK_EBELN AND
        LOEKZ NE 'X'.
        SORT IT_EKPO BY EBELN EBELP.
        IF WK_BSTYP = 'L' AND WK_BSART = 'ZLR'.
          SELECT * FROM EKET CLIENT SPECIFIED
          INTO TABLE IT_EKET WHERE
          MANDT = SY-MANDT AND
          EBELN = WK_EBELN.
          IF SY-SUBRC EQ 0.
            SORT IT_EKET BY EBELN EBELP ETENR.
            LOOP AT IT_EKPO.
              CLEAR WK_DIFF_QTY.
              LOOP AT IT_EKET WHERE EBELN = IT_EKPO-EBELN
                                AND EBELP = IT_EKPO-EBELP
                                AND EINDT LE SY-DATUM.
                WK_DIFF_QTY = WK_DIFF_QTY + IT_EKET-MENGE - IT_EKET-WEMNG.
              ENDLOOP.
              IF WK_DIFF_QTY GT 0.
                VALUES_TAB-TXZ01 = IT_EKPO-TXZ01.
                VALUES_TAB-MENGE = WK_DIFF_QTY.
                VALUES_TAB-MATNR = IT_EKPO-MATNR.
                APPEND VALUES_TAB.
              ENDIF.
            ENDLOOP.
          ENDIF.
        ELSEIF WK_BSTYP = 'F'.
         SELECT mseg~mblnr
                mseg~mjahr
                mseg~zeile
                mseg~bwart
                mseg~matnr
                mseg~ebeln
                mseg~ebelp
                mkpf~budat
                mseg~menge INTO TABLE it_mseg
                FROM mkpf INNER JOIN mseg
                ON mkpfmblnr EQ msegmblnr
                AND mkpfmjahr EQ msegmjahr
    FOR ALL entries IN it_ekpo
    WHERE bwart IN ('101','122','102')
    AND werks = it_ekpo-werks
    AND ebeln = it_ekpo-ebeln
    AND ebelp = it_ekpo-ebelp.
          SELECT * FROM EKET CLIENT SPECIFIED
          INTO TABLE IT_EKET
          WHERE MANDT = SY-MANDT AND
          EBELN = IT_EKPO-EBELN.
          LOOP AT IT_EKPO.
            CLEAR : WK_DIFF_QTY.
                   wk_101_qty,
                   wk_102_qty,
                   wk_122_qty.
           LOOP AT it_mseg WHERE ebeln = it_ekpo-ebeln AND
                                 ebelp = it_ekpo-ebelp.
             IF it_mseg-bwart = '101'.
               wk_101_qty = wk_101_qty + it_mseg-menge.
             ENDIF.
             IF it_mseg-bwart = '102'.
               wk_102_qty = wk_102_qty + it_mseg-menge.
             ENDIF.
             IF it_mseg-bwart = '122'.
               wk_122_qty = wk_122_qty + it_mseg-menge.
             ENDIF.
           ENDLOOP.
           if not it_mseg[] is initial.
           wk_diff_qty = it_ekpo-menge - wk_101_qty
                                 - wk_102_qty - wk_122_qty.
           else.
            wk_diff_qty = it_ekpo-menge.
           endif.
            READ TABLE IT_EKET WITH KEY EBELN = IT_EKPO-EBELN
                                        EBELP = IT_EKPO-EBELP.
            IF SY-SUBRC EQ 0.
              WK_DIFF_QTY = IT_EKPO-MENGE - IT_EKET-WEMNG.
            ENDIF.
           IF wk_diff_qty LE it_ekpo-menge.
            IF WK_DIFF_QTY GT 0.
              VALUES_TAB-TXZ01 = IT_EKPO-TXZ01.
              VALUES_TAB-MENGE = WK_DIFF_QTY.
              VALUES_TAB-MATNR = IT_EKPO-MATNR.
              APPEND VALUES_TAB.
            ENDIF.
          ENDLOOP.
           ENDIF.
        ELSE.
          SELECT TXZ01
          MATNR FROM EKPO CLIENT SPECIFIED
          INTO CORRESPONDING FIELDS OF TABLE VALUES_TAB
          WHERE MANDT = SY-MANDT AND
          EBELN = WK_EBELN AND
          LOEKZ NE 'X'.
        ENDIF.
      ELSE.
        SELECT TXZ01
              MATNR FROM EKPO CLIENT SPECIFIED
              INTO CORRESPONDING FIELDS OF TABLE VALUES_TAB
               WHERE MANDT = SY-MANDT AND
               EBELN = WK_EBELN AND
               LOEKZ NE 'X'.
      ENDIF.
      SORT VALUES_TAB BY TXZ01.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
          RETFIELD        = 'IT_TC1-ITEMCODE'
          DYNPPROG        = PROGNAME
          DYNPNR          = DYNNUM
          DYNPROFIELD     = 'IT_TC1-ITEMCODE'
          VALUE_ORG       = 'S'
        TABLES
          VALUE_TAB       = VALUES_TAB
          RETURN_TAB      = RETURN_TAB
        EXCEPTIONS
          PARAMETER_ERROR = 1
          NO_VALUES_FOUND = 2
          OTHERS          = 3.
    *BREAK-POINT.
      IF SY-SUBRC = 0.
        READ TABLE RETURN_TAB INDEX 1.
        SELECT SINGLE MAKTX FROM MAKT CLIENT SPECIFIED
        INTO WK_MAKTX WHERE
        MANDT = SY-MANDT AND
        MATNR = RETURN_TAB-FIELDVAL AND SPRAS = SY-LANGU.
      ENDIF.
    ENDMODULE.                 " ITEM_CODE  INPUT
    *&      Module  CHECK_INPUT  INPUT
          text
    MODULE CHECK_INPUT INPUT.
      CLEAR : EKKO-EBELN , EKKO-LIFNR.
      SELECT SINGLE EBELN LIFNR FROM EKKO CLIENT SPECIFIED
      INTO (EKKO-EBELN , EKKO-LIFNR )  WHERE
      MANDT = SY-MANDT AND
      EBELN = WK_EBELN.
      IF SY-SUBRC NE 0 AND ( SY-UNAME = 'GATE1010' OR
                             SY-UNAME = 'GATE1020' OR
                             SY-UNAME = 'GATE1030' OR
                             SY-UNAME = 'GATE1040' OR
                             SY-UNAME = 'GATE1050' OR
                             SY-UNAME = 'GATE1060' OR
                             SY-UNAME = 'GATE1070' OR
                             SY-UNAME = 'GATE1080' OR  SY-UNAME = 'ABAP' ).
        IF WK_EBELN NE SPACE.
          MESSAGE E003 WITH TEXT-001.
        ENDIF.
      ELSE.
        WK_LIFNR = EKKO-LIFNR.
        CLEAR : LFA1-NAME1.
        SELECT SINGLE NAME1 FROM LFA1 CLIENT SPECIFIED
        INTO LFA1-NAME1 WHERE
        MANDT = SY-MANDT AND
        LIFNR = WK_LIFNR.
        IF SY-SUBRC EQ 0.
          WK_NAME = LFA1-NAME1.
        ENDIF.
      ENDIF.
      IF ( SY-UNAME = 'GATE1010' OR SY-UNAME = 'GATE1020' OR
           SY-UNAME = 'GATE1030' OR SY-UNAME = 'GATE1040' OR
           SY-UNAME = 'GATE1050' OR SY-UNAME = 'GATE1060' OR
           SY-UNAME = 'GATE1070' OR SY-UNAME = 'GATE1080' OR  SY-UNAME =
           'ABAP' ).
       IF wk_vbeln IS INITIAL.
         set cursor field wk_vbeln.
         MESSAGE E003 WITH text-009.
       ENDIF.
       IF wk_fkdat IS INITIAL.
         MESSAGE E003 WITH text-010.
       ENDIF.
      ENDIF.
      IF ( SY-UNAME = 'STORE1010' OR SY-UNAME = 'STORE1020' OR
           SY-UNAME = 'STORE1030' OR SY-UNAME = 'STORE1040' OR
           SY-UNAME = 'STORE1050' OR SY-UNAME = 'STORE1060' OR
           SY-UNAME = 'STORE1070' OR SY-UNAME = 'STORE1080' ).
        CLEAR : ZMMT001_GRN_GATE.
        SELECT SINGLE EBELN CDATE FROM ZMMT001_GRN_GATE
        CLIENT SPECIFIED
        INTO (ZMMT001_GRN_GATE-EBELN ,
        ZMMT001_GRN_GATE-CDATE )
        WHERE MANDT = SY-MANDT AND
        SERIAL = WK_SNO AND WERKS = WK_WERKS.
        IF SY-SUBRC EQ 0.
          SELECT MBLNR
                 MJAHR
                 BUDAT
                 BKTXT FROM MKPF CLIENT SPECIFIED
                 INTO TABLE IT_TEMP_MKPF
                 WHERE MANDT = SY-MANDT AND
                 BUDAT = ZMMT001_GRN_GATE-CDATE
                 AND BKTXT = WK_SNO.
          IF

    Hi,
    after calling you programm and get the message call transaction su53. That willl display the authorization that you need.
    Hope this helps.
    Regards
    Bernd

  • I'm trying to sync my Iphone to get some new music but getting error message 'itunes was unable to load data class info'.  How do I fix it (my husband's 2 devices work fine on the PC)

    I'm trying to sync my Iphone to get some new music but getting error message 'itunes was unable to load data class info'.  How do I fix it (my husband's 2 devices work fine on the PC).  It's driving me mental and has stopped me putting anything new on for months.  Help!!!

    http://support.apple.com/kb/TS2690

  • Installing and formatting new HDD

    The HDD on my two year old MacBook Pro has gone bad, probably defective from the beginning.  Anyway, I live in another country, but had someone bring me a new HDD (upgrading from 750GB to 1TB).  I have already unistalled the old HDD and installed the new HDD.  Now I am trying to clone the old HDD.  I have had some problems using Disk Utility.  Not sure if I should have cloned the old HDD before unistalling it?? 
    Also, I have read several discussions involving Carbon Copy Cloner. I don't really understand how it works/how I would use it in my current situation.  Should I purchase the software? Will I have to back the computer up to another external HDD using carbon copy cleaner, and only then be able to clone it to the new drive?

    rogers2nica,
    if your old HDD has gone bad, then cloning it would also clone its faulty areas. The time to clone (and make other forms of backup) is when the source drive is working well. If you’re trying to salvage data from your bad HDD, then to minimize problems with your new HDD, you should install the OS and apps on the new HDD from scratch, and only salvage your personal data files from the old HDD.

  • ODBC Data Source Aministrator - new data source- error - SAP BO XI 3.1 SP3

    Hello there,
    when adding a new mySQL data source to the ODBC Data Source Aministrator on the server we recieve the following error message:
    The setup routines for the MySQL ODBC 5.1 Driver ODBC driver could not be loaded due to system error code 126: The specified module could not be found.
    (C:\Windows\system32\myodbc5S.dll)
    Does anybody know how to solve that problem?
    Thanks in advance!
    Alex

    Hi,
    is the .dll in the designated path?
    Regards
    -Seb.

Maybe you are looking for

  • Deleted audio comes back when movie is exported.

    When I view the project in iMovie, there is no audio except for the music tracks I added, but when I export it as a quicktime movie or to DVD, the audio that I had removed is back. I have double checked the settings, everything is muted, and I even w

  • Garbled Text

    Why am I recently getting garbled text when I try to download pdf's on my mac?

  • Creating Company Codes in Global Roll-out Project

    Dear Experts Our Company operates out of multiple countries and we have embarked on implementing SAP across all our subsidiaries in these countries. We are planning on a Single Instance Single Client Landscace. With this in mind, we have completed th

  • Complete recovery

    Hi All, I have a doubt. Imagine a database in archive log mode. whatever transactions are going on vil be written to redo logs and then to the archivelogs during the subsequent switch. But what if when db got crashed before the archive generated for

  • Help Please - New MAC User - OS X 10.6.8 Freezing

    Hello......New MAC user after moving from Windows and I have been delighted with the perfomance.  Out of the blue yesterday typing became hesistant.  Today Keyboard quit.  Changed batteries but still no go.  That was quickly followed by the MAC freez