Original Article Date: June 18, 2002
This article was inspired by and based upon a posting to Bentley's V8 newsgroup by Paul Mullis of Culpepper, McAuliffe and Meaders, Inc. In the posting Paul addressed how to create "tag cells" for title blocks and described one method of utilizing V8's new and improved tags. It's also somewhat of an extension to Brien Bastings Working with cells and tags attributes that also deals with cells and tags.
In earlier versions of MicroStation it was often a difficult task to manage and maintain cells with tags. All of that has now changed with the release of V8 - most notably you can now create a cell that only contains the tag and nothing else. In this article, I'll describe just one technique of creating a "tag-cell" that you can use for your title blocks. All we're going to do is creating a model containing only the tag with it's "origin" at XY=0,0. This will allow us to use the model as a cell for placement in our drawings. The following is just a wee bit of a description of what a tag is and then the steps for creating your tag-cell follow.What's a tag?:Without going into gory technical detail, an tag is a place-holder for non-graphical information that is stored as part of the element in the DGN file. There are lots of neat things you can do with tags such as populate an external database, generate reports, maintain quantity information and control the information being used in a title block.Parts of a tag:A tag is made up of a tag definition and belongs to a tag set. A tag set can several tags in it and to take it one step further, the design file can have several tag sets. For example, you could have a tag set called Equipment that contains the following tags Part Number, Serial Number, and Purchase Date. The same file can have another tag set called Title Block that contains Title, Drawn By, Scale and Date as it's tags. Pretty simple really. 1. Preparation:First things first...either create your own file or use the one I've prepared for you: 109_tags.dgn. If you're using mine, note that it has two models: Tags which is empty and has the model called Border attached as a reference. The location of the borders should be noted as well in that the lower-right corner of the border lines have been placed at XY=0,0. Again, since we can use a model as a cell, this location becomes the insertion point or origin upon placement.
2. Define a Title Block tag set:To define the tag, go to Element > Tags > Define and click the Add button. You'll then need to enter a name for the tag set such TitleBlock or something similar.
3. Define the tags for the tag set:From the Tag Sets dialog, poke on the Add button on the right side and enter the appropriate information. In this example, I used the tag name Title and entered Enter title of drawing for the prompt and ProjectName as the default value. Keep in mind that the user needs to be able to "see" where the tag is, so you should enter at least one character for the default value. Paul recommends using a simple little dash ( - ). The remaining tags can be defined at this time.
4. Place tag and adjust appearance:Tags are placed in the file using the active text settings, so ensure that they're to your liking. Then select Attach Tags, adjust the Associative option and snap to the lower right corner of the borders...this ensures that the tags location is placed correctly at XY=0,0.
Once the tag is placed, you'll notice that it gets placed in the file using the active text settings and that its position is not correct with respect to the title block. To remedy this, use the normal MicroStation element manipulation tools to adjust the position, size and appearance of the tags to suit.
5. Edit the tag values:Now for the fun stuff! Since the tag is going to be used as a cell you've got two choices:
In either case, you'll need to detach the border reference file from the tag model. To use the tag-cell, make Borders as the active model, go to the Cell Library dialog and attach the active file as the cell library. Notice that the name of the model containing the tag is displayed as an available cell and that the default tag values appear in the preview window? Cool eh?Once the tag has been placed as a cell, you can then use the Edit Tag tool to "fill-in" the correct tag values. What's neat about all of this is that you only need to poke on one of the tags in order to edit the information about all of them. This may become useful for those tags that don't have any default information in their definition.
AskInga Article #109