ObjectARX
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Reply
Message 1 of 7
Anonymous
712 Views, 6 Replies

^C^C

How to emulate well known in AutoCAD "^C^C" statement, you know to cancel
the current command prompt, with ObjectARX?

Thanks
6 REPLIES 6
Message 2 of 7
Anonymous
in reply to: Anonymous

Try sending two ESC's to the command line, like:

acedGetAcadTextCmdLine()->SendMessage(WM_CHAR, VK_ESCAPE, 0);

acedGetAcadTextCmdLine()->SendMessage(WM_CHAR, VK_ESCAPE, 0);

There might be a better way than that now, but that is how we used to do
it...

Jim Awe
Autodesk, Inc.

"HokuS" wrote in message
news:4885775@discussion.autodesk.com...
How to emulate well known in AutoCAD "^C^C" statement, you know to cancel
the current command prompt, with ObjectARX?

Thanks
Message 3 of 7
Anonymous
in reply to: Anonymous

You can also use:

extern int acedPostCommand(char const *)

like this:

acedPostCommand("\03\03");

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006
http://www.acadxtabs.com

"HokuS" wrote in message news:4885775@discussion.autodesk.com...
How to emulate well known in AutoCAD "^C^C" statement, you know to cancel
the current command prompt, with ObjectARX?

Thanks
Message 4 of 7
chuck.han
in reply to: Anonymous

I don't think acedPostCommand() is available in ObjectArx 2006. You can try using:

acDocManagerPtr()->sendStringToExecute(acDocManagerPtr()->curDocument(), "\x1B\x1B");

But remember that AutoCAD might not executed it when you want it to...
Message 5 of 7
Anonymous
in reply to: Anonymous

wrote

>> I don't think acedPostCommand() is available in ObjectArx 2006.

It certainly is.

Were it not available, I would have a few broken
apps that would not work at all.

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2004/2005/2006
http://www.acadxtabs.com
Message 6 of 7
chuck.han
in reply to: Anonymous

Huh.

Sorry to continue this discussion in this thread, but I don't know how else to contact Tony (your website has a contact link, but it doesn't lead to any contact info).

I can't find any reference to acedPostCommand() in the ObjectArx online reference (index/search) or the index of the hardcopy ObjectArx Developer's Guide (both for AutoCAD 2006). Is it supported/deprecated but not documented? Something else?

thanks, Chuck
Message 7 of 7
Anonymous
in reply to: Anonymous

Hi, chuck.han!
This function is not documented and is not supported, but working in AutoCAD R14...2006 .
It exported by acad.exe and is in acad.lib You need add this statement your's code:

extern int acedPostCommand(char const *cmd);

After then you can use acedPostCommand("\03\03") for canceling any active command;

ch> I can't find any reference to acedPostCommand() in the ObjectArx online
ch> reference (index/search) or the index of the hardcopy ObjectArx
ch> Developer's Guide (both for AutoCAD 2006). Is it supported/deprecated
ch> but not documented? Something else?

Best Regards,
Alexander Rivilis.

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

Post to forums  

Autodesk Design & Make Report

”Boost