Need help working from home with your Bentley software? We're here to help - click here
Original Article Date: Dec 18, 2001
Now this is really cool!! This article, written by Mr. Thor Leslie, explores the uses of 3D custom linestyles and even includes an exercise to do!
Caution: Regarding MicroStation pre-V8: Custom linestyles created in a 3D file will not display in a 2D file. This has been resolved in MicroStation V8.
How many elements do you think this took to produce this 3D model?Well, if you answered four then you would have been correct. The four elements are custom linestyles: one line for the stair, one for the handrail, one for the conveyor and one for the skirts and guards. Interested? Then read on!MicroStation is delivered with seven basic linestyles that we're all familiar with and most of us are content to use these without ever having to use a custom linestyle. However, custom linestyles are available for the user to define and with a little practise you can incorporate them into your designs.As with most learning experiences, I found myself in a position needing to produce a simple custom linestyle. It was a line complete with a balloon on one end and a dot on the other. Never having created custom linestyle, I refered to the manuals and Inga's two articles:Give your files some style with Custom Line Styles - Part 1Give your files some style with Custom Line Styles - Part 2I managed to create the linestyle by assigning two point symbols, a dot and a balloon to the line. Once I got the concept firmly planted in my brain I experimented with “maybe this could be a 3D point cell”. Bingo! It worked!Next came these questions: How can I utilize this? What are the limitations? What are the rules? And, what will it achieve for me? Having worked with 3D modeling since MicroStation V4, my greatest desire was to create a handrail. Having used PDS, I knew that it was possible to place handrails using third party applications, but had not found a way using MicroStation “out of the box” to achieve this same task.I managed to create a series of handrails and place them in the plan (top) view and discovered that I could use all the linear modification tools to manipulate my custom linestyles to my hearts desire. I could copy parallel, project to another line, insert vertex, break line, change linestyle, extend by a specific distance, extend 2 elements to intersection, modify, delete vertex, trim and so on.I then turned my efforts to “what else can I define?” and ended up creating stairs, ladders, ladder cages, columns with baseplates and foundations, bracing, beams, conveyor modules, conveyor skirts with guards, conveyor trusses, crash barriers, windrows, chains, bolts and piperacks. Just about anything that has a repeating symbol along it's length can be created.What will it do?By placing a custom line in a file and you can:
What will it not do?Placing a custom linestyle in a file and you cannot:
How do you work around these limitations?
Care in making and placing custom linestyles:All definitions for custom linestyles have to be created in the top (plan) view. This works well for the handrails because that's their normal orientation. A stair is always placed in the elevation so to create the linestyle definition correctly the elements used in creating the point cell need to be “laid down” from the normal elevation to the plan view...that is, elements are rotated through 90 degrees.Multi-line capabilities:If you consider that a multi-line can be assembled using custom linestyle components then it is possible to define a multi-line for a walkway with two beams and two handrails by offsetting them from the centerline. Just to top it off, an associative pattern can be placed on the multi-line to represent grating.Organizing the library:If a little thought is given to linestyle libraries then they're fairly easy to manage. Create a separate library for each type of linestyle: stairs, ladders, handrails, beams, and so forth. By doing this it'll be easy to manage linestyles created for specific projects to be copied into the appropriate symbol resource directory.Remember that if all users are to see the 3D custom lines then the libraries should reside on a network directory that the configuration variable MS_SYMBRSRC is pointing to.Take care when defining the names of the linestyles and you'll be rewarded with a logical sort in the custom linestyles dialog box. Of course, the Settings Manager can also be used as a means of placing different linestyles.How do you create a 3Dlinestyle?We're going to create a simple handrail that consists of a post that's 1050mm high and two rails that are 2000mm in length. The post and the upper rail will be 50mm in diameter while the mid rail is only 40mm in diameter. Let's get started!
Start by creating a 3D file that will be used to draw the elements that make up the handrail. I like to keep these in a separate directory just in case I need to modify an existing linestyle after the fact.Place a 50mm x 1050mm cylinder to represent the post. From the top center of the post, place a 50mm X 2000mm cylinder to represent the upper rail and ensure that it's laying towards the left. And finally, place a 40mm x 2000mm cylinder half way up the post for the mid rail. It too will lie in the same direction as the upper rail. You should end up with something similar to the following image.
To create the new linestyle resource file, open the Linestyle Editor by selecting Edit from the linestyle picklist in the Primary Tools tool box. Select File > New and enter the name Handrails in the resulting dialog. Create a name for our new linestyle by going to Create > Name and replacing the word Unnamed with HandRail2000For the stroke component, go to Edit > Create > Stroke Pattern and edit the name New Stroke Component to 2000 Cycle Baseline.Next we have to define the stroke pattern: poke on the Add button and define it as a Dash with a variable length of 2000.
To create the point component of our linestyle, select Edit > Create > Point and change New Point Component with Handrail Components.To make the point symbol for the post, place an Fence in the Top view around the post and select the Create button. Key in the name Post and define the origin at the center of the bottom of the post. You might find it helpful to place a line coming from this location to snap to when defining the origin. For the rails, place a Fence over the post and both handrails in the Top view and select Create. Enter the name rhpost and use the same origin as before.To define the location of the point symbols in the new linestyle, select Base Stroke Pattern and choose 2000 Cycle Baseline.The completed linestyle is going to consist of a post at the beginning of the line followed by the repetitive placement of the rhpost symbol. To do this, poke on the little square to the left of Origin, click Select and choose the post symbol. Now select the dash (which is the black line under the Base Stroke Pattern button), click Select choose rhpost and set the Justify option to Right. Lastly, set End to be another rhpost.The last thing to do is to link the name with the new point component and save our work: From the Linestyle Editor, Edit > Link > File > Save.To test the new linestyle, set it as the active linetype by using the keyin LC=HandRail2000 or by selecting it from the linestyles picklist in the Primary Tools dialog. In either case, you can now place handrails in the top view by simply placing a line or other linear element!
Conclusion:Customising linestyles can be very rewarding and well worth the effort. They work very well and I have been using them in all my 3D modeling for the last 2 years. They save many hours of time and are easy and flexible to use. It's interesting to note, that they were never intended to be designed as 3D and therefore there's no documentation about this feature. Who knows? Maybe Bentley will surprize us with new tools and capabilities in MicroStation for creating and managing 3D linestyles!I created a DGN file and a RSC file in this ZIP file that may help you get started on the exercise above.
AskInga Article #74