has anyone ever seen this dialog, random block names no longer assigned

has anyone ever seen this dialog, random block names no longer assigned

Anonymous
Not applicable
1,433 Views
9 Replies
Message 1 of 10

has anyone ever seen this dialog, random block names no longer assigned

Anonymous
Not applicable

when ever I use ctrl + shift + V to paste from the clipboard I get this dialog, have never seen this before and want to get rid of it. it wants to give blocks a name instead of assigning random names like usual

 
 

 

IMAGE1.png

0 Likes
Accepted solutions (1)
1,434 Views
9 Replies
Replies (9)
Message 2 of 10

RobDraw
Mentor
Mentor

That's a new one by me, too.

 

Do you have any standalone attributes in what you are trying to paste?


Rob

Drafting is a breeze and Revit doesn't always work the way you think it should.
0 Likes
Message 3 of 10

Anonymous
Not applicable
Accepted solution
Thanks for responding it is in the acad.lsp file someone has redefined the copypaste command to display that dialog and not assign a random name.

Thanks again
I just found it
Message 4 of 10

Anonymous
Not applicable

I'm with @RobDraw - never seen this behavior either

Tested with several random objects, both with blocks and also random geometry, text, etc. (including/not including a standalone attribute) and I can't reproduce it....

AutoCAD (plain vanilla, no add-ins) 2020.1.2

My opinion is exactly the opposite of yours however, as there are times I would consider this useful. If you figure out how you got ACAD to behave this way, please post!

0 Likes
Message 5 of 10

Anonymous
Not applicable
the problem is someone added and redefined the command in autolisp below you will find the autolisp file that autoloads to do the task you can find the lines very near the top of the file.
I just found this. And yes some people find this very useful others not so much.
Good luck and thanks for responding.
Ken
0 Likes
Message 6 of 10

Anonymous
Not applicable

No attachment- I think you will have to either zip it or insert the plain text into a post. Sometimes active content filters get in the way of useful stuff

Thanks in advance!

0 Likes
Message 7 of 10

Anonymous
Not applicable
if you send me the your email, and if not here is the text to insert near the top of the file.


;; PasteBlockWithName.lsp
;; To require a User-supplied Name for each Block created with the PasteBlock command,
;; at insertion, avoiding the native command's meaningless names, e.g. "A$C578A4EC7".
;; UNDEFINES and MAKES A NEW DEFINITION OF the PasteBlock command.
;; Kent Cooper, last edited 24 June 2015

;; To preserve AutoCAD's PasteBlock command definition, remove the following lines:
(setq cmde (getvar 'cmdecho))
(setvar 'cmdecho 0)
(command "_.undefine" "PASTEBLOCK")
(setvar 'cmdecho cmde)
(setq cmde nil)
;; and Redefine PasteBlock if necessary, CHANGE the COMMAND NAME in the
;; next line of code to something appropriate [it will then NOT be invoked by
;; Ctrl+Shift+V], and adjust descriptive comments above and prompt at end.
(defun C:PASTEBLOCK (/ newname cmde); new definition
(while
(not
(and
(setq newname (lisped "Name for Block to be Inserted"))
; calls up Text Editor with content pre-selected for replacement
(setq newname (vl-string-trim " " newname)); remove any leading/trailing space(s)
(/= newname ""); didn't either clear out or enter only space(s)
(/= newname "Name for Block to be Inserted"); didn't just hit Enter
(not (tblsearch "block" newname)); name not already in use
); and
); not
(alert
(cond
((= newname "") "Empty string or only space(s) not allowed;\nyou must supply a Block name.")
((= newname "Name for Block to be Inserted") "You must supply a new Block name."); Enter only
(T "\nThat Block name is already in use.")
); cond
); alert
); while
(command "_.pasteblock")
(while (> (getvar 'cmdactive) 0) (command pause))
;; finish _.PASTEBLOCK including possible Scale/Rotate options, etc.
(setq cmde (getvar 'cmdecho))
(setvar 'cmdecho 0)
(command "_.rename" "_block" (cdr (assoc 2 (entget (entlast)))) newname)
(setvar 'cmdecho cmde)
(princ)
); defun

my email is [email protected]

0 Likes
Message 8 of 10

ВeekeeCZ
Consultant
Consultant

It's build-in small STRING editor for LISP functions usage. Type this to your command-line to see...

(lisped "Name for block...")

It looks like you have some custom routine assigned to your shortcut.

 
0 Likes
Message 9 of 10

Anonymous
Not applicable

Got it, thanks again!

0 Likes
Message 10 of 10

cadffm
Consultant
Consultant

@ВeekeeCZ  schrieb:

 

It looks like you have some custom routine assigned to your shortcut.

 

CTRL+SHIFT+V start the _pasteblock command, it's the standard shortcut function

Sebastian

0 Likes