.NET

Reply
New Member
emilia_m
Posts: 2
Registered: ‎08-23-2010
Message 1 of 5 (1,260 Views)

SendStringToExecute method

1260 Views, 4 Replies
08-23-2010 01:52 AM

In VB. Net sending commands directly to the AutoCAD command line by using SendStringToExecute method.
EchoCommand parameter set to False. Command sent not visible in the AutoCAD command line, but we can see it after clicking the right mouse. Is there any method to see .NET command as last one insteed the LISP one sent by .NET?

Valued Mentor
Jeffrey_H
Posts: 372
Registered: ‎01-20-2010
Message 2 of 5 (1,259 Views)

Re: SendStringToExecute method

08-23-2010 02:00 AM in reply to: emilia_m

go to options user perferences then click Right click customization and check settings

 

You can also find your answers @ TheSwamp
Valued Mentor
caddzone
Posts: 305
Registered: ‎01-26-2005
Message 3 of 5 (1,218 Views)

Re: SendStringToExecute method

08-23-2010 11:43 AM in reply to: emilia_m

No, and is why it's a bad idea to use SendStringToExecute()

to script AutoCAD commands, regardless of what you may

have read suggesting otherwise, on some Autodesk blog.

 

You can define a command using the CommandMethod

attribute, and add the CommandFlags.NoHistory flag to it.

From that method you can execute AutoCAD commands

synchronously using the code at the link below.

 

You can run your command with SendStringToExecute()

and AutoCAD will not repeat it when the user presses

enter, as long as it has the CommandFlags.NoHistory bit.

 

   http://www.caddzone.com/CommandLine.vb

   http://www.caddzone.com/CommandLine.cs

 



AcadXTabs for AutoCAD
Supporting AutoCAD 2000-2011


Valued Mentor
Jeffrey_H
Posts: 372
Registered: ‎01-20-2010
Message 4 of 5 (1,183 Views)

Re: SendStringToExecute method

08-24-2010 08:40 PM in reply to: caddzone

Tony T.

I thought I read somewhere when the user clicks a button on custom ribbon you built to use the SendStringToExecute method

Do you suggest doing that?

You can also find your answers @ TheSwamp
Valued Mentor
caddzone
Posts: 305
Registered: ‎01-26-2005
Message 5 of 5 (1,153 Views)

Re: SendStringToExecute method

08-26-2010 04:29 AM in reply to: Jeffrey_H

Sorry, I don't understand the question given the way it was put.

 

 



AcadXTabs for AutoCAD
Supporting AutoCAD 2000-2011


Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.