How to create a BADI for the sceanrio

Hi abapers,
I have a scenario as follows.
I create a Transaction where in i put the details of the product and quantity for a particular project's site. The amount gets calculated based on the products  unit value and its displayed in net value field. Now the user saves the transaction and a number gets generated. If the net value amount is less than 500 then the user can approve , if its greater than 501 and less than 1500 then a mail should be generated to his superior who is able to approve and ifs amount is greater than 1501 then a mail should be generated to the top of hierarchy who should approve it.
Now the real challenge is if the same project card  has more than 1  new request and the amount is less than 500 the user should not be able to approve  instead it should generate a mail to his hierarchy for approval  since  the site has already been exceeded its limit of approval. bcoz earlier 500 and current 400 which will make it to greater than 500.similarly for the hiearchy.How do i go about  it.
Now i want to create a BADI  on the save event of transaction to check the net value amount as well as check for earlier amounts saved for the particular site.
Any help will be appreciated.
Regards,
Navin .

hai navin
r u using ECC 6.0 or 4.7 if 4.7 u can create badi defintiion directly form se18 transaction
and define the interface and its methods , once u define them activate them
and to use in ur code u create an instance of ur badi name
and then use
                 cl_exithandler=>get_instance  method in instance name parameter just pass ur badi name and this will create a badi defintion in ur code, and an oen can implement it
if u r usign ecc6.0 then u can either create new badis usign enhancments or classical badis
for clasical badis just go to menu  utilites and create classical badis and follw the sam eprocedure
regards
m.a

