Want to create a type at runtime

Hi all ,
I am trying to create a type at run time within my scheme by making use of a table loop.
[code]
Report test_data.
data :
    llv_imp type table of RSIMP,
    gt_imp_par type string occurs 0.
Field-Symbols :
    <fs_imp_par> like RSIMP,
    <fs_struct> type string.
Form inst_par_types
  Changing
  lv_imp like llv_imp
  lt_imp_par like gt_imp_par.
Data :
    lv_str(72)  type c ,
    lv_line     type I ,
    lv_delim    type C value ',' .
Describe table lv_imp lines lv_line.
Loop at lv_imp assigning <fs_imp_par>.
    if sy-tabix = lv_line.
       lv_delim = '.'.
    endif.
      if <fs_imp_par>-default is not initial.
        concatenate <fs_imp_par>-parameter 'TYPE' <fs_imp_par>-typ
        'VALUE' <fs_imp_par>-default lv_delim into
        lv_str SEPARATED BY space.
      else.
        concatenate <fs_imp_par>-parameter 'TYPE' <fs_imp_par>-typ
        lv_delim into lv_str SEPARATED BY space.
      endif.
  append lv_str to lt_imp_par.
  clear lv_str.
endloop.
Types :
        Begin of l_tabname ,
           <b><i>{T$lt_imp_par$$$&lt_imp_par&$$}</i></b>
        End of l_tabname.
EndForm.
[/code]
But when i instantiate this scheme it dumps as the highlighted line creates 2 different definitions of same variable lt_imp_par (1 as var & another one as table).
What shall I do to get the solution?

Please do not post multiple treads for the same question.
Please refer to other thread.
want to create an internal table at runtime
Regards,
Rich Heilman

