How to use Bpoly function?

How to use Bpoly function?

nguyennhattanpt
Contributor Contributor
2,545 Views
13 Replies
Message 1 of 14

How to use Bpoly function?

nguyennhattanpt
Contributor
Contributor

I'm researching the Bpoly function but haven't found any documentation on how to use this function. Hope anyone can explain to me. I've been doing a little research now.
(bpoly [point] [selection-set] [option-keyword] ...)
option-keyword as a list but I don't know how to use it.
Help me!

Thank.

0 Likes
Accepted solutions (1)
2,546 Views
13 Replies
Replies (13)
Message 2 of 14

komondormrex
Mentor
Mentor

i think the only parameter in the bpoly function is a point. if it finds a closed boundary at a given point, then it draws a polyline boundary and returns its ename; otherwise, it returns nil.

 

0 Likes
Message 3 of 14

Kent1Cooper
Consultant
Consultant

It's odd that (bpoly) is not in the AutoLisp Reference.  But it does exist as an AutoLisp function, and @komondormrex seems to be correct [one trial here] that a single point argument does it.  For more complex situations, you should of course be able to use the BPOLY command rather than the AutoLisp function.

Kent Cooper, AIA
0 Likes
Message 4 of 14

nguyennhattanpt
Contributor
Contributor

Not really. bpoly function allows the use of 0, 1 or more variables. If there is no variable, it will be like a command boundary. 1 variable works as you said.
i used with 3 variables it worked. variable 2 is Selection-set ; same as boundary-set of the boundary statement.
3rd variable is a list (I tried with '(0 0 0)); I don't understand what it is.
The msg returned is: "Invalid option keyword"

0 Likes
Message 5 of 14

nguyennhattanpt
Contributor
Contributor

Try using this command: (bpoly (getpoint) (ssget) '(0 0 0))

you will see it working!

0 Likes
Message 6 of 14

komondormrex
Mentor
Mentor

mmmm, this has no sense, i mean for (bpoly) to have parameters other than a point. i mean, i think it is a short-function method apart from the command to get pline boundary at a point. but who knows... 

0 Likes
Message 7 of 14

Kent1Cooper
Consultant
Consultant

Without some documentation of the arguments and syntax required [I haven't found any], who can say?  So I have to ask:  where or how did you encounter (bpoly) as an AutoLisp function rather than a command, and where do you get the idea of the arguments you suggest?

Kent Cooper, AIA
0 Likes
Message 8 of 14

ВeekeeCZ
Consultant
Consultant
Accepted solution
Message 9 of 14

pkenewell6347
Advocate
Advocate

Example Post Link : HERE

 

Simple usage: 

(setq e (bpoly (getpoint)))

FYI - It is currently not recommended to use this undocumented function because it has some issues. Instead you should use:

 

(setq bp (getpoint "\nSelect Internal Point: "))

(command "._-Boundary" "_non" bp "")
; Get new polyline created
(setq en (entlast))

0 Likes
Message 10 of 14

nguyennhattanpt
Contributor
Contributor
Tkank BeekeecCZ.
At the end of the conference the error still appears, I also have the same error and cannot resolve it.
0 Likes
Message 11 of 14

Sea-Haven
Mentor
Mentor

Used bpoly for years, inside lisps or manual, I think you need to post a dwg so we can see what it is your trying to do. If its lisp post code as well.

0 Likes
Message 12 of 14

nguyennhattanpt
Contributor
Contributor
I usually use (command "_.boundary" ...) however recently I discovered there is a function (bpoly pt), assuming this function will run directly without going through cmd; So I want to learn to improve Autolisp's running speed
0 Likes
Message 13 of 14

pkenewell6347
Advocate
Advocate

Have you tried to use it via my last post? It does work and is simple. There are no other options or setup to use. The function - at least for now - is loaded by AutoCAD at startup.


Please again note however that this is an undocumented, unsupported function, so there is very little documentation on it's usage at all. Try searching for it in Autodesk's help in the product documentation or the developer's guide and it is non-existent.


If someone can correct me on this - Show me where the documentation exists because I would love to know as well. I think it is an ADS function written in C? Have they updated it?

0 Likes
Message 14 of 14

Sea-Haven
Mentor
Mentor

 (bpoly pt) not supported in Bricscad V20 maybe a later version. But help says exists.

0 Likes