none
Display xml with nested data on multiple pages RRS feed

  • Question

  • We are trying to develop an rdlc that can be used as an invoice.  The data will be constructed as shown below where there can be any number of invoices with any number of line items.  How can I put each invoice on a single page?  Currently I can get the data from the invoice, but when I try to put the line items on the page I get all line items for all pages instead of the items for the current invoice.  So for the data below, I would get 3 invoices each with 5 line items.

    <Root>
      <Invoice>
        <Name>Bill Smith</Name>
        <Account>1234</Account>
        <LineItems>
          <LineItem>
            <Amount>112.00</Amount>
            <Description>Cable</Description>
          </LineItem>
          <LineItem>
            <Amount>25.00</Amount>
            <Description>Water</Description>
          </LineItem>
        </LineItems>
      </Invoice>
      <Invoice>
        <Name>Bob Jones</Name>
        <Account>2345</Account>
        <LineItems>
          <LineItem>
            <Amount>25.00</Amount>
            <Description>Water</Description>
          </LineItem>
        </LineItems>
      </Invoice>
      <Invoice>
        <Name>Smith Jones</Name>
        <Account>3456</Account>
        <LineItems>
          <LineItem>
            <Amount>12.00</Amount>
            <Description>Service Charge</Description>
          </LineItem>
          <LineItem>
            <Amount>5.00</Amount>
            <Description>Late Fee</Description>
          </LineItem>
        </LineItems>
      </Invoice>
    </Root>
    • Edited by Brian Bull Wednesday, July 8, 2009 3:54 PM xml formatting got messed up
    Wednesday, July 8, 2009 3:52 PM