Hi,
you can give criteria parameter when you open the dataset of your section.
Here's an example :
If clsheader.DataSet.OpenObject(omDefault, "InvoiId='ABC'") Then
Invoices dataobject include credit memo, quote, order and invoice. You can add a criteria to get only the invoitype that you want. In this blog : http://community.dynacom.com/EN/blogs/dynacom_blog/archive/2006/07/11/30.aspx you have an example on how to get invoitype enum.
Martin Ouellette
Dynacom Technologies, Inc.
www.dynacom.com