Hi Todd,
How are you doing?
Hope this is the right thread to post this question. Do you know how to export automatically a JPG/WMF file from AutoCAD.
I tried this code, but it gives an failure and on internet/google we're no good examples
AutoCAD.AcadApplication.ActiveDocument.Export ("c:\"...
Hi Todd,
That's really cool (My dad is a couple of years older, I mean 43 but he never say cool :o) so helping 19year old students keeps you young :-D)
It works amazing fast, I think the whole proces, opening AutoCAD, the good drawing, checking how much prints he must make, saving and closing...
Hay Todd,
I made it working:
Y = "C:\Program Files\AutoCAD 2004\acad.exe /b Import " & [Forms]![AutoCAD Updater]![Tekst31]
Just the space between the /b and Import
It works great!!!!
Thanks!!!!!
Han
Hi Todd,
This is so weird, I try it several times with several quotes but it haven't the good effect...
I have a better solution. How can I run the script automatically on startup? (so no switches)
Then I load the original script:
Y = "C:\Program Files\AutoCAD 2004\acad.exe" &...
Hi Todd,
And just another doublepost :o)
we make steps further, it gives now the following error:
(exactly)
-
" import C:\AutoCAD\Tekeningen\250000.dwg"
-
What is chr(34)?
TIF
Han
Hi Todd,
Hopefully this time I'm smart :o)
Dim X, Y
Y = Chr(34) & "C:\Program Files\AutoCAD 2004\acad.exe" & Chr(34) & " /b " & Chr(34) & "import" & Chr(34) & [Forms]![AutoCAD Updater]![Tekst31]
X = Shell(Y, 1)
End Function
I tried it like this way but it gives the same error...
Hi Todd,
I have the solution:
AutoCAD.AcadApplication.RunMacro ("acad.dvb!import")
When I run it separatelly it works, cause else AutoCAD is opening.
Do you know the code for waiting/delay of 6 seconds, or something?
TIF
Han
Hi Todd,
I guess you're the one with the most knowlegde at AutoCAD customazium (hope I spell it correct :)) How old/young are you?
I had to say I learned a lot in the past period.
You're solution is perfectly working in the shortcut. (I edit the scriptfile to add a , to simultain an enter)...
Hi Todd,
Sorry for my bad explanation about the script. This is what the script do:
-import
-save
-exit
I loaded the script in acad.dvb like also the export script. Now I want a shortcut so autocad start automatically the script, saves and exit. So it's not allowed to run on every startup.
I...
Hi Todd,
Do you know how to handle the switch /b so the script will run automatically. I can load the script when AutoCAD is openening, but the script will shutdown AutoCAD when it print and saved
How can I turn of that compression?
TIF
Han
Hi Todd,
I'm playing with my little program and I've 2 questions:
- I start AutoCAD with the following code:
Y = "C:\Program Files\AutoCAD 2004\acad.exe /nologo " & [Forms]![Formulier1]![Tekst31]
The're is also a switch to start automatically a script: /b with the scriptname. I use the script...
Hi Todd,
Did you have a nice weekend?
My monday is perfect, the code is perfectly working!!!
AcadDoc.Plot.NumberOfCopies = rstAttribs.Fields("Aantal").Value
AcadDoc.Plot.PlotToDevice
'AcadDoc.Save
'AcadApplication.Quit
End Sub
Thanks a lot!!!
Han
Hi Todd,
Sorry for my long time being 'offline' I was busy with a lot of other projects.
I produced the following code, and it feels i'm very close...
AcadDoc.Plot.NumberOfCopies = "[Aantal]"
AcadDoc.Plot.PlotToDevice
'AcadDoc.Save
'AcadApplication.Quit
It give now a execution error. When...
Hi Todd,
It's in the Netherlands 21:38 and with a beer you create the best ideas :)
Maybe I can make a macro what runs the printingprogram.
Example:
-Open autocad
-Print code
loop=copies
Is this possible?
TIF
Han
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.