How to add new fuctionality without modifying Print Program.

Hi,
This is Venkatrami Reddy.
I have a requirement which needs to display Vendor Number in form.
So, Please help me on this issue with some example code by using ITCSY Structure.
Thanks
Venkatrami Reddy

Hi
Welcome to SDN forum
check the Existing Script program whether the field Vendor Number (LIFNR) is available or not, (for example if you are using PO script MEDRUCK then it will be there in EKKO table structure)
then only you need to write an external subroutine using ITCSY structure and to bring the data from external table and to write in the script
see the sample code
REPORT ZMPO1 .
form get_freight tables in_par structure itcsy out_par structure itcsy.
tables: ekko,konv,t685t.
data: begin of itab occurs 0,
         ebeln like ekko-ebeln,
         knumv like ekko-knumv,
       end of itab.
data: begin of itab1 occurs 0,
         knumv like konv-knumv,
         kposn like konv-kposn,
         kschl like konv-kschl,
         kbetr like konv-kbetr,
         waers like konv-waers,
         kwert like konv-kwert,
       end of itab1.
data: begin of iout occurs 0,
         kschl like konv-kschl,
         vtext like t685t-vtext,
         kbetr like konv-kbetr,
         kwert like konv-kwert,
       end of iout.
data v_po like ekko-ebeln.
read table in_par with key 'EKKO-EBELN'.
if sy-subrc = 0.
   v_po = in_par-value.
   select
     ebeln
     knumv
  from ekko
  into table itab
  where ebeln = v_po.
  if sy-subrc = 0.
    loop at itab.
      select
        knumv
        kposn
        kschl
        kbetr
        waers
        kwert
      into table itab1
      from konv
      where knumv = itab-knumv and
            kappl = 'M'.
    endloop.
    loop at itab1.
      if itab1-kposn <> 0.
        select single * from t685t
                          where kschl = itab1-kschl
                            and kappl = 'M'
                            and spras = 'EN'.
        iout-vtext = t685t-vtext.
        iout-kschl = itab1-kschl.
        iout-kbetr = itab1-kbetr.
        iout-kwert = itab1-kwert.
        append iout.
        clear iout.
      endif.
    endloop.
    sort itab1 by kposn.
    loop at iout.
      sort iout by kschl.
      if ( iout-kschl eq 'GSDC' OR
           iout-kschl eq 'GSFR' OR
           iout-kschl eq 'GSIR' ).
        at end of kschl.
          read table iout index sy-tabix.
          sum.
         write:/ iout-kschl,iout-vtext,iout-kwert.
      out_par-name = 'A1'.
      out_par-value = iout-vtext.
      append out_par.
      out_par-name = 'A2'.
      out_par-value = iout-kwert.
      append out_par.
          endat.
        endif.
      endloop.
    endif.
  endif.
endform.
IN THE FORM I AM WRITING THIS CODE.
/:DEFINE &A1& = ' '
/:DEFINE &A2& = ' '
/:PERFORM GET_FREIGHT IN PROGRAM ZMFORM_PO1
/:USING &EKKO-EBELN&
/:CHANGING &A1&
/:CHANGING &A2&
/:ENDPERFORM
&A1&
&A2&
This Code is to be written in the PO form under ADDRESS window.
/:DEFINE &A1& = ' '
/:DEFINE &A2& = ' '
/:DEFINE &A3& = ' '
/:DEFINE &A4& = ' '
/:DEFINE &A5& = ' '
/:DEFINE &A6& = ' '
/:PERFORM GET_VENDOR IN PROGRAM ZMFORM_PO
/:USING &EKKO-EBELN&
/:CHANGING &A1&
/:CHANGING &A2&
/:CHANGING &A3&
/:CHANGING &A4&
/:CHANGING &A5&
/:CHANGING &A6&
/:ENDPERFORM
&A1&
&A2&
&A3&
&A4&
&A5&
&A6&
<b>Reward points for useful Answers</b>
Regards
Anji

