@avinash00002002 wrote:
.... it always give me clockwise direction p1 and p2 point.
I still don't understand what you mean by "clockwise" in this context. In your sample drawing, the direction from P1 to P2 is clockwise in relation to the overall outline, but P3 to P4 is counterclockwise. Likewise, P7 to P8 is clockwise, but P5 to P6 is counterclockwise. And AutoCAD doesn't have any way of knowing that those independent Lines make a closed outline, so it can't determine clockwise vs. counterclockwise directions around it.
Also: Is the sample drawing what you are starting with, or the desired end result? If it's what you're starting with, what should be the end result? If it's the end result, what did you start with?
[If it's an end result, and if it started as a rectangle, then CHAMFER is probably what you want, as suggested. And if the outline were a Polyline instead of independent Lines, CHAMFER can do that to all four corners at once, by selecting the Polyline anywhere -- no separate selections of adjacent edges for each corner. Also, if it were a Polyline, AutoCAD could determine which direction around it is clockwise, though maybe that would not matter if Chamfer does the job.]
Kent Cooper, AIA