askvity

How to Fill a Closed Polyline in AutoCAD?

Published in AutoCAD Filling 3 mins read

You can fill a closed polyline in AutoCAD using the BHATCH command.

AutoCAD provides specific tools for adding fills or hatch patterns to enclosed areas, such as closed polylines. The most common and widely applicable method mentioned for this purpose is using the BHATCH command.

Using the BHATCH Command

The BHATCH command is the standard way to add hatch patterns or solid fills to bounded areas in AutoCAD. According to the reference, you can use the BHATCH command to fill closed polylines. When you use BHATCH, you typically select the internal point of a closed area, and AutoCAD detects the boundary, which in this case is your closed polyline. You can then choose a solid fill (often found under the 'Pattern' dropdown as 'SOLID') or a hatch pattern.

Steps to fill a closed polyline using BHATCH:

  1. Type BHATCH or HATCH in the command line and press Enter.
  2. In the Hatch and Gradient dialog box (or the Hatch ribbon context tab), select the desired fill type (e.g., 'SOLID' for a solid fill).
  3. Under 'Boundaries', click the "Pick points" button.
  4. Click inside the closed polyline you want to fill. AutoCAD will highlight the boundary.
  5. Press Enter to return to the Hatch dialog box or ribbon.
  6. Review the settings (e.g., color, transparency).
  7. Click "OK" or press Enter to apply the fill.

Other Commands for Filling

While BHATCH is for general closed areas including polylines, other commands exist for specific object types or workflows:

  • MPFILL Command: The reference notes to use the MPFILL command to fill polygon objects. This command is typically associated with AutoCAD Map 3D and is designed specifically for filling Map 3D polygon objects.
  • ADEFILLPOLYG: The reference also mentions ADEFILLPOLYG in the context of moving filled objects in AutoCAD Map 3D. The note states: If you move closed polylines that you filled using ADEFILLPOLYG, you must move the hatch object as well. AutoCAD Map 3D toolset considers the closed polyline and the hatch object as separate objects. This highlights that fills created by methods like ADEFILLPOLYG (and generally by BHATCH) are separate objects from the original polyline. If you modify or move the polyline, you need to ensure the fill object is updated or moved accordingly.

Important Considerations

  • Closed Boundary: For BHATCH to work, the polyline must be completely closed. If there are gaps, the hatch will likely "leak" or the command will fail.
  • Separate Objects: As noted regarding ADEFILLPOLYG, the fill created by BHATCH is a distinct object layered on top of or below the polyline. If you edit or move the polyline, the fill does not automatically move with it unless they are grouped or selected together.

In summary, the most common and direct method to fill a standard closed polyline in AutoCAD is using the BHATCH command, selecting the desired fill pattern (like SOLID), and picking a point inside the polyline boundary.

Related Articles