A private block is a part of the report it’s inside of. This is unlike a drawing library or internal block, which is a library object that exists outside the report, and is included into it by reference. Private blocks are no more than a grouping mechanism for entities in the report. However, they are very useful for displaying or suppressing a group of entities together, as well as for moving a group of entities a specified distance in response to a specified condition.
Note: This exercise requires the use of the training.GLB library available from: download.aspx. Instructions for unzipping and setting up the library is on: using gint downloaded examples.aspx.
In the object selector, select ‘FINAL PHOTO TEST PIT’. Notice that it incorporates two blocks: a red one at left and a magenta one at right.
Zoom in on the red block insert at upper left. Notice that the block type is ‘PRIVATE’, the block name is ‘FIRST PAGE’, and the page range is ‘NOT ADDITIONAL PAGES’. ‘NOT ADDITIONAL PAGES’ specifies that the contents of the block—which are column entities—appear on the first page only (or until the bottom depth of the log appears), and not thereafter.
Zoom out using the Zoom Extent button. Zoom in on the magenta block insert at upper right. Notice that the block type is ‘PRIVATE’, the block name is ‘PHOTO PAGE’, and the page range is ‘ADDITIONAL PAGES’. The page range specifies that the contents of this block—which are photographs and corresponding titles—only appear after the log on the first one or more pages is complete.
Double-click on the ‘PHOTO PAGE’ block insert. Notice the Offset X field, which contains a value of ‘-8.0’. This specifies that when the block’s contents are printed, they print 8" to the left of where they appear in REPORT DESIGN.
When a FINAL PHOTO TEST PIT report is printed, one or more pages of log appear, followed by as many pages of photographs as are present. Separating the report entities into one private block for log entities and another private block for photo entities enables this kind of behavior to be implemented. Creating the photo entities 8" to the right of their intended position, then moving them 8" to the left on output, enables you to lay them out in the report design without having to place entities from the two blocks on top of each other.
The entities in black (in the heading and frame) are not in a block, and therefore appear on all pages.
In the object selector, select ‘FINAL SIMPLE SMART LOG’. Notice that this report contains two private blocks, one red, one blue.
Notice that the red block (SAMPCOLS) contains the two columns of sample information, and the blue block (LITHCOLS) contains the three columns of lithology information. This report is designed to eliminate the sample columns when there is no sample data in the borehole, and move the lithology columns to the left to fill the space (widening the Material Description column to compensate).
Double-click on the red SAMPCOLS block insert. Click the Configuration tab in the block properties window. Notice the Output Condition field contains the following expression:
This expression returns ‘True’ when there is sample data for the borehole. When the Output Condition for a block evaluates to ‘True’, the block is output; if it evaluates to ‘False’ the block is not output.
Click Cancel to close the block properties window.
Double-click the blue LITHCOLS block insert. Notice the following value in the Offset Xfield:
<<Calc(-1 * <<Report Var.OffsetSample>>)>>
This expression generates a negative value, in inches, that is the correct distance to move the columns in the LITHCOLS block to the left when sample data is not present.
Double-click in the Material Description column (somewhere below the column header). The COLUMN - TEXT VS DEPTH PROPERTIESwindow opens. Notice two things:
You are able to open this column for editing. If it were in a drawing library or internal block instead of a private block, you could not do this.
Click Cancel to close the properties window.
Note: With Internal and Drawing Library blocks, the Explode command will bring the block entities into the current page and erase the insert. However, for Private blocks the Explode command erases the insert without bringing the entities into the report.
Working With Blocks Part 1: Introduction https://communities.bentley.com/products/geotechnical1/w/wiki/12371.working-with-blocks-part-1-introduction.aspx
Working With Blocks Part Two: Drawing Library Blocks https://communities.bentley.com/products/geotechnical1/w/wiki/12372.working-with-blocks-part-2-drawing-library-blocks.aspx
Working With Blocks Part 3: Internal Blocks https://communities.bentley.com/products/geotechnical1/w/wiki/12374.working-with-blocks-part-3-internal-blocks.aspx