.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

sendstringtoexecute from a modelless form

6 REPLIES 6
Reply
Message 1 of 7
Anonymous
311 Views, 6 Replies

sendstringtoexecute from a modelless form

i invoke a "sendstringtoexecute" from a modelless form but this command dont
work because it is queue in application execution context so, how can i
execute this command ?
6 REPLIES 6
Message 2 of 7
Anonymous
in reply to: Anonymous


SendStringToExecute() from a modeless form works for
me.

 


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
i
invoke a "sendstringtoexecute" from a modelless form but this command
dont
work because it is queue in application execution context so, how can
i
execute this command ?
Message 3 of 7
Anonymous
in reply to: Anonymous



I am in application context and i need to
execute sendstringtoexecute in document contest and i dont know how to do
it.

I was reading your program at
href="http://www.caddzone.com/PaletteUtils.cs">http://www.caddzone.com/PaletteUtils.cs
 but
i am a beginner of VB so i am in trouble.

Can you help me Tony?

 

 

 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


SendStringToExecute() from a modeless form works for
me.

 


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
i
invoke a "sendstringtoexecute" from a modelless form but this command
dont
work because it is queue in application execution context so, how
can i
execute this command ?
Message 4 of 7
Anonymous
in reply to: Anonymous


Sorry, I don't understand what you mean by 'need to execute

sendstringtoexecute in document context'. 

 

You call SendStringToExecute() from the
size=2>application context

(e.g., a Click handler of a button on a
palette)
to execute commands.

 

PaletteUtils.cs is somewhat advanced and requires that
one

has some understanding and knowledge of the API.


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">



I am in application context and i need to
execute sendstringtoexecute in document contest and i dont know how to do
it.

I was reading your program at
href="http://www.caddzone.com/PaletteUtils.cs">http://www.caddzone.com/PaletteUtils.cs
 but
i am a beginner of VB so i am in trouble.

Can you help me Tony?

 

 

 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


SendStringToExecute() from a modeless form works for
me.

 


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
i
invoke a "sendstringtoexecute" from a modelless form but this command
dont
work because it is queue in application execution context so, how
can i
execute this command
?
Message 5 of 7
Anonymous
in reply to: Anonymous


i have a symple program running in a
palette

it let me select files, after it open
they one by time, make some command (i.e. zoom extend) and save it.

The problem is that they are saved before the
command is executed in document context.

 

 

 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


Sorry, I don't understand what you mean by 'need to execute

sendstringtoexecute in document context'. 

 

You call SendStringToExecute() from the
size=2>application context

(e.g., a Click handler of a button on a
palette)
to execute commands.

 

PaletteUtils.cs is somewhat advanced and requires that
one

has some understanding and knowledge of the
API.


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">



I am in application context and i need to
execute sendstringtoexecute in document contest and i dont know how to do
it.

I was reading your program at
href="http://www.caddzone.com/PaletteUtils.cs">http://www.caddzone.com/PaletteUtils.cs
 but
i am a beginner of VB so i am in trouble.

Can you help me Tony?

 

 

 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


SendStringToExecute() from a modeless form works for
me.

 


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
i
invoke a "sendstringtoexecute" from a modelless form but this command
dont
work because it is queue in application execution context so,
how can i
execute this command
?
Message 6 of 7
Anonymous
in reply to: Anonymous


You're not showing any code that would allow someone to

diagnose the problem, so i'm guessing that you are calling
the

SaveAs() method after calling SendStringToExecute(). If
that's

the case it explains what's happening.

 

You will need to find a way to wait until the last command
you

send to the command line has finished (the CommandEnded
event

sounds like it might work), and when it has, then you can
call

the SaveAs() method, or send "QSAVE" to the command line
if

you are saving back to the same file.


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


i have a symple program running in a
palette

it let me select files, after it open
they one by time, make some command (i.e. zoom extend) and save
it.

The problem is that they are saved before the
command is executed in document context.

 

 

 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


Sorry, I don't understand what you mean by 'need to
execute

sendstringtoexecute in document context'. 

 

You call SendStringToExecute() from the
size=2>application context

(e.g., a Click handler of a button on
a palette)
to execute commands.

 

PaletteUtils.cs is somewhat advanced and requires that
one

has some understanding and knowledge of the
API.


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">



I am in application context and i need
to execute sendstringtoexecute in document contest and i dont know how to
do it.

I was reading your program at
href="http://www.caddzone.com/PaletteUtils.cs">http://www.caddzone.com/PaletteUtils.cs
 but
i am a beginner of VB so i am in trouble.

Can you help me
Tony?

 

 

 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


SendStringToExecute() from a modeless form works for
me.

 


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
i
invoke a "sendstringtoexecute" from a modelless form but this command
dont
work because it is queue in application execution context so,
how can i
execute this command
?
Message 7 of 7
Anonymous
in reply to: Anonymous


thanksss... i will try


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


You're not showing any code that would allow someone to

diagnose the problem, so i'm guessing that you are calling
the

SaveAs() method after calling SendStringToExecute(). If
that's

the case it explains what's happening.

 

You will need to find a way to wait until the last command
you

send to the command line has finished (the CommandEnded
event

sounds like it might work), and when it has, then you can
call

the SaveAs() method, or send "QSAVE" to the command line
if

you are saving back to the same file.


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


i have a symple program running in a
palette

it let me select files, after it open
they one by time, make some command (i.e. zoom extend) and save
it.

The problem is that they are saved before the
command is executed in document context.

 

 

 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


Sorry, I don't understand what you mean by 'need to
execute

sendstringtoexecute in document context'. 

 

You call SendStringToExecute() from the
size=2>application context

(e.g., a Click handler of a button
on a palette)
to execute commands.

 

PaletteUtils.cs is somewhat advanced and requires that
one

has some understanding and knowledge of the
API.


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">



I am in application context and i need
to execute sendstringtoexecute in document contest and i dont know how
to do it.

I was reading your program at
href="http://www.caddzone.com/PaletteUtils.cs">http://www.caddzone.com/PaletteUtils.cs
 but
i am a beginner of VB so i am in trouble.

Can you help me
Tony?

 

 

 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">


SendStringToExecute() from a modeless form works for
me.

 


 

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

href="http://www.acadxtabs.com">http://www.acadxtabs.com

 


 

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
i
invoke a "sendstringtoexecute" from a modelless form but this
command dont
work because it is queue in application execution
context so, how can i
execute this command
?

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

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost