Losing values in XKOMV structure

Dear All,
Please help it's very urgent.
I have created a routine in VOFM under formulas-Condition Value. After populating value XKOMV-KBETR the value is replaced by the standard structure RETTKOMV.
Because of this my calculated value for KBETR is replacing with RETTKOMV-KBETR value.
This is happening after comming out of the routine.
Please do needful it's very urgent.
Thanks
Hreddy

Hi,
  I think the formula is not configured in the pricing procedure..That is the reason why it is getting replaced..
  Check this code in the include LV61AA43..The flag wertformel will be set if the routine is configured..
    IF xkomv-kofrm NE 0.                                     
    <b>wertformel = 'X'.</b>                                      
    xkwert = xkomv-kwert.                                  
    frm_kondi_wert-nr = xkomv-kofrm.                       
    PERFORM (frm_kondi_wert) IN PROGRAM saplv61a IF FOUND. 
    xkomv-kwert = xkwert.                                  
  ENDIF.                                                   
  If the flag is set the if condition that you mentioned will fail and it will not overwrite..
if xkomv-kofrm ne 0 and <b>wertformel eq space</b> and komp-kposn ne 0.
   rettkomv = xkomv.                                            
   xkwert   = xkomv-kwert.                                      
   frm_kondi_wert-nr = xkomv-kofrm.                             
   perform (frm_kondi_wert) in program saplv61a if found.       
   xkomv    = rettkomv.                                         
endif.                                                         
  Check in my previous reply for the formula in the pricing procedure..
Thanks,
Naren
Message was edited by: Narendran Muthukumaran

Similar Messages

  • How to set values to the structure containing a node with cardinality 0..n

    Hello.
    I 'm trying to set values for the node with cardinality 0..n. The node type is "Fields".
    <xsd:complexType name="Field">
       <xsd:sequence>
          <xsd:element name="fieldCode" type="xsd:string"></xsd:element>
          <xsd:element name="displayValue" type="xsd:string" minOccurs="0"></xsd:element>
       </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="Fields">
       <xsd:sequence>
          <xsd:element name="field" type="tns:Field" minOccurs="0" maxOccurs="unbounded"></xsd:element>
       </xsd:sequence>
    </xsd:complexType>
    I  need to set several values for the element "fieldCode" but it has cardinality 0..1 and BPM does not allow it but I did not find any option about how to set values for the structure of type "Fields". Could you help me?
    Best regards,
    Timur Semenchuk

    Hi Marcus,
    If there is no way you could change the cardinality of the node, and thus it can contain 0..n items, I think you should create-and-add a new element programmatically.
    Since the collection can contain zero elements, I would add a 'new' button, which upon clicking adds one new element via:
    IYourNodeElement yourNodeElem = wdContext.nodeYourNode().createYourNodeElement();
    wdContext.nodeYourNode().addElement(yourNodeElem);
    Hope this explains a bit!
    Best,
    Robin van het Hof

  • Assign values to bapi structure dynamically

    Hi,
    I have to use the BAPI, BAPI_MATERIAL_SAVEDATA to extend the material to different plant specific views. I have to use the structure BAPI_MARC and other structures in order to do this. But the values to be passed to the structure BAPI_MARC are not fixed. These values will be maintained in a custom table against the structure name and field name for a particular plant.
    In the program I have to extract the structure name and field name for a corresponding plant from custom table and fill the corresponding value in BAPI structure BAPI_MARC.
    Now, internal table in the program is having these details.
    How can I fill the bapi structure BAPI_MARC based on this information.
    For example, if in custom table, value 0001 is maintained against the field PUR_GROUP, I have to fill the field PUR_GROUP in strcutre BAPI_MARC with 0001.
    Hope I am clear in explaining the problem. Please let me know how to aciheve this?
    Best Regards,
    Kumar.

    Hi,
    I have tried to implement that in a sample program first. Please have a look at the code below.
    DATA: BEGIN OF line,
            col1 TYPE i,
            col2 TYPE i,
            col3 TYPE i,
          END OF line.
    DATA comp(4) TYPE c VALUE 'COL3'.
    FIELD-SYMBOLS: <f1> TYPE ANY, <f3> TYPE ANY.
    ASSIGN line TO <f1>.
    ASSIGN COMPONENT comp OF STRUCTURE <f1> TO <f3>.
    IF <f3> IS ASSIGNED.
    ENDIF.
    I checked in the debugging mode and the value of <f3> in debugging mode is 0, but not line-col3.
    Best Regards,
    Kumar

  • To pass the values in repetitive structures any function module

    hi all,
          Is there any function module to pass the values in repetitive structures like infotype 0041(Date spcification). I heard there is a function module, so any of you can tell that function module.
    thanks,
    sekhar.

    Hi Chandra,
    If your question is to find a date for a given dar value in IT 0041 then this is the sol:
    Yes there is a function Module for IT0041, HR_ECM_READ_IT0041_DATE_TYPE
    eg: 
    INFOTYPES: p0041.
    DATA: lv_msg TYPE REF TO if_hrpa_message_handler,
              lv_date TYPE D.
    GET pernr.
    CLEAR: lv_date.
        CALL FUNCTION 'HR_ECM_READ_IT0041_DATE_TYPE'
          EXPORTING
            datar           = 'U2'       " specify the value of the dar value, for which u have to find date
            p0041           = p0041
            message_handler = lv_msg
          IMPORTING
            date            = lv_date.
    For the dar value U2, lv_date will have the corresponding date.
    Hope this will clear your doubt.
    Thanks,
    Kishore

  • Show values of a structure dinamically

    Hi,
    I'm trying to show the content of fields of a structure dinamically, that is show the content of the fields without knowing how many fields or the name of them, only the name of the structure.
    For the time being I'm only able to get the field' names of the structure. But how can I get the values of these fields?
    thanks in advance
    REPORT zlan03_campostype .
    with this code I get horalunes, hormartes and so on
    what I want to get is 3:00, 5:00, that is the values
    of the structure
    TYPES:
    BEGIN OF my_struct,
       horalunes(5),
       horamartes(5),
       horamiercoles(5),
       horajueves(5),
       horaviernes(5),
    END OF my_struct.
    DATA:
    my_data TYPE my_struct,
    descr_ref TYPE REF TO cl_abap_structdescr.
    FIELD-SYMBOLS:
    <comp_wa> TYPE abap_compdescr.
    START-OF-SELECTION.
      my_data-horalunes = '3:00'.
      my_data-horamartes = '5:00'.
      my_data-horamiercoles = '13:00'.
      my_data-horajueves = '12:00'.
      my_data-horaviernes = '8:00'.
      descr_ref ?= cl_abap_typedescr=>describe_by_data( my_data ).
      LOOP AT descr_ref->components ASSIGNING <comp_wa>.
        WRITE: / <comp_wa>-name.
      ENDLOOP.

    Hi Javier,
    look:
    field-symbols <f>.
      DO.
        ASSIGN COMPONENT sy-index OF STRUCTURE my_data TO <f>.
        IF sy-subrc <> 0.
          EXIT.
        ENDIF.
        WRITE: / <f>.
    enddo.
    regards Andreas

  • Fetching value from deep structure

    Hi All,
    I need to take value from deep structure into a variable.
    IS_DESDLVRY_NOTIF-DELIVERY-ITEM[1]-PURCHASE_ORDER_REFERENCE-ID is that structure.
    Value is available in debugger.
    But in editor gives syntax error- item[1] doesnt exist,Item exist.
    If i delete [1] from item i wont get value.
    can you guide how to resolve error?
    Thanks.
    Edited by: sanj_dell on Jun 17, 2011 8:20 AM

    Hi,
    you have to read table IS_DESDLVRY_NOTIF-DELIVERY-ITEM index 1 into a matching structure!
    Regards,
    Klaus

  • How to pass values in dynamic structure and then dynamic table

    Hi,
    we have a Z structure in se11 holding 10 fields. But at run time i need to create a dynamic table with more than 10 records.
    I am able to create the structure and corresponding internal table. Now the issue is i have to populate this dynamic structure with some values and then append it to dynamic internal table. Since the dynamic  table type is any its not allowing an index operation like modify etc etc.
    Could anyone help me in passing the values . I have searched in SDN . everyone created a dynamic table and then populated it values from some standard or custom tables.Then assigning the component of structure  and displaying the output. but in my situation i have no such values stored in any tables. i populate values based on certain calculation.

    Hi Friends,
    This is the piece of code.After creating dynamic work area and dynamic table what i should do?
    TYPES: BEGIN OF STR,
    ID TYPE I,
    NAME(30) TYPE C,
    END OF STR.
    data: v_lines type i.
    STR_TYPE ?= CL_ABAP_TYPEDESCR=>DESCRIBE_BY_NAME( 'STR' ).
    STR_COMP = STR_TYPE->GET_COMPONENTS( ).
    APPEND LINES OF STR_COMP TO COMP_TAB.
    COMP-NAME = 'NAME1'.
    COMP-TYPE = CL_ABAP_ELEMDESCR=>GET_STRING(  ).
    APPEND COMP TO COMP_TAB.
    COMP-NAME = 'VALUE1'.
    COMP-TYPE = CL_ABAP_ELEMDESCR=>GET_STRING( ).
    APPEND COMP TO COMP_TAB.
    COMP-NAME = 'NAME2'.
    COMP-TYPE = CL_ABAP_ELEMDESCR=>GET_STRING( ).
    APPEND COMP TO COMP_TAB.
    COMP-NAME = 'VALUE2'.
    COMP-TYPE = CL_ABAP_ELEMDESCR=>GET_STRING( ).
    APPEND COMP TO COMP_TAB.
    COMP-NAME = 'NAME3'.
    COMP-TYPE = CL_ABAP_ELEMDESCR=>GET_STRING( ).
    APPEND COMP TO COMP_TAB.
    COMP-NAME = 'VALUE3'.
    COMP-TYPE = CL_ABAP_ELEMDESCR=>GET_STRING( ).
    APPEND COMP TO COMP_TAB.
    NEW_STR = CL_ABAP_STRUCTDESCR=>CREATE( COMP_TAB ).
    NEW_TAB = CL_ABAP_TABLEDESCR=>CREATE(
    P_LINE_TYPE = NEW_STR
    P_TABLE_KIND = CL_ABAP_TABLEDESCR=>TABLEKIND_STD
    P_UNIQUE = ABAP_FALSE ).
    CREATE DATA DREF TYPE HANDLE NEW_TAB.
    CREATE DATA DREF1 TYPE HANDLE NEW_str.

  • How to check the value of the structure component at run time

    Dear Friends,
    Kindly, through some idea for the below query:
    Step 1: I have a structure name as STRUCT with components COMP1, COMP2, COMP3,......, COMP99. At run time in this structure few components may have values and few may not have.
    Step 2: Now I have a variable of type char name as LV_CHAR, at run time this variable may have value as any of the structure components given in the above step such as COMP1 or COMP2 or .....or COMP99.
    Step 3: Let us assume the variable LV_CHAR have value COMP11 and now I need to check whether the strucutre componet STRUCT-COMP11 is initial or not using this variable.
    Could you please give me the steps what needs to be done to handle it.
    Thanks & regards,
    Mallikarjuna M.

    PatanGova wrote:
    Hi,
    Can someone help me out to divide a Hexadecimal number say"ABCD" and display 
    1) each value of hexadecimal number like 'A','B','C','D' in separate indicators and
    2)each value of hexadecimal number like 'A','B','C','D' into their respective decimal number and to show in separate indicators.
    Thanks.
    That has absolutely nothing to do this thread.  Start a new thread.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • How To fetch the Value of nested structure returned by RFC in c# application.

    Hello ,
    i am new to C#,i have rfc that return data from SAP system as Nested structure but when i fetching that data using
    IrfcTable table = rfc.getTable("exporting_parameter");       // et_customer
    it return's only first inner structure only .
    for example my exporting internal table for rfc is
    "et_customer" that contain sub structure as follow
              gen_data
               bank data
               tax data
    it return only value inside gen_data only.
    how to get entire data

    Hi,
    I am using Java JCO but I can see in the java doc that JCoTable have a Method
    getTable
    Check and see if you have it in .net
    Regards.

  • Selecting Field Values in a Structure

    Hi,
    I would like to seek help in selecting field values of structures.
    Here's the scenario. I am currently retrieving records and I need to filter the status.
    When I pressed F1 on the status field, the screen-field is VTGFHAPO-XBEWEBE.  VTGFHAPO is a structure. So, SQL statement is not possible.
    How do I filter the status of the record?
    For example, I will only retireve records with "OK".
    VTGFHAPO-XBEWEBE  = "OK".
    Thanks in advance for the replies.

    Goldust,
      VTBFHAPO---table
    this is added in structure VTGFHAPO field  "INCLUDE double click on it...
    Don't forget to reward if useful....

  • Passing values between event structure cases

    Hello everybody,
    I have a question concerning the event structure  - how to pass values (let's say a string / the state of a boolean control / the value of a numeric control value / an array of numeric values) between event cases ?
    There seem to be 2 situations here  :
    - when you need to pass the value of the control that triggers an event;
    - when you need to pass the value of a control which is modified in an event case.
    I have read the documentation but i still do not understand very clearly how to do this. Maybe you can point me in the right direction (maybe some threads on the forum that i have missed).
    Thank you very much !!
    (KUDOS for everyone who is interested in this )

    AndreiN2014 wrote:
    - when you need to pass the value of the control that triggers an event;
    - when you need to pass the value of a control which is modified in an event case.
    The first question isn't worded very well.  What exactly are you looking to do?  Are you looking for an event that specifically relates to that control?  If so, just drop it inside of the event and wire it.  Are you looking to trigger multiple events from the same control?  Ie, you hit the control, event1 is triggered which then triggers event2 ... ?  If so, you might consider taking a look at a different architecture.  I can think of very few cases where I'd prefer do this over something like having the button trigger a state and using the state machine architecture. 
    Others have pointed out the Shift Register.  This is the typical way to pass values between one iteration of a loop to another.  We can assume you have some sort of loop outside of the event structure to make it run a second time.  Put a shift register on this loop and the value wired into it will pass each iteration.  But, if it's just a random control, you can also just leave that outside of the event structure and wire it in as well.  This will provide the new value to the next occurrence of the event structure.
    You really need to define your problem before trying to solve it.

  • Pick first value from source structure out of multiple satisfying condition

    Hi PI Experts,
    I have mapping situation as follows. Looking for best way to achieve this.
    I have source structure
    Src Header
       Src Line ITems ( 1.. N)
             Line Field 1
            Src Details records ( 1....N)
                  Field 1
                  Field 2
    My Target stucture is
    Target (1.. N)  ( Cardinality same as the Src Details records)
    Line Field1
    Field 1  
    Field 2  ( This is should field2 of the first Src detail records which matches the condition based on field 1)
    From the source message  I want to repeat the field 2 in the target from that source record which matches the condition.
    e.g if Field1 =  PR00 then Copy of the values of records field 2 in the all the output target records.
    I was thinking of useOneOfMany but the issue is my source i can have multiple records which may satisfy the condition but i want only the first one which is satisfying condition from the source records to be output in targe.
    Thanks,
    Mahesh

    Hello,
    Use Collapse Context & SplitByValues like this
    Field2collapseContext-SplitByValue---Target Field
    Set the context of field to one level Up
    Regards

  • Updating values in standard Structure

    Hi Everyone...
    How can i edit the values in a standard structure ....
    i have edited the value in standard table ANEP ( field nafab) ...
    but i want to change the values in structure FIAA_AW01_TRANS ...
    hw can i do that?
    Regards,
    Phani

    Hi Phani,
    Try the following sample code.
    loop at FIAA_AW01_TRANS.
      FIAA_AW01_TRANS-fieldX = 'SAMPLE'.
      modify FIAA_AW01_TRANS.
    endloop.
    lets assume that theres a field fieldX in the structure FIAA_AW01_TRANS.
    The value SAMPLE will be transferred to the structure at runtime.

  • Value of KNVV structure is not changing

    I am working in customer exit EXIT_SAPMF02D_001 of customer master in include program ZXF04U01
    Here, I want to update the 1 field of KNVV table. So I am changing the structure I_KNVV based on condition but as soon as I leave the form,
    it gets the orignal value of KNVV field.
    Example :
    KNVV-FLD1 = '500001'
    Now I am using  EXIT_SAPMF02D_001 - include program ZXF04U01 and I am getting  '500001' as I_KNVV-FLD1.
    So If I change KNVV-FLD1 = '500002' and continue process, It still gives me KNVV-FLD1 = '500001'.
    How can I change the value in ZXF04U01? I tried with ASSIGN COMPONENT but its not working. Is there anything special required for ASSIGN COMPONENT?
    REgards,
    RH

    Hello,
    This is not the right Customer exit to change KNVV structure,in this KNVV structure is only import parameter thats why it is clearing the knvv value as and when you come out of this. try another exit wchich has KNVV as changing parameter or in Table parameter.
    Thanks and Regards,
    Muralidhar.

  • Finding the average value of related structure keys

    Issue:
    I have a form structure which I need to find the value
    averages of all the *AGE keys, *MINORS keys, and *ADULTS keys.
    Here's my example form structure, after using
    structkeyarray() of coarse:
    1 RES_ROOM2_MINOR3_AGE
    2 RES_ROOM1_MINORS
    3 RES_ROOM2_MINOR1_AGE
    4 RES_ROOM1_MINOR2_AGE
    5 RES_ROOM3_MINOR1_AGE
    6 RES_ROOM2_MINORS
    7 RES_ROOM3_MINOR2_AGE
    8 RES_ROOM3_ADULTS
    9 RES_ROOM3_MINORS
    10 RES_ROOM1_ADULTS
    11 RES_ROOM2_ADULTS
    12 RES_ROOM1_MINOR1_AGE
    13 RES_ROOM2_MINOR2_AGE
    Question:
    How should I AT LEAST go about pulling out each set of keys
    so i can procede to find the mean?

    Such as...
    cfset keys = structkeylist (form)
    - cfloop index='x' list='keys'
    - - cfif x contains AGE/MINORS/ADULTS blah
    - - cfset blah
    - /cfloop
    I guess that should definitely work. Simple no less. I got
    caught up
    looking for a special function to run through the structure.
    Thanks for
    shaking my head up, and sending me on my way. ;-)
    That's the idea. If you care, you can use the collection form
    of the
    <cfloop...> tag. Eliminates the need to pull out the
    list of keys
    separately.
    <cfloop collection="#form#" item="field">
    <cfif field contains "AGE|MINORS|ADULTS|Ect">
    process
    </cfif>
    </cfloop>

Maybe you are looking for

  • 10.4 to 10.4.11 Combo Update (PPC) Issues - Will Not Sleep, Etc.

    I've been running Panther 10.3.9 successfully for a long time. There are a few programs I'd like to use that require Tiger and I realized that Tiger retail disks were getting hard to come by and expensive, so I decided to buy one when I found it for

  • JMS Connectivity problem

    Hi, On one of our production deployments using Weblogic 10.3.0, we are getting the following exception when trying to connect to a JMS queue on one of the managed server. We are able to access the queues on other managed servers(there are 4 managed s

  • Using activex control in forms 6i

    hi all, I want to use activex control in my form. (e.g Spreadsheet.11) . how to set the cell property (value,colour,border etc..) i have created activex control in form and imported ole libraries, run time i am able to see the control .Ii want to set

  • Time Machine and partition on external drive

    Planning to buy a big external drive, but, is it possible to partition the external drive and make TM work on one ?

  • Checkbox in sapscript

    Hi all, I need to print a checkbox in my sapscript. The line in sapscript I would have is: 5    blalba         yes  <- here my checkbox Hi have uploaded a bmp file with a checkbox, but with this command: /:  BITMAP 'SQUARE3' OBJECT GRAPHICS ID BMAP T