• This forum is the machine-generated translation of www.cad3d.it/forum1 - the Italian design community. Several terms are not translated correctly.

incomplete vba code execution from script

  • Thread starter Thread starter Shape
  • Start date Start date

Shape

Guest
I have a problem, I have to run a macro on a set of drawings (500) :eek:

then I decide to use the powerful utility of rpor createfilescript and up to here everything well

open files
Run the macro all ok

But... but... the last command of the macro is a "sendcommand" i.e. switches to the command line of the commands (in this case the settings for the press _-plot etc etc etc etc etc etc.), here are not running them and opens the next file... :confused:

only in the last file is executed completely. . .

I have the pc too fast? :biggrin:
 
Quick solution: delete the part related to plotting, do the operations to all files and then print the run with another script.

bye and good weekend
 
Quick solution: delete the part related to plotting, do the operations to all files and then print the run with another script.

bye and good weekend
ehhh maybe it was so simple, it is not a print but a printing setting, which depends on size, scale etc operations that I carry out with the macro.

I try to insert a save so I hope the latency time increases and executes the command.
 
ehhh maybe it was so simple, it is not a print but a printing setting, which depends on size, scale etc operations that I carry out with the macro.

I try to insert a save so I hope the latency time increases and executes the command.
yes the sendcommand is asynchronous and vba does not wait for the execution of the command.
Put it on
Code:
private declare sub sleep lib "kernel32 " (byval dwmilliseconds as long
in the statements.
then immediately after the sendcommand put
Code:
sleep (700)
see if 700ms are a few or troops, some commands need more time so you'll have to do some tuning.
 
yes the sendcommand is asynchronous and vba does not wait for the execution of the command.
Put it on
Code:
private declare sub sleep lib "kernel32 " (byval dwmilliseconds as long
in the statements.
then immediately after the sendcommand put
Code:
sleep (700)
see if 700ms are a few or troops, some commands need more time so you'll have to do some tuning.
Thank you very much for the tip, for now I solved everything in vba without script.

However known with pleasure that the forum is populated with friulani. . .

:finger:
 

Forum statistics

Threads
44,997
Messages
339,767
Members
4
Latest member
ibt

Members online

No members online now.
Back
Top