Similar Messages

  • How to create a type table in designer 9i

    Hi
    In our company we use designer 9i. I want to create a type table using designer. Is it possible? I have a requirement where i need to create a type table and use in creating a view through designer.
    Create or replace type varchar2_ntt as table of varchar2(4000);
    [\pre]
    Please suggest.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

    Hi
    Here I am giving the step by step process.
    1. select the container in which container you are going to create the type.
    2.Go to tools then design editor and expand the container. There you will find oracle collection types. there we have to create a new one by clicking the + button on the left side.
    3. Give the name of the new collection type.
    4. And in the collection of tab, let it be scalar, give the scalar data type,and the size and click finish.
    5. then right click on that object and give generate. there you select theDDL files only and the give the path where the scripts have to go.
    This the process.
    Thanks,
    raju

  • Unable to create wage types in It0015 for Zambia

    Hi Friends,
    I want to create Wage types in IT0015 - Additional Payments for Zambia. But I am unable to find any model wage types which can be copied to create the custome wage type for country grouping ZM - Zambia.
    I also tried to copy the wage typse by using the functionality "copy between country groupings" but I am unable to find Zambia in the country groupings drop down list.
    Can someone pls help asap. Its an urgent client requirement.
    Bye
    Naveen

    Hello All,
    Thanks to all of you for trying to solve my problem but at last the solution was very easy which I could find myself.
    There is a custome table T500L_CUST in which I can configure Zambia country grouping and accordingly create a wage type catalog for Zambia by copying the wage types from other countries 99 or in that matter any country.
    Let me know if anyone has any doubt in this.
    Bye
    Naveen

  • When i want to create a face time it tells me to vertify my email address. When i go to do this i have to type in my apple ID and password on the Apple website, however when ever i do this i get a message saying Invalid account for this Email Address..

    when i want to create a face time it tells me to vertify my email address. When i go to do this i have to type in my apple ID and password on the Apple website, however when ever i do this i get a message saying Invalid account for this Email Address..

    Same problem here.  Whats the deal?!  Apple??

  • Create a structure type at runtime

    Hi friends,
    is it possible to create a local structure type dynamically(at run time).My situation is as follows :
    The user gives a period of time - for Example from "05.03.2009" to "04.03.2010"
    Depending on the number of months between the period of time 
    I have to create a structure with field names as follows:
    I have calculated the number of months between a period of time and the field name also(Mar-09.Apr-09 extra) using function modules.
    The question that is running around my head now is how to create the local structure type at run time with the field names.
    TYPES: BEGIN of st_testStruct
         matnr type string,
         land type string,
         "The above to fields in the structure will always be there but depending on the period of time.
         the following fields have to created dynamically.
         Mar-09 type string,     " as the time period starts from "05.03.2009"
         apr-09 type string,
         may-09 type string,
         ........so on
         dec-09 type string,
         jan-10 type string,
         feb-10 type string,
         mar-10 type string,
    end of st_testStruct.
    depending on the time range the number of field could be more or less in the structure type.Thats why I want to create it dynamically.
    Any sample code for this purpose is useful.....
    Thanks
    P

    ABAP RTTS is what you're looking for - check out this [Wiki page|http://wiki.sdn.sap.com/wiki/display/ABAP/RuntimeTypeServices+%28RTTS%29], which should answer your questions... (here's the link to the [ABAP online docu|http://help.sap.com/abapdocu_70/en/ABENRTTI.htm])
    Cheers, harald
    p.s.: Don't use the hyphen in your field names. This was a bad practice that was used in some old releases. The problem is that fields in a structure are addressed with a hyphen, e.g. like mara-matnr.

  • I am mac user and want to create Object in VBA macro. when i write "set objwrd=createObject("Word.Application")"- it returns "runtime error "492" can't create object". now what it alternative to create object for word in excel macro???

    I am mac user and want to create Object in VBA macro. when i write "set objwrd=createObject("Word.Application")"… it returns "runtime error "492" can't create object". now what it alternative to create object for word in excel macro???

    Any help here...
    http://support.microsoft.com/kb/288117
    http://www.macworld.com/article/1154785/welcomebackvisualbasic.html

  • Creating a simple type in runtime

    Hi,
    I'd like to know if it's possible to create a simple type in runtime, and set its constraints.
    I need to do that because I generate UIElements at runtime, and I'd to parameter the type of the attribute bound to that UIElement at runtime.
    I won't know the number of UIElements and their type definitions until I go get them from the backend.
    Is it possible, or I'll have to resolve that through a workaround?
    Thanks in advance.
    Alexis Trudeau

    Hi Alexis,
    it's not possible to create a SimpleType at runtime, but it is possible to modify one. Everything can be changed except the builtin-type, which basically describes the Java class used to store values for this type.
    So you can create your attributes using the predefined SimpleType for your desired class and then call
    getModifiableSimpleType()
    on that attribute. Then you can set the constraints as needed.
    HTH Uwe

  • Want to create a user field with type alphanmumeric and structure text through coding

    i want to create a user field with type alphanumeric and structure text through coding.am using vb
    plz help me

    Hi.
    Please take a look at samples in SAP B1 SDK.
    Dim oUserFieldsMD As SAPbobsCOM.UserFieldsMD
    oUserFieldsMD = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oUserFields)
    ' Adding "Name" field
    '// Setting the Field's properties
    oUserFieldsMD.TableName = #YOUR_TABLE_NAME#
    oUserFieldsMD.Name = "Name"
    oUserFieldsMD.Description = "Name"
    oUserFieldsMD.Type = SAPbobsCOM.BoFieldTypes.db_Alpha
    oUserFieldsMD.EditSize = #LENGTH_OF_FIELD#
    '// Adding the Field to the Table
    lRetCode = oUserFieldsMD.Add
    GC.Collect() 'Release the handle to the User Fields
    Hope it helps.
    Regards,
    Pawel

  • I had used Iphone4 to update to ios 7.0.4(11B554a) but after update whenever I want to create new contact, I can't type in the word because the keypad don't appear, what should I do? Can I uninstall the update of ios 7.0.4?

    I had used Iphone4 to update to ios 7.0.4(11B554a) but after update whenever I want to create new contact, I can't type in the word because the keypad don't appear, what should I do? Can I uninstall the update of ios 7.0.4?

    You cannot uninstall the update. Apple does not support downgrading. What troubleshooting have you done? Start with a reset. Hold the sleep/wake and home buttons together until you see the Apple logo and then release. The phone will reboot. Are you syncing contacts with iCloud?

  • Training and event management - create new type of attendee

    Hi all,
    For training and event management, I have to create a new type of attendee besides sap existing attendee type such as company, contact person, customer, external person and so on.
    Via IMG -> Training and event management -> basic settings -> object type modeling enhancement -> object type -> define object types, then how can I define OrgObj Type for new object type I want to create?
    Thanks & regards,
    WCC

    S_AHR_61016216 - Cancellations per Attendee , i think there is no standard report for cencelation of business events, type and group.
    for cancellations per attendee reports is available in the system.
    good luck
    Devi

  • I cannot sign in.  "This Apple ID has not yet been used with the iTunes Store.  Please review your account information."  I click "Review", next message "You must turn on cookies to continue.   Cookies must be enabled if you want to create or edit.. etc."

    I applied and received an upgrade code to Redeem Mountain Lion for my new MBP. 
    I get this message when I try to Sign in to the App Store after entering the redemption content code, and also if I just try to "Sign In".   The first part of the error is true - I haven't used the AppleID with the iTunes store.  
    I received the upgrade code using this same AppleID, so I don't think I can use a different AppleID.
    I also tried to re-create this appleID...(it was one suggestion I saw for this issue) It doesn't let me since the ID already exists...
    The error is:
    "This Apple ID has not yet been used with the iTunes Store.  Please review your account information."  I click "Review", next message "You must turn on cookies to continue.   Cookies must be enabled if you want to create or edit.. etc." 
    It's clearly not a cookie issue..   Stuck...

    The first part of the error is true - I haven't used the AppleID with the iTunes store. 
    Try here >  Using an existing Apple ID with the iTunes Store and Mac App Store
    received the upgrade code using this same AppleID, so I don't think I can use a different AppleID.
    Correct.
    It's clearly not a cookie issue..
    As for cookies. Quit the App Store. Now open the Finder. From the Finder menu bar click Go > Go to Folder.
    Type this exactly as you see it here:   ~/Library/Cookies
    Click Go the move the   com.apple.appstore.plist   file from the Cookies folder to the Trash.
    Relaunch the App Store.

  • I want to create a different plug-in . Could you please send me an email adress to contact about my questions for plug-ins?

    Dear Sir / Madam,
    First of all my english is not good enough and apologise for that. I want to create a kinda different java plug-in on mozilla . I ve been playin a textbase game for many years. However it takes many hours to play it manually. I d like to create a script for that and think script will work by itself (it will read 3d codes paste them automatically, it will click some words in website automatically etc.) I saw that one on your system its called "omerta rankscript". Could you tell me how i can start to do this and ? is it easy or how long time it takes to create a new plugin like this? also may i see the codes of this plug-in(omerta rankscript)?
    Thank you for your consideration.
    Best Regards,
    Zafer ATABAY

    Depending on what you want to develop, you could consider an ''extension'' or a ''userscript''. A plugin probably is not the right type of add-on to create.
    For suggestions and assistance with these different kinds of add-ons:
    Extensions:
    * http://forums.addons.mozilla.org/
    * http://forums.mozillazine.org/viewforum.php?f=19
    Userscripts:
    * http://userscripts.org/forums
    Good luck with your project.

  • Create Dynamic Structure at Runtime via ALV-Methods!

    Hi Experts,
    i try to create at the ABAP Runtime a new Structure.
    FOR EXAMPLE: I have a internal Table "database" and i dont know their Structure or Typ.
    MY Question: How can i get the structuretype for this internal Table "database" ??
                                    I thought that it is possible with ALV-Methods, but i dont find the right way.
    First Step:       I must get the structure of this internal Table.
    Second Step: I must create a workarea/ line of this internal Table, that i can work row for row with the table.
    Have someone an code example for me, because iám very confused about this Problem.
    With kind regards.
    Ersin Tosun

    Hello,
    For this specific requirement, SAP has provided RTTI class.
    Below is a code snippet for your ready reference. In this example we're trying to get the structure of the dynamic table <ITAB> whose structure is not defined till run-time.
    TYPE-POOLS: abap.
    PARAMETERS: p_table TYPE tabname.
    DATA: dref TYPE REF TO data.
    FIELD-SYMBOLS <itab> TYPE STANDARD TABLE.
    CREATE DATA dref TYPE STANDARD TABLE OF (p_table).
    ASSIGN dref->* TO <itab>.
    DATA: go_tab_descr TYPE REF TO cl_abap_tabledescr,
          go_struc_descr TYPE REF TO cl_abap_structdescr,
          wa_comp TYPE abap_compdescr.
    go_tab_descr ?= cl_abap_tabledescr=>describe_by_data( <itab> ).
    CHECK sy-subrc = 0.
    go_struc_descr ?= go_tab_descr->get_table_line_type( ).
    LOOP AT go_struc_descr->components INTO wa_comp.
      WRITE: / wa_comp-name.
    ENDLOOP.
    I must create a workarea/ line of this internal Table, that i can work row for row with the table.
    Sorry i missed the Step 2:
    FIELD-SYMBOLS: <itab> TYPE STANDARD TABLE,
                   <wa> TYPE ANY,
                   <val> TYPE ANY.
    LOOP AT <itab> ASSIGNING <wa>.
      LOOP AT go_struc_descr->components INTO wa_comp.
    *   To access the components of the structure dynamically
        ASSIGN COMPONENT wa_comp-name OF STRUCTURE <wa> TO <val>.
      ENDLOOP.
    ENDLOOP.
    BR,
    Suhas
    Edited by: Suhas Saha on Nov 18, 2010 7:26 PM

  • How to create multiple TYPES of objects from one menu?

    Q: How can I create a single class to create objects of multiple 'object classes' in a way that is not a huge switch statement?
    Explaination:
    Let's say that I have an application that I am building, that manages five hundred object types. A properly-built object subclassing tree is created, and I want to be able to create objects of any 'leaf node' of this subclassing tree using a single 'objectCreate()' method in a 'factory object'. The purpos of this method will be to create an instance of the correct object, pass a handle to a few collections for properly sorting and storing these objects in groups.
    Usually, one could create a switch in this function, testing for the type of object that the user wants to create from the menu. But in the case of having hundreds of possible object choices, this becomes harder and harder code to maintain (let alone performance).
    Any suggestions?

    But if my menu has:
    1. German Shepard
    2. Doberman Pinscher
    3. Malamut
    4. Persian Long-hair
    5. Siamese
    6. Tabby
    And my object class tree goes:
                                  [ Animal ]
                 [ Cat ]                              [ Dog ]
      [ various breeds ]                         [ various breeds ]How do I code the menu class to respond to the input, so that it runs the correct [breed] object's constructor?
    The line:
    Animal choice = new xxxxxxxx();
    I can't use a variable to replace 'xxxxxxxx' in run-time, but having a ton of choices in code sounds/looks unreasonable.
    if (choice == "Doberman Pinscher")
    Animal choice = new doberman();
    else if (choice == "Tabby")
    Animal choice = new tabby();
    Do you see what I am trying to avoid? I am not experienced enough to instantly realize how to avoid the latter, and instead, do a single instantiation command for the correct constructor.

  • HT1178 Do I want to create a new wireless network or join my current network?  I can't connect an ethernet cable to the Mac / printer and to the wireless modem at same time - in two different rooms.

    I am trying to set up Time Capsule so that I can do my first backup (after 1 1/2 years!) with Time Machine.  I have read other forums, but in each case they instructions eventually do not apply.
    I have connected my TC to my existing wireless router.  This sits in a bedroom and cannot be moved as a rental home.
    I have plugged in the TC and updated the software.
    Now - do I want to A Create a New Wireless Network (remember I can't connect the TC to Mac using an Ethernet cable). B Replace an existing base station or wireless router with TC (only intend to use for TM as don't know other benefits as of yet). or C want TC to join current network. 
    Thinking C.  If I choose C, it then asks A TC to wireless join current network (NO as already connected using Ethernet). B want to connect TC to my network using Ethernet to extend my existing wireless network. C want to disable the wireless network on this TC and connect it to my computer or network using Ethernet - CANNOT do this as devices can not be in the same room.
    Or do I want to create new wireless network - first set of questions - choice A?  What is the benefit to creating a new one when I won't be in this rental house for longer than 18 more months??
    Please help and quickly!  Thanks!

    Let me suggest some things.
    But first ask exactly what wireless router you have now and what type of broadband service?
    Are you happy with the wireless on the current router? If so, then you can plug the TC straight into whatever computer you have by ethernet, short 1M cord with no connection to the network. And use it without affecting your existing network at all. This is trivial setup.
    Although you don't say exactly what Mac and printer you are using, is it a desktop? Laptop it is definitely easier not to plug it in, but a desktop you can plug in the TC and it will all sit happily together.
    How is the printer connected and to what?
    I am not sure why you need such quick help.. this is all minor setup stuff.. and 18months in todays world is like permanent man.
    Your multiple A, B, C are more confusing than helpful.
    The best choices without more info.. are to replace the existing wireless router with the TC. ie your option B.. but how to do this depends on the type of connection. Is it cable or adsl? Can you easily bridge the existing modem router.. if that is what it is?
    Think carefully in the ideal world what would you like..
    and what do you have..
    We can probably suggest ways and means to fit what you like to what you have.. without introducing a stack of options that are doing your head in.

Maybe you are looking for

  • Time Capsule and windows 7

    Just installed a new time capsule. I have a MacBook and my wife has a pc. I am able to get on fine. I downloaded airport utility for windows 7 from Apple support for her, but when I open network preferences I can only get on the guest site from the p

  • Using ms office 2008 for mac home & student edition with snow leopard serv

    Hi all, I have a very particular question. I have a new small business starting up and we want to make full use of leopard and snow leopard server in our infrastructure. We also want to use os x for all our client machines. We want to use ms office 2

  • HELP - Website isn't working for me but working for everybody else

    Hey I'm new to this site so I'm sorry if this is in the wrong section! So I've been getting annoyed lately because my website (www.curtiskeay.com) isn't working for me and just redirecting me back to my hosting website saying that the website is 'com

  • Lumia 1520 update information

    Hello, When can we expect the update for Lumia 1520? Not talking about Denim update, talking about OS update only with the new features (creating folders, selection of multiple sms) Thanks, Jose Santos Solved! Go to Solution. Attachments: original.jp

  • Pdf on encore or pr

    Hello friends, Cant I put pdf files to a dvd and how cant doing that.?.....I want put an pdf book inside the dvd for view on any computer.