Similar Messages

  • HT1296 how to add new photos without deleting the existing photos in ipad

    Hi,
    Can anyone tell me how to add new photos/PDF books from my PC to iPad without deleting the exsting data in iPad?

    Hello AJ2349
    If it is prompting you that it will replace the data on your iPhone, then that is typically the result of syncing with a different computer. The only way you can bypass that is to replace the media on your device and then sync. Now it will only replace items that would be considered purchased items like music, movies, TV shows and Apps and would not delete any pictures from your iPhone. Alternatively you can setup a Shared Photo Stream and then add the Photos there without syncing your iPhone with your computer. Check out the articles below for more information.
    iOS: Issues syncing content with multiple computers using iTunes
    http://support.apple.com/kb/ts1474
    Managing content manually on iPhone, iPad, and iPod
    http://support.apple.com/kb/ht1535
    iCloud: Shared Photo Streams FAQ
    http://support.apple.com/kb/HT5903
    Regards,
    -Norm G.

  • How to add new class in modified template...

    Finally I have encourage myself to scratch to (for me deepest darkwood) templates...
    I have modified original Theme 2 to My theme 2 and added in some tempaltes region my parts-looks promising.
    Now I want to create sidebar region that is 450 px wide.
    It should be the same sidebar region but with different width!
    I saw on file system that there is .css so I add this class in it....(as aspected) it is not shown in template class list...
    I am able to apply that new class to template, but I cannot see that class in "Template Class" LOV (in Edit Region Template form).
    Is that important and could this bee seen in that list?
    THX!

    I have now working template with my new class...
    What is still bothering me is that I have editeted "theme_V2.css" file. I'm plannig to put my app on hosted WEB site in Germany, where this file will not be the same as is on my server.
    How to achieve future compatibilty according this?
    THX!

  • BAPI_REQUIREMENTS_CHANGE - How to add new qty without refreshing existing

    Hello ,
    I am using this bapi the problem i am facing BAPI_REQUIREMENTS_CHANGE.
    Problem -
                    How to overwrite existing values.

    Hi Andre,
    Here is the description of the tables:
    table with the NEW content of: EBAN
    data: begin of xeban                           occurs 20.
            include structure ueban                         .
    data: end of xeban                          .
    table with the OLD content of: EBAN
    data: begin of yeban                           occurs 20.
            include structure ueban                         .
    data: end of yeban                          .
    table with the NEW content of: EBKN
    data: begin of xebkn                           occurs 20.
            include structure uebkn                         .
    data: end of xebkn                          .
    table with the OLD content of: EBKN
    data: begin of yebkn                           occurs 20.
            include structure uebkn                         .
    data: end of yebkn                          .
    Regards,
    Nitin.

  • I have one playlist on iphone4. how can i add new playlist without deleting old one. i do not have old playlist in itunes any more.

    I have one playlist on iphone4. how can i add new playlist without deleting old one. i do not have old playlist in itunes any more.When i try to sync iphone with itunes it says that this action will remove my old playlist and all songs.

    "it says that this action will remove my old playlist and all songs."
    Are you connecting to a different iTunes library than you normally connect to?  That will erase the songs and playlists since the iPhone can't be connected to multiple libraries even if it is in manual sync mode.
    If you no longer have access to the original library that your iPhone calls 'home', then the only way to save the playlist (and the songs on your iPhone) would be to use a 3rd party application to extract your iPhone contents to this new iTunes library you're trying to connect to.

  • How to add new group entry in Cisco Vpn using powershell

    I am working on a powershell script to connect cisco vpn using powershell, I am able to connect to vpn but not sure how to add new group to vpn. I am using the following script$vpn_profile = 'Test'
    $username = 'TestUser'
    $userPassword = ConvertTo-SecureString -String "Password" -AsPlainText -Force
    $credentials = new-object -typename System.Management.Automation.PSCredential -argumentlist
    $username,$userPassword
    $password = $credentials.GetNetworkCredential().Password
    Set-Location 'c:\Program Files (x86)\Cisco Systems\VPN Client'
    .\vpnclient.exe connect $vpn_profile user $username pwd $password
    Write-Host "You Are Connected"
    cd "C:\"

    Have you entered .\vpnclient.exe /? to see if it will return information about other switches you can use with this executable? Other than connect, I was able to track down a few without actually having the executable (http://www.scribd.com/doc/40108893/Cisco-VPN-Client-Command-Line).
    That said, I do not believe that there is a switch that will help you create a connection. These are either done manually through the GUI, or can be likely be added by supplying a properly formatted file in the proper place.
    If you're using the version of the Cisco VPN client I think you are, then your connection settings, or profiles, are stored in individual .pcf files somewhere on your computer (likely in the Cisco directory). These are simple, text-based files. Find one
    on your computer, save it with another name, and then modify it manually. If you really want to use PowerShell, then use this opportunity to learn how to create and edit basic text files using PowerShell. If you have a standard connection file, then you can
    put that file onto remote computers any number of ways. If a .pcf file exists in the proper place when the VPN client is opened, then it likely will not prompt for a new connection.
    Update: Added more info; clarified

  • How to add new text field in standard report

    how to add new text field in standard report?

    Hi,
    I presume you are talking about a report display in ALV and u wish to add a column to it .
    If it is a global requirement ,as in table being used there in ALV can be modified, then you can append the table and the system should pick up the same automatically from there.
    Otherwise , you can make a Z program . Modify the catalog being used in ALV.
    Regards,
    Shweta

  • How to add new row and update existing rows at a time form the upload file

    hi
    How to add new row and update existing rows at a time form the upload file
    example:ztable(existing table)
    bcent                      smh            nsmh         valid date
    0001112465      7.4                       26.06.2007
    0001112466      7.5                       26.06.2007
    000111801                      7.6                       26.06.2007
    1982                      7.8                       26.06.2007
    Flat file structure
    bcent                       nsmh         valid date
    0001112465     7.8     26.06.2007  ( update into above table in nsmh)
    0001112466     7.9     26.06.2007  ( update into above table in nsmh) 
    000111801                     7.6      26.06.2007 ( update into above table in nsmh
    1985                      11              26.06.2007   new row it should insert in table
    thanks,
    Sivagopal R

    Hi,
    First upload the file into an internal table. If you are using a file that is on application server. Use open dataset and close dataset.
    Then :
    Loop at it.
    *insert or modify as per your requirement.
    Endloop.
    Regards,
    Srilatha.

  • How to add new columns in materialized view

    We are using Oracle 10g Release2.
    We need to add new columns to a prebuilt fast refresh materialized view. We want to add 4 new columns in this table and make them part of select statement in the materialized view. We can drop the view but we cannot do complete refresh after that because the paymentsInfo table has a creation_timestamp column which is populated by before row insert trigger with systimestamp. If we did the complete refresh, all values in this column shall be changed.
    CREATE MATERIALIZED VIEW  paymentsInfo
    ON PREBUILT TABLE
    REFRESH FAST
      ON DEMAND
      START WITH SYSDATE
      NEXT SYSDATE+5/1440
      WITH PRIMARY KEY
    DISABLE QUERY REWRITE AS
    SELECT PAYMENT_ID,BATCH_REFERENCE, TRANSACTION_REFERENCE, NO_OF_TRANSACTIONS, DEBIT_ACC_NUM,... from payment@dblink
    I want to know is there any other way to add new columns without losing any changes from the master table.
    Thanks.

    There is no way to add new Columns to Materialized view. To add new columns, it has to be dropped and re-built again.
    Extract from Oracle Documentaion:
    Use the ALTER MATERIALIZED VIEW statement to modify an existing materialized view in one or more of the following ways:
      To change its storage characteristics
      To change its refresh method, mode, or time
      To alter its structure so that it is a different type of materialized view
      To enable or disable query rewrite
    If you have a problem of Complete refresh, then It may be beneficial to get the backup of the MView; Drop and re-create it with modified definition; Restore the backup data leaving the new columns untouched (assuming they are to be kept as fetched from the Master site).

  • How to add new T Code FB01L in OBU1

    Dear Expert,
    How to add new T Code FB01L in OBU1
    Regards,
    Alok

    Hi, Alok.
    It is not possible to add new entries to table TSTCP via transaction OBU1 (you can only modify the default parameters for the existing transactions).  However, new default parameters for other transactions can be created via transaction SE93 (trans F-44).  You can review notes 19798 and 310587 for further information.
    I hope this helps.
    M Trein

  • How do install new software without a keyboard??

    I just got the mac mini without bluetooth.
    I am looking to add Belkin bluetooth but I do not have a keyboard - How do install new software without a keyboard??

    casimirtad-
    Tis a bummer. It is not a bad idea to have a cheap usb keyboard and mouse around for future troubleshooting purposes, but I am not sure that will get you past this.
    Have you tried plugging stuff in to see if it works? I don't have a happy feeling that it will but it couldn't hurt to try.
    Luck-
    -DaddyPaycheck

  • How to add new fields in Reduced message ( in BD53 )

    Hi Experts,
    How to add new fields in Reduced message ( in BD53 ), when the required field iis available in Table or Structure and need to be added in BD53 so that we can ALE.
    Thanks,
    Ninad

    Hello,
    I think of something like:
    First, you create extension, with transaction WE30.
    Then, reduce your idoc, your extension should also be proposed.
    Do not forget to add this extension in outbound we82, and/or we57 in inbound, and WE20, and find BTE or exit to populate extension.
    regards.
    F.S.

  • PLz Help me its urgent, how to add new field in mm01 basic data screen

    Hi everyone,
         plz tell me how to add new field in mm01 basic data screen,i added that field in basic data screen but when i create a material the data for that field will not save in database table.
    Thanks,
    murali.

    Hi Murali,
    when created added a field on the screen by using user exit then after that you have add the field in main table where you will be getting these table in the userexit only, please make sure about this. And i am sure defenitly it will get updated in to the table.
    reward if useful.
    thanks
    abdulsamee.

  • How to add new line in message on my S890

    My stock keyboard in Lenovo S890 doesn't have enter key, is this normal ? How to add new line ?
    However this happened only in messages, while using whatsapp the enter key present.

    Hi,
    the fact that your question is posted in Order Management section, does the move order automatically generated by OM?
    nevertheless, i don't think you should (or allowed, in this case) to add a new line in transact move order. Transact move order only queries (not create records) the move order lines eligible to allocate and transact.
    So, I don't see why you need to add a new line in transact move order.
    You can, however, add a new line in the allocation of the lines, where for instance, you need to have half of the line allocated to one locator, and the other half to another locator
    Thanks

  • How to add New field in SMART forms.

    How to add new field in the SMART FORMS. Please know me the step.
    Please help me soon.
    Moderator message: Welcome to SCN!
    Moderator message: please search for available information/documentation, do not use a priority higher than normal (no "soon", "ASAP", "earliest" etc.).
    [Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
    [Asking Good Questions in the Forums to get Good Answers|/people/rob.burbank/blog/2010/05/12/asking-good-questions-in-the-forums-to-get-good-answers]
    Edited by: Thomas Zloch on Jun 17, 2011 12:31 PM

    How to add new field in the SMART FORMS. Please know me the step.
    Please help me soon.
    Moderator message: Welcome to SCN!
    Moderator message: please search for available information/documentation, do not use a priority higher than normal (no "soon", "ASAP", "earliest" etc.).
    [Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
    [Asking Good Questions in the Forums to get Good Answers|/people/rob.burbank/blog/2010/05/12/asking-good-questions-in-the-forums-to-get-good-answers]
    Edited by: Thomas Zloch on Jun 17, 2011 12:31 PM

Maybe you are looking for