TfrxUserDataSet and TCollection

Hi, I'm trying to automatically generate a report using data provided by a TCollection.

TCollections are composed by TCollectionItems, wich also contains both native data types and TCollections in its published fields. An example is:

TEmployees (TCollection)
TEmployee(TCollectionItem)
TSalesByEmployee(TCollection)

So, I want to create a report listing all employees and all the sales by each employee. I can't access directly to the database. Because of that, I created a report containing a MasterData bound to a TFrxUserDataSet for listing employees, and a DetailData bound to another TfrxUserDataSet to list the sales by employee.

Can anybody help me?

Leonardo.

Comments

  • gordkgordk St.Catherines On. Canada.
    edited 12:15PM
    I havent tried using a tcollection to supply data to an frxuserdataset.
    but for sure you will need to write code for each of the events of the frxuserdatasets to control movement in the dataset.
    onfirst, on next, on prior, and on eof.
    and ranges props as well.
  • edited 12:15PM
    Yes, thanks Gord.

    I'm reaching a solution for this. If I can make this abstract enough to be used with any TCollection descendant I'll share the solution with you.

    Sincerely,
    Leonardo M. Ram?©
    gordk wrote: »
    I havent tried using a tcollection to supply data to an frxuserdataset.
    but for sure you will need to write code for each of the events of the frxuserdatasets to control movement in the dataset.
    onfirst, on next, on prior, and on eof.
    and ranges props as well.

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.