.NET

Reply
*James Allen
Message 21 of 36 (667 Views)

Re: Wait for SendStringToExecute to complete

08-07-2009 03:17 AM in reply to: timbot
I believe COM's SendCommand will do what you want if you call it from an
application context command.
See:
http://discussion.autodesk.com/forums/message.jspa?messageID=6215733#6215733


--
James Allen
Malicoat-Winslow Engineers, P.C.
Columbia, MO



jta_albert wrote:
> Yep, thats bascially what I reliazed... (about the sendstring not executing untill later)
>
> I would like to stay away from storing and jumping in and out of the code.
>
> Do you know if there is any way to send to the command line and have it run in sync?
>
*Tony Tanzillo
Message 22 of 36 (667 Views)

Re: Wait for SendStringToExecute to complete

08-07-2009 06:07 AM in reply to: timbot
http://www.caddzone.com/CommandLine.cs

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2009
Supporting AutoCAD 2000 through 2009

http://www.acadxtabs.com

Introducing AcadXTabs 2010:
http://www.caddzone.com/acadxtabs/AcadXTabs2010.htm

Email: string.Format("{0}@{1}.com", "tonyt", "caddzone");


wrote in message news:6232893@discussion.autodesk.com...
Yep, thats bascially what I reliazed... (about the sendstring not executing
untill later)

I would like to stay away from storing and jumping in and out of the code.

Do you know if there is any way to send to the command line and have it run
in sync?
*James Allen
Message 23 of 36 (667 Views)

Re: Wait for SendStringToExecute to complete

08-07-2009 06:19 AM in reply to: timbot
Oh yeah, I'd start with Tony's class/method unless you need application
context.

--
James Allen
Malicoat-Winslow Engineers, P.C.
Columbia, MO



James Allen wrote:
> I believe COM's SendCommand will do what you want if you call it from an
> application context command.
> See:
> http://discussion.autodesk.com/forums/message.jspa?messageID=6215733#6215733
>
>
> --
> James Allen
> Malicoat-Winslow Engineers, P.C.
> Columbia, MO
Contributor
timbot
Posts: 15
Registered: ‎09-23-2008
Message 24 of 36 (667 Views)

Re: Wait for SendStringToExecute to complete

08-07-2009 06:20 AM in reply to: timbot
Ok, a few questions about the thing i found on your web site. I've been trying to get autocad to zoom to a specific point based on what item is selected in a palette i'm making. the problem is that when i send my command it's .IsApplicationContext = True and returns 0. when i remove that code the command goes thru but nothing happens... i'm confused, it's returning like -5001 or something. but i can't find much information on the .IsApplicationContext = True or the code -5001. any help would be greatly appreciated!
*Tony Tanzillo
Message 25 of 36 (667 Views)

Re: Wait for SendStringToExecute to complete

08-07-2009 12:35 PM in reply to: timbot
From what code are you calling it? A floating palette or modeless form?

--
http://www.caddzone.com

AcadXTabs: MDI Document Tabs for AutoCAD 2009
Supporting AutoCAD 2000 through 2009

http://www.acadxtabs.com

Introducing AcadXTabs 2010:
http://www.caddzone.com/acadxtabs/AcadXTabs2010.htm

Email: string.Format("{0}@{1}.com", "tonyt", "caddzone");


wrote in message news:6233264@discussion.autodesk.com...
Ok, a few questions about the thing i found on your web site. I've been
trying to get autocad to zoom to a specific point based on what item is
selected in a palette i'm making. the problem is that when i send my command
it's .IsApplicationContext = True and returns 0. when i remove that code the
command goes thru but nothing happens... i'm confused, it's returning
like -5001 or something. but i can't find much information on the
.IsApplicationContext = True or the code -5001. any help would be greatly
appreciated!
Valued Contributor
jta_albert
Posts: 75
Registered: ‎01-10-2006
Message 26 of 36 (667 Views)

Re: Wait for SendStringToExecute to complete

08-10-2009 02:50 PM in reply to: timbot
Thanks Tony, the CommandLine.cs was exactly what I needed.

Not sure I udnerstand how it works though...
Contributor
timbot
Posts: 15
Registered: ‎09-23-2008
Message 27 of 36 (661 Views)

Re: Wait for SendStringToExecute to complete

08-13-2009 12:13 PM in reply to: timbot
floating palette
Valued Contributor
jta_albert
Posts: 75
Registered: ‎01-10-2006
Message 28 of 36 (661 Views)

Re: Wait for SendStringToExecute to complete

08-15-2009 02:08 PM in reply to: timbot
Turns out I do need application context(or "CommandFlags.Session") if thats what you mean.

Does this not work in "Session" mode?

If not is there another way in "Session"mode?

Jon
Valued Contributor
jta_albert
Posts: 75
Registered: ‎01-10-2006
Message 29 of 36 (661 Views)

Re: Wait for SendStringToExecute to complete

08-15-2009 02:24 PM in reply to: timbot
Hey Tony,

I ran into a problem using Commanline.cs in ApplicationContext.

Any help on using the command line in sync while in ApplicationContext(or "CommandFlags.Session" if I understand correctly)

Thanks,

Jon
*James Allen
Message 30 of 36 (660 Views)

Re: Wait for SendStringToExecute to complete

08-16-2009 02:01 PM in reply to: timbot
Hi Jon,

Yes, that's what I meant, in which case COM's SendCommand should work.

See my first reply to you, one up from the one you replied to, and the
thread it links to for more details.

--
James Allen
Malicoat-Winslow Engineers, P.C.
Columbia, MO



jta_albert wrote:
> Turns out I do need application context(or "CommandFlags.Session") if thats what you mean.
>
> Does this not work in "Session" mode?
>
> If not is there another way in "Session"mode?
>
> Jon
>
Announcements
Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.
Need installation help?

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