123ArticleOnline Logo
Welcome to 123ArticleOnline.com!
ALL >> Computers >> View Article

Zwcad Hot Tip: The Many Ways To Count Blocks In Drawings

Profile Picture
By Author: Paul W. Walker
Total Articles: 7
Comment this article
Facebook ShareTwitter ShareGoogle+ ShareTwitter Share

Sometimes we need to count the number of blocks that exist in our drawings. It turns out that there are several approaches to doing this in ZWCAD. Let me share them with you.

Approach 1: BCOUNT

Here is how to use the BCOUNT command to count all or just a selected group of blocks in drawings:
1. Enter the BCOUNT command.
2. Select the objects you want to count, and then press Enter.
3. Notice that the name of each block and the number of its occurrences appear on the command line. To see all of the details, press F2 to get to the Text window, a big version of the command prompt area. It looks something like this:

blocksum command

As a bonus, this method also reports the number of each kind of block in the selection set.

Approach 2: BLOCKSUM

The BLOCKSUM command does not count the total number of blocks; rather, it is used to count how many blocks are on a specific layer, and how many have the same name.

The BLOCKSUM command can ...
... be accessed from ZWCAD Express menu: Express - Tools - Number of Blocks.

blocksum command

Follow these steps to use the BLOCKSUM command:
1. Enter the BLOCKSUM command, or select it from the Express menu.
2. Notice that it prompts you, 'Layer/selection Set/All'. There are two choices, Layer, or select a specific number of objects:
- Layer option counts the number of blocks on the same layer as the selected block.
- selection Set option counts the number of blocks that have the same name as the selected block.
3. When you input L to choose the layer option, it prompts you, 'Select an object on the layer or exit:'. Select a block, and then press Enter.

Notice that the command line it reports, '[Number of] blocks on layer [layer name]'.

Approach 3: Attribute Extraction

The BCOUNT and BLOCKSUM commands are specifically meant for counting blocks. There is also an indirect way to count them, through attribute extraction. The AttExt command extracts all kinds of data from blocks, such as attribute values and X,Y coordinates -- and it also extracts the number of blocks. The result is similar to that of BlockSum, in that it lists the names of blocks and the number of occurrences. See the figure below.

blocksum command

Approach 4: QSELECT

ZWCAD's quick select feature is yet another indirect way to count blocks. Here is how to use the QSELECT command for this task:
1. Enter the QSELECT command.
2. In the dialog box that appears, set the following options:
Object type=Block Reference
Color=Bylayer (We assume that all of the block's colors are ByLayer.)
3. Press the OK button. Notice that all the selected blocks are highlighted. The command line prompts us that there are X item(s) selected, so we know how many blocks are in this drawing.

blocksum command

In addition to these ways of counting blocks in drawings, we could use LISP programs, but I think above four methods are enough for block counting. I'm glad to have shared them with you.

Total Views: 76Word Count: 510See All articles From Author

Add Comment

Computers Articles

1. Web Scraping Top Grocery Chains In Michigan
Author: FoodDataScrape

2. How Refurbished Laptops Help Students Save Money And Study Smarter In 2025
Author: usedstore

3. Why The Ls3002 Barcode Scanner Is Perfect For Retail In 2025
Author: prime pos

4. Does Cleaning Temporary Files Really Improve Laptop Speed? (what To Expect)
Author: Neha Jain

5. Extract Supermarket Data From Walmart & Target In Usa
Author: FoodDataScrape

6. How Odoo Partners Drive Growth: From Implementation To Innovation
Author: Alex Forsyth

7. Leverage Web Scraping Cold Drinks Data On Swiggy Instamart
Author: FoodDataScrape

8. Empowering Universities Through Student Engagement Crm Solutions|e2s
Author: Brenda Joyce

9. Odoo Manufacturing And Lean Practices For Small And Medium Enterprises
Author: Alex Forsyth

10. How Posiflex Pos Machines Enhances Customer Service
Author: pbs

11. Scrape Keeta Food Delivery App Data In Saudi Arabia For Insights
Author: FoodDataScrape

12. Microsoft Office Professional Plus 2021 Vs. Microsoft Office Professional Plus 2024: Which One Should You Choose?
Author: davudobuya55

13. Microsoft Office Professional Plus 2019 Vs. Microsoft Office Professional Plus 2019 Dvd: Which Version Should You Choose?
Author: davudobuya55

14. Microsoft Office Professional 2024 Vs. Microsoft Office Professional Plus 2010: Which One Is Right For You?
Author: davudobuya55

15. Microsoft Office Home Business 2021 For Mac Vs Microsoft Office Home Student 2021 For Mac: Which Is Right For You?
Author: davudobuya55

Login To Account
Login Email:
Password:
Forgot Password?
New User?
Sign Up Newsletter
Email Address: