Autodesk Technology Managers Forum
Share your knowledge, ask questions, and engage with fellow CAD/BIM Managers.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

PGP shortcut different from full command entry for BLOCKREPLACE

21 REPLIES 21
Reply
Message 1 of 22
Seneb
1293 Views, 21 Replies

PGP shortcut different from full command entry for BLOCKREPLACE

One of our users has added BB to his PGP for the BLOCKREPLACE command. However, when he types in BB, the dialog box doesn't come up. It just prompts a menu in the command line. Any idea why this happens, or how to modify it to bring up the dialog?
www.gears4good.org
CAD / 3D / Graphics / Photography
21 REPLIES 21
Message 2 of 22
Anonymous
in reply to: Seneb

Works fine here: unless the user entered his changes at the very bottom of
the PGP file, there might be a later BB definition calling up another
command.

--
Dean Saadallah
http://LTisACAD.blogspot.com
--
Message 3 of 22
Anonymous
in reply to: Seneb

blockreplace doesn't work on dynamic blocks....


another acad thing that needs to be addressed because of dynamic blocks...


TDP

wrote in message news:6328800@discussion.autodesk.com...
One of our users has added BB to his PGP for the BLOCKREPLACE command.
However, when he types in BB, the dialog box doesn't come up. It just
prompts a menu in the command line. Any idea why this happens, or how to
modify it to bring up the dialog?
Message 4 of 22
Seneb
in reply to: Seneb

Strange. I just checked and it was at the bottom, and there isn't another BB command. I tried placing it in the main list, and that didn't work either. It's acting the same as typing "-BLOCKREPLACE" in the command line.

It does the exact same thing on my system.
www.gears4good.org
CAD / 3D / Graphics / Photography
Message 5 of 22
Anonymous
in reply to: Seneb

Exact AutoCAD version?

--
Dean Saadallah
http://LTisACAD.blogspot.com
--
Message 6 of 22
Seneb
in reply to: Seneb

That shouldn't have any bearing on how the command functions. I'm simply trying to figure out why the shortcut doesn't bring up the dialog box, and the full command does.
www.gears4good.org
CAD / 3D / Graphics / Photography
Message 7 of 22
Seneb
in reply to: Seneb

Vanilla 2010, Dean. Edited by: seneb on Feb 3, 2010 8:04 AM
www.gears4good.org
CAD / 3D / Graphics / Photography
Message 8 of 22
Anonymous
in reply to: Seneb

Well, there is a command line version of that, are you sure about the
shortcut spelling?

See if someone else around here can replicate. Sorry, I can't get it to
default to that here.

--
Dean Saadallah
http://LTisACAD.blogspot.com
--
Message 9 of 22
Anonymous
in reply to: Seneb

seneb wrote:
> One of our users has added BB to his PGP for the BLOCKREPLACE command. However, when he types in BB, the dialog box doesn't come up. It just prompts a menu in the command line. Any idea why this happens, or how to modify it to bring up the dialog?

try adding a . (period) before as in ".blockreplace"
Message 10 of 22
Seneb
in reply to: Seneb

I tried that and it didn't work. I changed the shortcut to BBB and the dialog came up. BB is not in the PGP but still works as BLOCKREPLACE in the command line. This lead me to believe that BB is sitting in a file somewhere. I found the lisp file in our standards folder, and in the lisp code, BB was listed as the command line shortcut for the routine. I changed the coding to BBB, so now BB brings up the dialog box and BBB keeps it in the command line.
www.gears4good.org
CAD / 3D / Graphics / Photography
Message 11 of 22
Anonymous
in reply to: Seneb

Ah, you have a Lisp or ARX loading with BB defined. It will override PGP all
the time. Good catch.

--
Dean Saadallah
http://LTisACAD.blogspot.com
--
Message 12 of 22
Seneb
in reply to: Seneb

Thanks, Dean.
www.gears4good.org
CAD / 3D / Graphics / Photography
Message 13 of 22
dgorsman
in reply to: Seneb

A quickie check for things like this is to preceed the text with an exclamation e.g. !BB. Depending on where the function is defined you will get different results. This is also a good argument for verbosely defining functions e.g. "callThisFunctionHere" instead of "CTF".
----------------------------------
If you are going to fly by the seat of your pants, expect friction burns.
"I don't know" is the beginning of knowledge, not the end.


Message 14 of 22
Anonymous
in reply to: Seneb

This is exactly why I NEVER use a shortened command name in a
LISP file. IMO, LISP files should always be a "long" descriptive name
and let the PGP file handle the shortcuts. If I were you I'd remove
the shortcut from the LISP file rather than changing it to BBB.


wrote in message news:6330413@discussion.autodesk.com...
> I found the lisp file in our standards folder, and in the lisp code,
> BB was listed as the command line shortcut for the routine.
Message 15 of 22
Seneb
in reply to: Seneb

Just for the record, I didn't write the LISP. In fact, I know only enough about LISP to read the coding and basically follow the process to find what I need.
www.gears4good.org
CAD / 3D / Graphics / Photography
Message 16 of 22
Anonymous
in reply to: Seneb

I wasn't assuming you wrote it.

I see folks, ones which I respect their coding ability a great deal,
posting code with these shortcuts defined in the LISP file. It's
simply bad practice to do so, IMO.

wrote in message news:6331358@discussion.autodesk.com...
Just for the record, I didn't write the LISP. In fact, I know only enough about LISP to read the coding and basically follow the
process to find what I need.
Message 17 of 22
Anonymous
in reply to: Seneb

Good advice.

--
Dean Saadallah
http://LTisACAD.blogspot.com
--
Message 18 of 22
Anonymous
in reply to: Seneb

On Fri, 5 Feb 2010 09:27:03 -0800, Jason Piercey wrote:

>I see folks, ones which I respect their coding ability a great deal,
>posting code with these shortcuts defined in the LISP file. It's
>simply bad practice to do so, IMO.

It's not "bad practice" at all. Smaller LISP symbol names take up less memory
and system resources than overly long ones, and you don't have to define
shortcuts for them in the PGP file.

This also relieves you of having people needing to coordinate their own PGP file
with your macros as you update things.

IMO, in most cases people who write "global" LISP routines and functions do so
to provide users with a list of shortcuts for complex command macros that are
simply impossible using the PGP, due to its inherent limitations. People can
infill the PGP with shortcuts on their own which do not interfere with the
master global list.

When you want to give your users the chance to change the command macro used,
you have a couple of choices, including your method. But to me, it's
easier/better IMO to write a function that allows users to redefine your LISP
routines to a new shortcut symbol, remove your old symbol from memory, and use
their own PGP shortcuts.

For example, in a user's .lsp file, which could be set to load in each
drawing, you can do something like this:

;; Redefine standard LSP command macros
;; Usage:
;; (ReDefineMattsCommand C:MattsCommandName C:YourCommandName)

(ReDefineMattsCommand c:c c:co) ;; redefines my global "Copy" macro to "CO"

Then in their ACAD.PGP, the user would have this:

C *COLOR

Matt
matt@stachoni.com
Message 19 of 22
Anonymous
in reply to: Seneb

"Matt Stachoni" <...> wrote in message news:6331444@discussion.autodesk.com...

> It's not "bad practice" at all. Smaller LISP symbol names take up less memory
> and system resources than overly long ones, and you don't have to define
> shortcuts for them in the PGP file.

Is memonry consumption really much of an issue these days? I think not.
After all, we are talking smigends here not resource hogs (like 2010). At
one point long ago I'd agree with you, but not in today's world of PCs.


> This also relieves you of having people needing to coordinate their own PGP file
> with your macros as you update things.

I don't care what/how people define their own PGP file. A shortcut that
works for me, may not for them. I choose to be flexible in this case. I use
Z for zoom, a friend of mine uses Q because it's easier for them. Whatever
works for the individual user is fine with me. I rarely change the names of
LISP commands so coordination of PGP file content is moot in this office.
Message 20 of 22
Anonymous
in reply to: Seneb

neither method is really bad prasctice if implemented and communicated
properly. Myself I have a lisp that sifst through everyone's .pgp and comes
up with an availability list. I then inform the users which two letter
commands I will be using and leave the single ones for them. they have a
list of the double/triple letter commands that are available. And I have
room to grow on my side as I add function shortcuts.

I'm with matt on command lengths though. I prefer to limit them to 3 chars
long.
I mean 36^3 is a lot more commands than anyone cares to try to remember.

--
TDP

First things first, but not necessarily in that order.

The Doctor
"Jason Piercey" wrote in message
news:6331457@discussion.autodesk.com...
"Matt Stachoni" <...> wrote in message
news:6331444@discussion.autodesk.com...

> It's not "bad practice" at all. Smaller LISP symbol names take up less
> memory
> and system resources than overly long ones, and you don't have to define
> shortcuts for them in the PGP file.

Is memonry consumption really much of an issue these days? I think not.
After all, we are talking smigends here not resource hogs (like 2010). At
one point long ago I'd agree with you, but not in today's world of PCs.


> This also relieves you of having people needing to coordinate their own
> PGP file
> with your macros as you update things.

I don't care what/how people define their own PGP file. A shortcut that
works for me, may not for them. I choose to be flexible in this case. I
use
Z for zoom, a friend of mine uses Q because it's easier for them. Whatever
works for the individual user is fine with me. I rarely change the names of
LISP commands so coordination of PGP file content is moot in this office.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Administrator Productivity


Autodesk Design & Make Report