Sunday, January 27, 2013

Understanding and Customizing Electrical's Ladder Reference Numbers (MLR)

The ladder is unique in that each number running down the side is simple text. Delete these and the ladder continues to function just fine. However the first number is a block with several hidden attributes. Delete it and the ladder is nothing more than dumb AutoCAD lines and text. So in all reality the first number on the ladder IS the ladder. Components and wires will auto-number as if the rest of the ladder is not present. Nothing else is needed! So this post is really about the Master Ladder Reference or MLR block.

The first thing I always do when tackling a subject in Electrical, is figure out what blocks are in play. I open each and take a look at what attributes are in each. This helps me understand why each block acts the way it does. Then I start tweaking and observe the results. So what blocks are at play here?

The MLR Blocks

The horizontal ladder MLR blocks all start with WD_MLRH and the vertical MLR's start with WD_MLRV. In the images below the blocks are in order and shown in both exploded and in use.


Ladder Style

If the change needed was simply a font style/size change, then I would find the closest style and modify that block. Remember to purge the old block reference from any drawings after making changes. However if the change involves adding a custom block or extra text, I would stick with modifying the User Block (WD_MLRHX).

First lets look closer at the WD_MLRH block. This is the simplest and most commonly used style.
                                 image     image
Note that the MLR block stores not only the starting rung number (RUNGFIRST) but also all the other ladder settings entered at ladder placement.

In simple terms wire numbers and component tags look opposite the Sort Order until a MLR block is found. Then from that MLR blocks 0,0 it counts down using the spacing, index, and first rung number to find what tag/wire number should be assigned. The actual rungs and text numbers running down the side do nothing.

To test this delete some rung numbers and type something over one of the other text numbers on the side and then place a component. The proper number is given to the component. Renumber or Revise the ladder and the text is replaced with the proper numbers again.

Adding Sheet Numbers

The third and fourth reference style are awesome and underutilized. They both bring the sheet number into the front of the ladder numbers. Most company standards have the rung numbers match (in hundreds) the sheet numbers. The first sheets ladder starts with 100, second with 200 and so on. This causes extra work when an additional sheet is needed between sheets 5 and 6 on a 60 page project. However when combining the sheet number with the reference number a Project-Wide Update and Retag is all that's needed to update all sheet numbers, ladders, components, and wire numbers.

This makes adding sheets a breeze because the template already has properly numbered ladders in place. Simply add the new sheet and start placing components. There is no need to revise the ladder with the correct starting rung number.

When using any ladder style that references sheet numbers, remember the first number (sheet number) is missing from the "reference" number and must be added to components, wires, and cross reference settings. Add the %S as needed. The "S" must be capital.

Adding Geometry/Text to Reference Numbersimage

MLR blocks 8, 9, and X add a block to the reference numbers. The script that builds the ladder simply fills in text with the proper reference number. If you add geometry or extra text to the MLR block, it is not automatically copied down to the other numbers. The extra text or geometry must converted into a block and then added to the MLR block being modified. This embedded block is named AW_MLR_USER by default. However it seems to push any block name just fine. If multiple blocks are added only one of them will be pushed down.

When this extra block is pushed down to each row, it is placed using its own 0,0 regardless of where it was inside of the MLR. The additional blocks will be placed off to the side over the reference number. It seems the default distance off of the MLR's 0,0 is 0.513 inches. Make sure your custom blocks origin is positioned appropriately.

If the additional geometry is simply an arrow, dash or inline text it can be quite frustrating trying to get it to fall into place. Also I gave up on the Block Editor when working on this "block within a block" and simply exploded, modified, and re-blocked.


In this example I created an arrow block with an origin at the end of the arrow head. imageimage

Notice how the script assumes that arrow should be dead center of the reference numbers. With that knowledge its easy to predict where and how the inserted blocks will behave. I simply need to change the origin of my arrow block to be dead center between my reference numbers.


So lets try this again. I exploded the arrow block and on recreation I moved its origin over a bit.



Tada... and now it works as expected.



  1. Again thank you for the post.

    It took some tweeking but i got it.

    I have a couple of other modifications that i would like, do you take requests? :)


  2. Request away :)
    I'll do my best.

  3. Great,

    There are times when we need to add items to our BOM that are not on the electrical schematic. We put reference drawings, such as, the hydraulic schematic, Single Line diagram, etc. in the BOM.

    We need a way (maybe a Macro) to have these drawings added/removed from the BOM after running a BOM Report.
    I know we can add these ref drawing numbers to the catalog and then assign them to a component, but the problem with that is we will have random components on the schematic that will come up in other reports and they may get accidently deleted.

    I like the idea of using the catalog to add these ref drawings but i was wondering if there is a way to have them added or removed from the bom without having to add a random component to the schematic.

    Thanks for the help so far,

  4. I added my IMAGINiT e-mail address to my profile above. So you can e-mail me as well. This blog is a side thing and obviously real work comes first. But I will do my best with any requests.

  5. James,
    I see this as a two part question. How to mix and match schematic components with "other" components. And how to remove entire pages from a BOM. E-mail me so I can confirm your desired workflow.