Open
Description
When reading a dxf file, the message "The layer color cannot be ByLayer or ByBlock" is displayed.
- I see a layer color setting code that checks as shown below. Is it absolutely necessary?
- Is there a problematic value among the color values of the layer in my dxf file?
ACadSharp/Tables/Layer.cs
/// <summary>
/// Color
/// </summary>
/// <remarks>
/// if the index is negative, layer is off
/// </remarks>
[DxfCodeValue(62, 420, 430)]
public Color Color
{
get { return this._color; }
set
{
if (value.IsByLayer || value.IsByBlock)
{
throw new ArgumentException("The layer color cannot be ByLayer or ByBlock", nameof(value));
}
this._color = value;
}
}
this is dxf layer information