Looping inside Smartform with PWB data

Hi,
I'm trying to access the field belzart and inside the following path:
PWB_DATA-> T_BBP_HEADER->T_BI_HEADER->T_BI_ITEM-> WA_BI_ITEM.
can anyone please tell how shoul i loop the table so that I can access the data?
If I loop
PWB_DATA-T_BBP_HEADER-T_BI_HEADER-T_BI_ITEM into SU_BI_BILL_S_BI_ITEM, it gives the error:
"No component exists in PWB_DATA with name T_BBP_HEADER-T_BI_HEADER-T_BI_ITEM".
Awaiting early response.
Thanks & Regards,
Anshumita Baksi.

Hi,
In the initialazition tab copy the data of ts_customer into anther internal table like as follows.
data:it_cust type table of ts_customer.
it_cust[] = ts_customer[].
sort it_cust by kunnr.
delete adjacent duplicates it_cust comparing kunnr.
now your internal table contains no duplicate kunnr.
first loop the it_cust.
then loop the ts_cust where kunnr = it_cust-kunnr.
after this loop create a command node
select the go to and give the next page .
now it will give multiple letters for each customers.
Tnks,
NN.

Similar Messages

  • Printing Smartform with Table data from PrintProgram

    Hi,
      Can any one explain the steps involved in printing the Smartform with the data from the Print Program table. How to fit table in the Smartform i.e, while designing the Smartforms layout for the table.
    Thanks & Regards

    Hi,
       As  data is coming from the print program in the table. Do the following procedure
    1. In the form interface ---> Declare the internal table as same structure as in the print program. for ex: you r passing MARA table data then declare it as itab type table of mara.
    2. In the window you want to create the table, right click > create> table.
    3. Go to data tab give the internal table name and work area .
    4. Now go to General tab-->Details.
    5. Declare the line types.
    6. Right click on header/main area/footer -->create table line.
    7. Now give the line type which you want to use.
    8. In the displayed columns>right click> create text node.
    9. In the text node &mara-matnr&.
    Procedure to create line type:
    1. Double click on table
    2. Go to table tab --> details
    3. Give the table width (width you want to display on the screen should be less than or equal to the window width).
    4. Line type --> Divide this into no of column you want to have in header/item.
    Note: total length of all columns should be equal to the table width.
    5.save.
    Br,
    Laxmi

  • Looping over arraycollection with sap data

    Hello,
    I asked a lot of persons but i still have a problem.
    I am trying to make a organizational chart in Adobe Flex with data out of the SAP system.
    When I try to access my data that I have given trough the Flash Islands container it doesn’t work.
    I do:
    [Bindable]
    Public var datasource:Arraycollection;
    Then I want to loop over this datasource with a for loop but it says that the object is null.
    for (i = o; i < datasource.length; i++)
    When I use datasource as dataprovider for a datagrid in Flex, that works perfect.
    Please answer fast because I need it for school.
    greetings

    Hello,
    I asked a lot of persons but i still have a problem.
    I am trying to make a organizational chart in Adobe Flex with data out of the SAP system.
    When I try to access my data that I have given trough the Flash Islands container it doesn’t work.
    I do:
    [Bindable]
    Public var datasource:Arraycollection;
    Then I want to loop over this datasource with a for loop but it says that the object is null.
    for (i = o; i < datasource.length; i++)
    When I use datasource as dataprovider for a datagrid in Flex, that works perfect.
    Please answer fast because I need it for school.
    greetings

  • SmartForms: How to loop inside smartforms?

    Hi All,
    I have the following scenario below:
    kindly check the screenshot of my smartForm first: http://img10.imageshack.us/img10/9456/sflayout6cells.jpg
    In the screenshot, in the right side is the screenshot of my SAP output, while on the left is the smartforms.
    Let's say I have ITAB.
    LOOP AT itab.
    ENDLOOP.
    In my SF, i have 6 big cells, i want to pass itab-matnr in each of the 6 cells.
    Now, if the number of rows in my ITAB is 12, I should pass 12 matnr in each of the cells but it should trigger my SF to produce a 2nd page to contain next set of 6 matnr.
    How can I loop the page of my SF to contain the next loop pass from my ITAB?
    Thanks.

    U want that after every six iteration the page no should be changed and the next six matnr's should print on the next page. Please correct me if I am wrong?
    In that case u do these things in main window. Create a template in main window to hold six rows.
    rigt clk and create loop lines .
    Now put one program line there and  loop the internal table upto 6 rows.
    take a local variable for storing the index no.
    and write a case statement there
    declare six global variables of type string
    pass each of the matnr's in each of these six variables according to the index nos.
    after the itab has looped six times.delete itab from 1 to 6.
    and increase the page no by 1 everytime at the end. In this way u need not worry how many rows ur internal table contains.It will keep printing in multiples of six.
    See the sample code below
    DATA LV_INDEX.
    CLEAR LV_INDEX.
    CLEAR:GWA_VBAP,GV_STRING,GV_STRING1,GV_STRING2,GV_STRING3.
    LOOP AT GIT_VBAP INTO GWA_VBAP FROM 1 TO 4.
    CASE LV_INDEX.
      WHEN 0.
       GV_STRING = GWA_VBAP-MATNR.
       CONDENSE GV_STRING.
      WHEN 1.
       GV_STRING1 = GWA_VBAP-MATNR.
       CONDENSE GV_STRING1.
      WHEN 2.
       GV_STRING2 = GWA_VBAP-MATNR.
       CONDENSE GV_STRING2.
      WHEN 3.
       GV_STRING3 = GWA_VBAP-MATNR.
       CONDENSE GV_STRING3.
    ENDCASE.
    ADD 1 TO LV_INDEX.
    ENDLOOP.
    DELETE GIT_VBAP FROM 1 TO 4.
    SFSY-PAGE = SFSY-PAGE + 1.

  • Threads in while loop with two data acq loops

    Good day, I am using two while loops to perform data acquisition from two different pieces of hardware inside a "main" while loop - a total of three while loops. I want each of the data acq loops to run as fast as possible. With this model will each data acq loop run in a separate thread or will they be running in the same thread because they are both inside the "main" while loop.
    I'm not getting the performance I would like and I'm looking at ways to optimize the execution. 
    Thanks
    John 

    I would have a loop for each of you data acquisition tasks and at least one, possibly two additional loops that will write your data to file. Let the acquisition loops collect the data as quickly as possible and simply queue it off for further processing. When these loops are in parallel LabVIEW will run them on separate threads. In addition you could have a separate loop with an event structure that could handle you UI interaction. This loop could control the overall application with respect to starting and stopping the tasks, etc. You don't really need to contain all these loops in any other loop or structure. They can all reside on the block diagram next to each other. Ideally you will create subVIs for the data acquision and data processing tasks.
    Message Edited by Mark Yedinak on 10-06-2009 04:29 PM
    Mark Yedinak
    "Does anyone know where the love of God goes when the waves turn the minutes to hours?"
    Wreck of the Edmund Fitzgerald - Gordon Lightfoot

  • Help needed with binary data in xml (dtd,xml inside)

    I am using the java xml sql utility. I am trying to load some info into a table.
    my.dtd:
    <!ELEMENT ROWSET (ROW*)>
    <!ELEMENT ROW (ID,JPEGS?)>
    <!ELEMENT ID (#PCDATA)>
    <!ELEMENT DESCRIPTION EMPTY>
    <!ATTLIST DESCRIPTION file ENTITY #REQUIRED>
    <!NOTATION INFOFILE SYSTEM "Files with binary data inside">
    <!ENTITY file1 SYSTEM "abc.jpg" NDATA INFOFILE>
    xml file:
    <?xml version="1.0" standalone="no"?>
    <!DOCTYPE ROWSET SYSTEM "MY.DTD">
    <ROWSET>
    <ROW>
    <ID>1272</ID>
    <DESCRIPTION file="file1"/>
    </ROW>
    </ROWSET>
    I am using the insertXML method to do this. However, the only value that gets loaded is the ID. abc.jpg is in the same directory where I ran the java program.
    Thanks in advance.

    Sorry! wrong dtd. It should read this instead:
    my.dtd:
    <!ELEMENT ROWSET (ROW*)>
    <!ELEMENT ROW (ID,DESCRIPTION?)>
    <!ELEMENT ID (#PCDATA)>
    <!ELEMENT DESCRIPTION EMPTY>
    <!ATTLIST DESCRIPTION file ENTITY #REQUIRED>
    <!NOTATION INFOFILE SYSTEM "Files with binary data inside">
    <!ENTITY file1 SYSTEM "abc.jpg" NDATA INFOFILE>
    null

  • How to create a textfile dynamically(with in the loop) with given data?

    Hi all,
    Can anyone Please guide me how to create a text file in the given path dynamically? (with in the loop) with given data.
    For example:
    <%
    String data1="name";
    String data2="address";
    for(int i=0;i<10;i++)
    create the textfile at c:/test/sample.txt//name of the each file created being "sample.txt"
    //contents of text file will be
    data1+i; //to get name1,name2.....
    data2+i// to get add1,add2........
    delete(sample.txt) //to enable to create another file in the loop with same name
    %>

    The code which Ashokan mentioned is not is not creating a file.
    i used code given below to create and write into it.
    But, not is writing into it. I don't konw, where i am going worng !
    Code
    String sample2="C:/Ash/sample2.txt";     
                                                                                    FileWriter fw = new FileWriter(sample2,true);
                                            BufferedWriter bw=new BufferedWriter(fw);
                                            bw.write("EMP ID");     
                                            bw.newLine();
    Please help
    Regards
    aSh

  • Problem with pass data to smartform

    hi guru.
    i found a question and need advise for solve this problem.
    i create a smartform about tax, this form use sorted and index data from zreport to display in form.
    i declare structure of tab and structure of type in report as same as structure of type in smartforms (copy one from zreport and paste in form and correct header of type).
    when zreport execute, smartform is display data in my desire cell but one value is missing.
    so i run this report in debug mode, all data from zreport pass to smartform correctly. but when form display,  one important data is missing. nor a single trext from this data show in form. it's like non data to show or this data not exist at the begin, or this cell has fill with white color
    once i change this value to normal word but result is the same.
    at first i want to upload code and xml file of this form for easy to your, but i can't
    anyone have a clue? what is possible fr this problem?
    <removed_by_moderator>
    regards.
    kittisak.
    Edited by: Julius Bussche on Feb 25, 2009 9:00 AM

    to dinakar
    i use table to display and no error when check form.
    at first i declare data type as "stceg  type lfa1-stceg" . when i change data type to "stceg(20) type c" it still not work.
    Edit
    later, i try move a problem data to other cell. it display.
    Edited by: Kittisak B on Feb 25, 2009 2:24 AM

  • Error -50103 occured with timed loop inside a while loop

    Hello everyone,
    i wrote an application to sample analog voltage from  DAQ6024E card (see the attachments).
    I have a big while loop in the VI because a I want to add some other functions later.
    In the "WHILE_Cont Acq&Graph Voltage-Int Clk.vi" I use a while loop inside the big while loop to read the samples. It's working properly.
    but when I use a timed loop inside the big while loop (see "TIMED_LOOP_Cont Acq&Graph Voltage-Int Clk.vi"), I get an error -50103 from the timed loop.  It seems that the first cycle is ok, but after the first cycle the error occurs.
    I don't know what happens with the timed loop, anyone can help me? what does the error -50103 mean? thanks a lot!
    PS: I am using LabVIEW 8.0
    Message Edited by molo511 on 10-22-2006 05:21 AM
    Message Edited by molo511 on 10-22-2006 05:23 AM
    Attachments:
    TIMED_LOOP_Cont Acq&Graph Voltage-Int Clk.vi ‏143 KB
    WHILE_Cont Acq&Graph Voltage-Int Clk.vi ‏75 KB

    hi molo511,
    I tested your program but only with simulated devices. I had to delete the wire to the timing, so that the timed while loop runs with 1kHz. Did you already try this? Because this works on my PC.
    I also found a link in our database that might be interesting for you.
    http://digital.ni.com/public.nsf/websearch/04BEDD9E9E91ED3486256D180048116D?OpenDocument
    Greets
    Philipp N.
    NI Application Engineer

  • Help with loops inside a method

    I am having a bunch of problems creating a loop inside my 'mean' method. What i want do is set up a loop to give me the average of the numbers of the input that i entered. Can anyone assist me in creating this loop?
    My code:
    import java.io.*;
    import java.text.*;
    import java.util.StringTokenizer;
    public class Labtest6{
    public static void main (String args []) throws IOException {
    int MAX = 100;
    int MIN = 0;
    int [] list = new int [MAX];
    int count = 0; // ammount of items//
    double guess;
    double x;
    double avg;
    double var;
    double stdDev;
    BufferedReader stdin = new BufferedReader (new InputStreamReader (System.in));
    NumberFormat nf = NumberFormat.getNumberInstance ();
    nf.setMaximumFractionDigits (2);
    nf.setMinimumFractionDigits (2);
    count = read_list (list);
    avg = mean (list, count);
    System.out.println (count);
    System.out.println (avg);
    public static int read_list (int [] list)throws IOException {
    BufferedReader stdin = new BufferedReader (new InputStreamReader (System.in));
    int count = 0;
    String item = stdin.readLine ();
    while (item != null)
    list [count] = Integer.parseInt (item);
    ++ count;
    item = stdin.readLine ();
    return (count);
    public static double mean (int [] list, double count) {
    thanks

    That's not our job. It is your homework. Once you have made an attempt at it and can't get it to work, paste your code and ask a specific question. You won't get any help if all you do is whine about how you can't do it.
    P.S. When pasting code, highlight it and click the code button to retain formatting.
    Message was edited by:
    flounder

  • How to use loop in smartforms???

    hi experts,
                  I have an internal table with three values .i am passing it into new itab inside smartforms .while displaying it is displaying only the third data .i think i must use loop condition .but i dont know where to use it .pls help me.if i select only one data it is coming .if i select multiple data using select statement .only the final thing is coming .

    On your smartform, you should have a table set up.  Go to transaction SMARTFORMS, enter your form name, and display it.  Now navigate to the table on your form and double-click it.  Go to the Data tab.  Under "LOOP", make sure that you have checked "Internal table".  Next to that should be the name of your internal table, then "Into", then a work area.  The work area needs to be defined under "Global Definitions" (under Global Settings, check the tree for your form).  Your work area should be defined as TYPE, with the associated type being your internal table.  Your internal table should actually be defined as a structure where each component is one item that you want to include in your row.  I hope this helps.
    - April King

  • Loop in smartform - how to make values valid in all pages

    Hi All.
    I have a smartforms with several pages (9). I must print these 9 pages once for each line in the internal table ITAB. When I put a loop in the first page, the data under that loop is printed correctly, but every text node outside the loop always prints the last line of ITAB.
    Do any of you know how to make the data in the loop valid throughout the other pages?
    any help will be welcome.
    thanks,
    Hermes.

    I got it. The main window must be the first one in the first page. The loop must be inside the main window, and bellow the loop there must be a page-break command.

  • Smart form - loop inside a loop

    Dear Techies,
      I am new to smartforms. I have a query, in one of the code examples there is a context menu on the main window called "complex selection", but i dont find the same in my editor, what is the reason.
      I want this because i have data in two internal tables. Different tables are generated from secondary depending on the entries in first table. how do i achieve this on the main window.
    Similar to loop inside a loop, depending on my first table entries, all the entries belonging to that entry are to be put in table of second entry. i will have tables equal to the entries in first internal table. hope my question is clear.
    Please help.
    Regards
    imran.

    Hye..
      Loop in main area will fill only the current table, but i want several tables depending on entries in the first internal table.  The number of tables in the main window will be the number records in the first table.
    Regards
    imran.

  • How to build a array with collected data

    Hi,
    I have collected data from serial port with VISA. Now I want to build a array with 100 date points. Should I connect VISA Read with Build Array directly? How to do it?
    PS: All of them are in a While Structure.
    Thank you!

    An inefficient way to create the array is to use the build array and a shift register as shown below. It's more effecient in terms of memory management to create the array and then use the replace array subset as shown in the other image. Of course, if you don't need the array inside the loop, just wire the value out of the while loop and on the exit tunnel, right click and select 'Enable Indexing'.
    Message Edited by Dennis Knutson on 07-03-2007 10:25 PM
    Message Edited by Dennis Knutson on 07-03-2007 10:26 PM
    Attachments:
    Crude Build Array.PNG ‏4 KB
    Better Build Array.PNG ‏6 KB

  • Loop in smartforms

    hi all,
    ive just stuck with a problem in smartforms, ive created a smartform for purchase requisistion(pr) , in that im fetching the pr items in main window (main) and service line items in a loop in mainwindow, the problem is if the pr doesn't have a service line items a single empty line is displaying after the header data, i ve just tried by giving the conditions in the conditions tab" if itab or workarea is not initial" , but its stopping the loop and displaying only header data with out service line items. can any one give me the solution to this.
    regards
    venkat.

    Hi,
    if you want to dispaly the service line items even though there is no entry in line items table,  then create the service line item table after the PR line item table in main window not in (loop..endloop).
    In this case first line items of the PR will be printed and then service line items will be printed.
    If the service line items are related to the PR line items then the form is correct, because there are no line items for PR's.
    Regards,
    Raju.

Maybe you are looking for