I suppose you are using SelfServicing.
Use the collection.GetMultiAsDataTable()
And pass the appropriate filter.
Please consult the manual on how to construct a filter:
**Using the generated code -> SelfServicing -> Filtering and sorting -> Getting started with filtering, **