Indicates the band in a hierarchical control which uses the current record. A band consists of all the records at a given level in the hierarchical display. A given band might contain sets of child rows from different parent records, as shown:
Band 0Band 1Band 2Band 2Band 3Band 3Band 1Band 0Band 1Band 1Band 0Band 1Band 2Band 3Band 3Band 1Band 2Band 2Band 1Band 1Band 2Band 2Band 3Band 3This property is only set for a ProBindingSource bound to a ProDataSet with a recursive data-relation. A recursive data-relation can use a particular query in different bands. To access the correct query for the current row in this case, your application must use the BandIndex as a parameter for the data-relation’s CURRENT-QUERY( ) method.
Data type:
Access: PUBLIC Read-onlyThe following procedure is a CreateRow event handler designed to handle a ProDataSet with a recursive data-relation. First, it checks to see if the BandIndex is 0, which always uses the top query. If not, it uses the BandIndex as the parameter for the CURRENT-QUERY( ) method to find the handle of the correct instance of the data-relation query.
PROCEDURE recursiveRelationCreateRow:DEFINE INPUT PARAMETER sender AS System.Object.DEFINE INPUT PARAMETER args AS Progress.Data.CreateRowEventArgs.DEFINE VARIABLE hBuffer AS HANDLE.DEFINE VARIABLE hQuery AS HANDLE.DEFINE VARIABLE hTopQuery AS HANDLE.DEFINE VARIABLE hRelation AS HANDLE.hBuffer = args:BufferHdl.IF args:BandIndex EQ 0 THENhQuery = hTopQuery.ELSEhQuery = hRelation:CURRENT-QUERY(args:BandIndex).hBuffer:BUFFER-CREATE().hQuery:CREATE-RESULT-LIST-ENTRY().args:Created = TRUE.END.
© 2012 Progress Software Corporation and/or its subsidiaries or affiliates. |