Similar Messages

  • How to create a validation for the project coding mask

    Hi,
    Would just like to ask how to create a validation for the project coding mask wherein the WBS elements hierarchy will be checked against the template saved. For example,
    project coding mask is XXXX-XXXXX-XX-X-X-X-00-X
    mother WBS should be XXXX-XXXXX-X and lower level WBS would be XXXX-XXXXX-XX.
    The validation should not allow a mother WBS to be XXXX-XXXXX-XX.
    How can we go about this?

    Hi Jacquiline Bersamin,
    You can use validation with the combination of the level and the coding mask.
    In the validation:
    Pre requisite: WBS level = 1
    Validation: Prps-posid = prps-posid :1-12:
    Message : Error
    If required you can give the parameters for your detail error message.
    Please let me know if this does not work.
    Thanks
    Regards
    Srinivasan Desingh

  • How to create a password for the pdf file

    In Adore Acrobat XI, how to create a password for the file? The help states going to Tools Menu and clicking on Protection tab - but there is no such option. In the file - properties - security screen, it shows the security details but does not allow to edit it.

    I think you may be mixing up two different products: Adobe Reader (free), and Acrobat ($$).

  • HOW TO CREATE SEVERAL folder for the generation and READING FILE

    HOW TO CREATE SEVERAL folder for the generation and READING FILE WITH THE COMMAND utl_File.
    please give an example to create 3 folders or directories ...
    I appreciate your attention ...
    Reynel Martinez Salazar

    I hope this link help you.
    [http://www.adp-gmbh.ch/ora/sql/create_directory.html]
    create or replace directory exp_dir as '/tmp';
    grant read, write on directory exp_dir to eygle;
    SQL> create or replace directory UTL_FILE_DIR as '/opt/oracle/utl_file';
    Directory created.
    SQL> declare
      2    fhandle utl_file.file_type;
      3  begin
      4    fhandle := utl_file.fopen('UTL_FILE_DIR', 'example.txt', 'w');
      5    utl_file.put_line(fhandle , 'eygle test write one');
      6    utl_file.put_line(fhandle , 'eygle test write two');
      7    utl_file.fclose(fhandle);
      8  end;
      9  /
    PL/SQL procedure successfully completed.
    SQL> !
    [oracle@jumper 9.2.0]$ more /opt/oracle/utl_file/example.txt
    eygle test write one
    eygle test write two
    [oracle@jumper 9.2.0]$
    SQL> declare
      2    fhandle   utl_file.file_type;
      3    fp_buffer varchar2(4000);
      4  begin
      5    fhandle := utl_file.fopen ('UTL_FILE_DIR','example.txt', 'R');
      6 
      7    utl_file.get_line (fhandle , fp_buffer );
      8    dbms_output.put_line(fp_buffer );
      9    utl_file.get_line (fhandle , fp_buffer );
    10    dbms_output.put_line(fp_buffer );
    11    utl_file.fclose(fhandle);
    12  end;
    13  /
    eygle test write one
    eygle test write two
    PL/SQL procedure successfully completed.
    SQL> select * from dba_directories;
    OWNER                          DIRECTORY_NAME                 DIRECTORY_PATH
    SYS                            UTL_FILE_DIR                   /opt/oracle/utl_file
    SYS                            BDUMP_DIR                      /opt/oracle/admin/conner/bdump
    SYS                            EXP_DIR                        /opt/oracle/utl_file
    SQL> drop directory exp_dir;
    Directory dropped
    SQL> select * from dba_directories;
    OWNER                          DIRECTORY_NAME                 DIRECTORY_PATH
    SYS                            UTL_FILE_DIR                   /opt/oracle/utl_file
    SYS                            BDUMP_DIR                      /opt/oracle/admin/conner/bdumpRegards salim.
    Edited by: Salim Chelabi on Apr 4, 2009 4:33 PM

  • How to create a playlist for the movies I have?

    Hope someone can help me here. How do you set the movies to play continuously? I can't seem to create a playlist for the movies. You can create playlist for podcast videos and musics but how do you creat playlist for the 3 movies I have got on my iphone?
    Any help will be greatly appreciated.

    Not exactly true. As absurd as it sounds, if you have just one music track in your playlist, then you can select it from the Playlists section on the iPhone and play your videos, movies etc. one after the other.
    I have created a completely empty music track in Garageband which I drag onto the end of each and every video playlist I create. An ugly solution, but it works.
    You have to remember to check the playlist in both the Video and Music sections in iTunes->Devices->Your iPhone.

  • How to create search path for the file on the desktop..

    hello experts..
          I have used gui_upload module to upload the data from flatfile to the internal table, in that how can i create search path for the file selection in the selection screen, also please help me the code to update the ztable.
    thanks

    HI
      If iam not wrong you want to select a file from a location that you don't know so if this is ur problem then use the function module
    F4_FILENAME
    this FM helps to locate and select the desired file from the system.
    Sample code that you can check is
    How to get windows filename
    PARAMETERS: lv_file LIKE rlgrap-filename.
    Method 1
        CALL FUNCTION u2019KD_GET_FILENAME_ON_F4u2019
        EXPORTING
        MASK = u2019,.txt,.*u2019
        STATIC = u2019Xu2019
        CHANGING
        FILE_NAME = LV_FILE.
    Method 2
    CALL FUNCTION u2019F4_FILENAMEu2019
    EXPORTING
             program_name = syst-cprog
             dynpro_number = syst-dynnr
             field_name  = u2019 u2019
         IMPORTING
             file_name   = LV_FILE.
    Regards
    Pavan

  • How to create an Invoice for the sales order using the T-Code VF01

    Hello Experts,
    How to create an Invoice for a sales order using the T-Code VF01?
    Thanks in advace,
    Suma

    hi,
    Make the following settings-
    1. Create sales document and billing type
    2. assign billing type in sales document type config VOV8
    3. Activate itemcategory as sales order related billing
    4. Maintain copy control header and item level between sales order and billing
    5. Maintain pricing procedure for sales order and billing
    6. Define Output procedure in case to print invoice
    Regards
    Goutham

  • How to create a matchcode for the list of Customers "Group key" KNA1-KONZS

    Hi All,
    with reference to the creation of "Group key" KNA1-KONZS for Customers,
    I'd like to know if is possible to create a matchcode for the list of Customers "Group key" created.
    Thanks
    Gandalf

    Hi
    MAINTAIN THE GROUP KEY IN GENERAL DATA ---CONTROL DATA SCREEN
    If the customer or the vendor belongs to a group, you can enter a group
    key here. The group key is freely assignable.
    If you create a matchcode using this group key, group evaluations are
    possible.
    KNA1-KONZS
    Cya
    udayakumar

  • How to create clean text for the web in Photoshop/Illustrator

    I am puzzled to death on how in the world to get clean text for the web in Photoshop/Illustrator, particularly white text. I want my text to turn out exactly like the text at this website: thepainteddoor.org
    If you scroll down to the bottom of that page, notice the titles "Featured Media", "Social Networking", and "Contact Information". They are all .gif images. I have tried to replicate what these images look like for about 3 hours now to no avail. Can anyone tell me how to do this? It just looks like a simple outline or drop shadow, but I can't get it to show up like that. If someone could help me replicate that effect with text (aka make it show up clean as an image), I would graciously give them money through PayPal*.
    * = I will only give cash if it will replicate it exactly (and I mean exactly)..and it won't be too much..I'm a poor college student. :-P
    Thanks in advance!
    Thomas

    You would do it the way I created it:
    Select the Text tool in Photoshop and set the font and parameters as I have listed.  Then enter whatever text you like.  It will be rendered over the top of the lower layers you may have in the document.  Save as an image of the appropriate type and you're there.
    Note that "lower layers you may have in the document" could conceivably be none at all (i.e., you render the text over a transparent document).  You could imagine saving that as a .png with transparency and get light text in an image that could then be put over the top of anything else.  The alpha mixing will see to it that the edges smoothly blend with the background.  I haven't actually tried this (I usually do try my own suggestions) because of lack of time right now.
    -Noel
    Edit:  Markerline and I seem to be on the same crystal-controlled wavelength. 

  • How to create a service for the OHS (Apache 2.0) on Windows?

    I've downloaded the Oracle HTTP Server (Apache 2.0) (10.1.3.3.0).
    It works also fine with DB 10gR2 and APEX.
    But how do I create a windows service for the opmnctl.exe?
    Thanks
    Ralph

    I've downloaded the Oracle HTTP Server (Apache 2.0) (10.1.3.3.0).
    It works also fine with DB 10gR2 and APEX.
    But how do I create a windows service for the opmnctl.exe?
    Thanks
    Ralph

  • How to create Search help for the field /SAPSLL/PRGEN-ATTR20V

    Hi ,
    I need to add a search help for the field /SAPSLL/PRGEN-ATTR20V and their is a chk table used for this field is /SAPSLL/TCOATV20.
    In this table /SAPSLL/TCOATV20-ATTRV20V is a Primary key field.
    How can I add search help for this field?
    Any suggestions will be appreciated!
    Regards,
    Kittu

    HI,
    Fixed on my own..
    I am closing this thread!
    Thank you!
    Kittu

  • How to create a file for the file format PDF/A?

    I want to create a file,which conform to the standard  PDF/A.
    when i use InDesign to create a pdf file and export it,i find the file format only support PDF/X,
    but i can't find any menu for PDF/A.
    who can help me?
    thank you !

    File>Print
    Choose Adobe PDF as your printer
    Go to Setup
    Go to preferences
    Choose the standard
    Make sure the rest of your settings are correct for the page size etc.
    It's a big screenshot so I've linked instead of posting here.
    Sorry had to blur out some PDF settings for privacy reasons
    http://img339.imageshack.us/img339/6103/37345539.png

  • How to creat business process for the user?

    Hi
    when i use to create message in notif_creat i am getting error message Business partner Neni_SM does not exist
    please help me
    Regards
    Neni

    Problem : when i use to create message in notif_create i am getting error message Business Partner Neni_sm cannot be the reporter
    Admin_sm(Key user)
    Neni_sm(sub user)
    Neni_sm1(sub user)
    Step Followed
    1L.ogon to System Admin_sm go to Code:BP
    2.When I use to select Display in BP role as “Employee”
    3 required Data filled in “address tab”
    4.In Identification tab  I can only c subtab
    Employee data:
             Personnel number
             User Name:neni_sm
    5.When I use to select Display in BP role as “Employee in cfloders”
    Employee data:
             Personnel number
             User Name :neni_sm
    Identification number
              External BP number :<SID>< installation number of the system>only this 2 r possible
    Now problem is  When I  logon to Neni_sm(sub user)system  create message in notif_creat i am getting error message <b>Business Partner Neni_sm cannot be the <u>reporter</u></b>
    <b>Requirement</b>: I have to give access to create message for the following user Neni_sm(sub user)
    Neni_sm1(sub user) 
    Where I have already  created user: neni_sm and also   roles
         SAP_SUPPDESK_ADMIN
         SAP_SUPPDESK_CREATE
         SAP_SUPPDESK_DISPLAY
         SAP_SUPPDESK_PROCESS
    Please help me
    Regards
    Neni

  • How to create a instance for the method

    it is showing me dump error for the call method
    data: i_tab type /SCMB/DM_ORDER_TAB,
          grid1  TYPE REF TO /SCA/CL_SVORDER .
    CALL METHOD grid1->READ_BY_IDS
      EXPORTING
       IS_CTRL      =
        IV_ORTYPE    = gt_po_detl-ortype
       IV_LOCKFLG   = /SCMB/CL_C_ORDER=>GC_FALSE
       IV_NOADDRESS = /SCMB/CL_C_ORDER=>GC_FALSE
       IV_MAPID     = /SCMB/CL_C_ORDER=>GC_FALSE
       IV_DUEQUAN   = /SCMB/CL_C_ORDER=>GC_FALSE
        IT_ORDERID   = itab_orderid
      IMPORTING
        ET_ORDERS    = i_tab
       ET_PROT      =
    u r attempting to use a null object reference access a component (variable 'GRID!")
    an object reference must point to an object (an instance of  a class ) before it can be used to acess a component either the reference was never set or it was set to null using the clear statement

    sridhar loganathan,
    A ABAP Class is just a definition of fields/variables called attributes and routines (like in standard ABAP forms and functions) called methods. Also you can have events, don't care about before necessary.
    The definition itself is just a blueprint. Nothing exists, nothing can be used before you create an instance for this definition.
    DATA: grid1 TYPE REF TO /SCA/CL_SVORDER creates a 'handler' for ( to be created) instances of the class.
    The statement CREATE OBJECT grid1 creates an instance of the class as defined in the 'blueprint' and assigns the reference to this instance (with all methods, attributes and events) to reference field grid1.
    In 999 of 1000 cases SAP creates just one object of a class. In those cases the definition of classes and uses of object oriented programming is more or less obsolete.
    Anyway: Just keep in mind that you can not uses attributes and methods of the class directly (blueprint!) but only of the instance created.
    An Exception to be noted are so-called Static attributes and methods where an instance is not required. Example ABAP_CHAR_UTILITIES=>HORIZONTAL_TAB gives the character for horizontal tab regardless of platform and char encoding (unicode!). Class ABAP_CHAR_UTILITIES defines static attribute HORIZONTAL_TAB - no instances necessary because this will never change in a given system.
    Hope this sheds some light on it
    Regards,
    Clemens

  • How to create a spool for the billing document

    Hi all
    In the ALV report i am getting the
    List of billing documents
    on the selection of any billinfg document
    i wanted to create the spool of the same
    is there any way for the same .
    please help.

    Hi
    check with the fun module to get the SPOOL ID of the billing doc
    RSPO_RW_SPOOLJOB_PARAMS
    Reward points if useful
    Regards
    Anji

Maybe you are looking for