Assigning value to the dynamic item

Hi All,
I am trying to achieve the following
1. Create a program unit that passes the block name and item name
2. Build :<BlockName>.<ItemName> and assign the value say 'Yes' / 'No' based on the condition.
3. I do not want to hard code the block name and item name.
Any ideas on how to complete this?
TIA,
Nilesh

Hello,
Use the Copy() built-in.
Francois

Similar Messages

  • How can i dynamically assign values to the tld file

    How can i dynamically assign values to the tld file

    In the tld you write for the tag handler mention the following sub tags in the attribute
    <attribute>
    <name>xyz</name>
    <required>true</required>
    <rtexprvalue>true</rtexprvalue>
    </attribute>
    import the packagejavax.servlet.jsp.tagext.DynammicAttributes;
    add the method
    public void setDynamicAttribute(String rui, String localname, Object value) throws JspException
    <Your Required task>
    Its better if you SimpleTagSupport class to be extended.

  • Assigning Value To An Application Item via JS

    Hi guys,
    I am trying to assign a value to an application item by using javascript. But I can't do this when I try to display with alert the result is empty. Do you have any idea how can I assign value to an application item by using javascript?
    else if(action=="ASSIGN")
    var moname = $(el).children("td[headers='SOURCE']").text();
    $s('F10_SELECTED_OBJ',moname);
    alert($v('F10_SELECTED_OBJ'));
    Thanks

    Hi
    >
    I am trying to assign a value to an application item by using javascript. But I can't do this when I try to display with alert the result is empty. Do you have any idea how can I assign value to an application item by using javascript?
    >
    Scope of JavaScript is the HTML DOM in the browser. The Application Items do not exist in the HTML DOM, only in the session state.
    This explains what you observer. To set the App Items using JS you have to use an AJAX call to an OnDemand Application Process that sets the Application Item using PL/SQL. Or, call a procedure over http and set the App Item in that procedure after setting the Workspace / Security Group Id.
    Regards,

  • How can i assign value to the certain field in dynmic table ?

    i have created a dynmic table .now i want to assign value to the certain field,how can i do that?
    for eg,
    <dyn_table> contains fields of  name age ,now i want assign 'jack' to this internal talbe's field name ,

    Hi,
    try this:
    FIELD-SYMBOLS: <GT_ITAB>      TYPE TABLE,
                   <GS_ITAB>,
                   <FS>, <FS1>.
    DATA: GT_DATA   TYPE REF TO DATA.
    DATA: GS_DATA   TYPE REF TO DATA.
    START-OF-SELECTION.
      CREATE DATA GT_DATA TYPE TABLE OF PA0002.
      ASSIGN GT_DATA->*   TO <GT_ITAB>.
      CREATE DATA GS_DATA    LIKE LINE OF <GT_ITAB>.
      ASSIGN GS_DATA->*      TO <GS_ITAB>.
      ASSIGN COMPONENT 'NACHN' OF STRUCTURE <GS_ITAB> TO <FS>.
      <FS> = 'Smith'.
      ASSIGN COMPONENT 'VORNA' OF STRUCTURE <GS_ITAB> TO <FS>.
      <FS> = 'Paul'.
      APPEND <GS_ITAB> TO <GT_ITAB>.
      ASSIGN COMPONENT 'NACHN' OF STRUCTURE <GS_ITAB> TO <FS>.
      <FS> = 'Jones'.
      ASSIGN COMPONENT 'VORNA' OF STRUCTURE <GS_ITAB> TO <FS>.
      <FS> = 'Martin'.
      APPEND <GS_ITAB> TO <GT_ITAB>.
      LOOP AT <GT_ITAB> INTO <GS_ITAB>.
        ASSIGN COMPONENT 'NACHN' OF STRUCTURE <GS_ITAB> TO <FS>.
        ASSIGN COMPONENT 'VORNA' OF STRUCTURE <GS_ITAB> TO <FS1>.
        WRITE: / <FS>, <FS1>.
      ENDLOOP.
    Regards, Dieter

  • Freight Calculation based on the net value of the Line item

    Hi SAP Gurus,
    I have one requirement for Freight calculation(Sales order is created through an IDOC) :
    In the idoc,we will receive a freight dollar amount - which will be the total amount of freight.(example 100)
    We will also receive sales dollar for each line item ,which is then passed to the pricing procedure, for a total amount of sales for that Sales order.
    (examples below, for a total of 1500)
    The 100  is to be posted to a freight G/L account.
    The 100 is further divided by each profit center  of the materials on the Sales order.
    The freight is split out amongst the  profit center , based on the net value of the line item.
    Freight value to be allocated = Line item value/total value of the sales order * Freight amount.
    Total of the sales order =1500
         Line item value     Freight value calculation     Profit center
    Material A:      800          800/1500*100  = 53     Profit center A
    Material B:     500          500/1500*100  = 33     Profit center B
    Material C:      200          200/1500*100  = 13     Profit center C
    Please let me know how to achieve this functionality in pricing procedure or what changes i need to make in Freight condition type.
    Thanks in advance,
    Bhakar Saha

    Were you able to resolve this issue of allocating freight costs to line items/profit centers using the net value of the line items?

  • Change Assignment Field in the Line Item

    I'm trying to change manually the Assignment field in the Line item of a FI Document but the field is not open for entry.
    In the SPRO -> Document Change Rules, Line Item settings are correct and should allow change of the field. Do you have any ideas on that problem?

    Hi
    Assigment field it system given no , the main purpose of this field is to idetify the particular line item system not allowed to chavge that one once u save the document?
    Rams

  • How can I get the value of the previous item

    Hi,
    I have a block with some records in it.
    I want to capture the value of the previous item of the cursor position
    for eg I have emp_no, and emp_name
    If I click emp_name it goes to different block ang brings up emp info. for that particular employee. but to get that I need emp_no
    I'm taking emp_name by giving
    emp_name := system.cursor_value
    how can I capture emp_no value
    Thanks in advance

    Hello,
    try this:
      name := :blk.emp_name ;
      num  := :blk.emp_no ;
      sal  := :blk.emp_sal ;
      etc...Francois

  • Incorrect value in the dynamic table.

    Hii,
          I am new to abap, i wrote a program which is showing dump  " Incorrect value in the dynamic table." .
       Error in the ABAP Application Program
       The current ABAP program "SAPLKKBL" had to be terminated because it  come across a statement that unfortunately cannot be executed.
    pls help me to solve this issue.
    REPORT  zBLOCKED_ALV.
    *tables: ekko,ekpo.
    type-pools slis.
    parameters porder like ekko-ebeln.
    data:  i_ekko type   table of ekko,
              i_ekpo type   table of ekpo,
             fieldcat type slis_t_fieldcat_alv,
             keyinfo type slis_keyinfo_alv.
      clear keyinfo.
      keyinfo-header01 = 'ebeln'.
      yinfo-item01 = 'ebeln'.
    select * from ekko into table i_ekko where ebeln = porder.
      select * from ekpo into table i_ekpo for all entries in i_ekko
        where ebeln = i_ekko-ebeln.
        CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'
          EXPORTING
            I_PROGRAM_NAME               = sy-cprog
            I_INTERNAL_TABNAME           = 'i_ekko'
            I_STRUCTURE_NAME             = 'ekko'
          CHANGING
            CT_FIELDCAT                  = fieldcat.
    refresh fieldcat.
        CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'
          EXPORTING
            I_PROGRAM_NAME               = sy-cprog
            I_INTERNAL_TABNAME           = 'i_ekpo'
            I_STRUCTURE_NAME             = 'ekpo'
          CHANGING
            CT_FIELDCAT                  = fieldcat.
    CALL FUNCTION 'REUSE_ALV_HIERSEQ_LIST_DISPLAY'
      EXPORTING
        I_CALLBACK_PROGRAM             = sy-cprog
        IT_FIELDCAT                    = fieldcat
        I_TABNAME_HEADER               = 'i_ekko'
        I_TABNAME_ITEM                 = 'i_ekpo'
        IS_KEYINFO                     = keyinfo
      TABLES
        T_OUTTAB_HEADER                = i_ekko
        T_OUTTAB_ITEM                  = i_ekpo.

    Hi,
    You have to pass 'EKKO' and 'EKPO' i.e in caps to the exporting parameter I_STRUCTURE_NAME of the function module
    'REUSE_ALV_FIELDCATALOG_MERGE'.
    I think this would work, if not pls let me know.
    Thanks,
    Radhika

  • Can we catch the dynamic item value in Apex?

    Hi All,
    In my application i am using SELECT_LIST_FROM_QUERY_XL Function. The select list will be populated based on some product group id.
    Some times the list will be 2 or 5 based on prgr id. Now how to catch the dynamic list item name. Is it possible?
    Thanks,
    Anoo..

    Not directly. You can have two items and then dynamically switch between those two items. This can lead to other issues of cause. For example if the item value should be stored in the database, you have to decide which item to store and how to do that.
    The field type itself should not be changed. There are a lot of other things that depend on that. Possible ? Yes. Advisable? No. Check the page source text to see the difference between a select item and a normal text field. Then think if you want to set all this dynamically.
    Maybe a popup list would be better suited?
    One more point: In my experience adding too many dynamic stuff onto a page will not improve the user experience, but will decrease it. So you should carefully consider if this is something. Dynamic actions are great, but they are not always the best tool for the job.

  • Very slow performance when assigning value to a form item

    Dear all,
    I have an add-on form that contains 30 text edits. I did not creat the from with screen painter but positioned them by marking each item's top and left position in the new sub.
    I have named them as 'edBox1', 'edBox2'......, 'edBox30'
    At a point I need to assign value to each edit text, I have queried the content from DB into one recordset. However, when I start to assign values to each edit text, the performance became very slow.
    my code is as follow
    me.form.items.item("edBox1").Specific.String = recordset.field.item(0).value.tostring
    me.form.items.item("edBox30").Specific.String = recordset.field.item(29).value.tostring
    I found that B1 seem to iterate each item on the form in order to find the item I specified.
    so I think I should specificy items earler.
    Now for each item I dim an object for it at new sub
    Dim oedBox1 As SAPbouiCOM.EditText
    Dim oedBox30 As SAPbouiCOM.EditText
    and while creating forms, I specificy each item to the matched object
    Then I assign values to items by
    oedBox1.String = recRetrive.Fields.Item(0).Value.ToString
    oedBox30.String = recRetrive.Fields.Item(29).Value.ToString
    However, B1 still iterates to find the item and the performance is still slow, does anyone has a better solution to this issue? please kindly advise.
    Thank you
    Alan
    Edited by: Chih-Peng Chen on Dec 17, 2007 8:42 AM

    Hi Chen,
    you can find one example under SDK samples which will guide on using datasources
    Bind the controls to dbdataource and then query the datasource.
    then update form using oForm.Update(),this will automatically fill the values in all edit boxes and it will be very fast as well
    Hope it helps you
    Regards
    Vishnu

  • Assigning values to the charecterstics in a purchase order

    Hello,
    I have to create the configuration object and assign the values to it in a purchase order.
    I am able to generate the temporary CUOBJ using FM CUXM_SET_CONFIGURATION but not able to save it to the database.
    I am using FM CUCB_CONFIGURATION_TO_DB to save the cuobj to the DB but getting a short dump.
    MESSAGE_TYPE_X
    Technical information about the message:
    Message class...... "CUIB1"
    Number.............. 699
    And hence not able to run the FM 'CUCB_CONFIGURATION_TO_DB' properly.
    Can anyone help me how do I create the cuobj, assign values to it and then save it to the purchase order...
    Any help will surely be rubarbed...
    Thanks in advance.
    Husain

    Thank you for your respond, but I have few questions:
    myText = myText.replace(/\bred\b/gi, "<font color='#ff0000'><a href='event:redClick'>$&</a></font>");
    -myText.replace: how this finction works?
    -what is this?
    /\bred\b/gi
    -it's not a link , I need a hover listener to this spesific word.
    -where do you assign the word you want to highlight? And can I assign more than one word without writing the same code over again?
    -this looks like html and I don't use any in my project, can you write this line without html?
    <font color='#ff0000'><a href='event:redClick'>$&</a></font>
    I don't understand the functionality of these line:
    var pattern:RegExp = new RegExp("\(\?\<\=\\s)" + string + "(?=[\\s|\,])", "ig");
         var result:Object = pattern.exec(text);
         while (result) {
              textField.setTextFormat(highLightFormat, result.index, result.index + string.length);
              result = pattern.exec(text);
    what is
    RegExp?
    result?
    pattern.exec?
    Sorry if these are alot of questions, I just want to understand.

  • Increase In GR value for the Line Item

    Dear Friends
    I have a Cost center PO with "text item"  ordered for Quantity 10000 PC for  an amount of 10000 USD. MIGO has been done 4/5 times where the quantity inwarded equalled the GR value.  in the month of Novembeer  the user carried out GR for a quantity of 290 PC but suddenly the GR value was higher i.e 434 USD. User cancelled the document using MBST and the Value which got cancelled is 290 usd only and not 434(which should have been).
    My query is why system behaved abnormally? There is no item change log in the PO as User has not changed the unit price for the PO. I have checked the PO history Table " EKBE" and i do not find any changes to the Value of PO during or before the period , no changes are displayed in the Table w.r.t value.
    Secondly why during cancellation system only considered the PO value not the GR value. Where should I look for  the reasons of this abnormality.
    Thanks

    this can happen if any freight or packaging condition value was present while GR but deleted or altered befire the cancellation of document.. pl check in MSEg for amount in LC and delivery costs.

  • Map default values in Header based on multiple values in the line item

    Hi
    I have a scenario in which the Header field of an IDOC should be populated with some default values based on some mixed mvt types in the line items.
    eg:
    Header -
    > Delivery type -
    > needs to be mapped to A (for X of line item 1)or B (for Y of line item 2) or C (for Z of line item 3 )
    based on line items field
    line item1---> mvt type---> X
    line item 2-->mvt type----->Y
    line item 3 -
    > mvt type -
    > Z
    mvt types doesnt necessarily have to come in that order and even the same mvt type can repeat in multiple line items.
    Can we achieve this logic in XI ?

    I think if you include removeContext, Sort, SplitByValue (on Value Change), CollapseContext to mvt type in all line items and then use ifelse condition to achieve your result.
    I will give an example of line Item1
    mvt type --->RemoveContext ->Sort>SplitByValue(on value change) --> CollapseContext
    Use the above mapping to IF function and check if it is having X, Y or Z then map the appropriate value to target field.
    Do the same for rest of the line items.

  • KO23 Object currency assigned  value not equal Line item assigned value

    Dear all:
                    I have one problem.  Some Internal Order budget  use KO23  view about Object currency assigned value not equal Standard Reprt
    S_ALR_87013019 - List: Budget/Actual/Commitments  assign value.
    I don't knew what happen ?
    So I wish someone can give me a hand. Tel me how to fix this problem.
    thank you !

    Hi Jason,
    First of all:
    The displayed account code must be translated into the internally used code ("_SYS...") when using segmentation - when not using segemntation it is just internal code = displayed code.
    The code displayed is just a sample to give you a hint in case you are already familiar with the SAP Business One application.
    Therefore the sample code does not talk about where you got e.g. the value for FormatCode from ("FormatCode" is e.g. a field in table OACT where the account name with segments is (redundantly) stored without separators).
    The user should know on which account he/she wants to book a line on; maybe you might want to give some help to the user by displaying a dialog with suitable - or preselected accounts?
    In addition I am sure you know how to assign a string value to a string property - without explicitly writing it, right?
    HTH,
    Frank

  • How to assign values to the parameter

    I have write a procedure in procedure builder like this:
    PROCEDURE "GETMCTOREPORT" (
    p_logname IN VARCHAR2,
    p_mysql IN VARCHAR2,
    p_opyear IN VARCHAR2,
    p_exrate IN VARCHAR2,
    p_flag IN OUT VARCHAR2)
    but I don't know how to run this procedure, espically how to declare a variable and then assign to last parameter, in the procedure builder environment.
    Anyone helps me,Thanks
    PL/SQL>

    Have a look at JDeveloper and it's PL/SQL development capabilities. You can write a PL/SQL procedure click run and a window will popup letting you fill values for the parameters. And you can even debug the procedure.
    For more info:
    http://otn.oracle.com/products/jdev/htdocs/database/db_overview.html

Maybe you are looking for

  • Not able to reload the data from DB using finder methods

    Hi all, <p> I am facing a weird problem while using finder methods. I am using weblogic 8.1 SP3 and entity beans are CMP with DB concurrency.DB is oracle </p> <h4>Problem Description</h4> <p> I am having one session bean which internally interacts wi

  • Display html code in a variable of a pojo failed by JSTL

    hai, my pojo contains the following code: Class Pojo{ String htmlFormat="<a href='someurl'>click</a>";  setters and getters} in my jsp displaying this pojo variable <c:out value="${htmlFormat}" /> is displaying it as text but the content is of type h

  • Overview report cost estimate (fix and variable)

    Hello anybody knows a overview report  where i can see for the current valid cost estimates per material costs splitt between fix and variable costs Alternatively it would be sufficient if this is just shown for a costing run In CK40N and all other r

  • Change Management Issue

    Dears, I am configuring CHARM in solman 7.0,I have performed configuration activities but after creating change management ticket by DSWP->Change management->Change request management I go to ticket and make it in change mode I get in option tab: The

  • Annoying spry image display problem

    xml works good but I can't figure out how to display images in a horozontal line Hi, I have a spry data set that I've created with cs4. SO the idea is I have an xml with an image field which I constrain to a particular size and turn into thumbnails a