Jump to content

Recommended Posts

Posted

This code operate ok ::

  (command "-plot" "Y" "" "DWG TO PDF.PC3" "Iso full bleed A3 (420.00 x 297.00 MM)" "" "L" "" "Window" pt1 pt2 "F" "C" "" "" "" "" "" "" "" )

but when i just changed my printer shows following error:

 (command "-plot" "Y" "" "HP Deskjet 1280 series.PC3" "Iso full bleed A3 (420.00 x 297.00 MM)" "" "L" "" "Window" pt1 pt2 "F" "C" "" "" "" "" "" "" "" )

the error::

Command: Plot1
Select Lower Left Hand Corner
               of Plotting Area:
Thanks.......Unknown command "Plot1".  Press F1 for help.
Unknown command "L".  Press F1 for help.
Unknown command "PP".  Press F1 for help.
Unknown command "WINDOW".  Press F1 for help.
Unknown command "F".  Press F1 for help.
Unknown command "C".  Press F1 for help.
Unknown command "PP".  Press F1 for help.
Unknown command "PP".  Press F1 for help.
Unknown command "PP".  Press F1 for help.
Unknown command "PP".  Press F1 for help.
Unknown command "PP".  Press F1 for help.
Unknown command "PP".  Press F1 for help.
Unknown command "PP".  Press F1 for help.

o:)

Posted

Try setting CMDECHO to 1 and CMDDIA to 1 in order to debug these.

 

When plotting via (command ) you must have the exact sequence require that particular device. They are not all the same.

 

Also in lieu of a simple "", sometimes using the full parameter value can help.

Posted

When using the plot command, try walking through it manually to find the issue, or as David said, make sure you have you command echo on so you can see where the error occurred.

Posted

THIS IS FULL CODE:

(defun c:XSX ( )
(setvar 'CMDECHO 1)
(setvar 'CMDDIA 1)
    (setq pt1 (getpoint "\nSelect Lower Left Hand Corner
               of Plotting Area: "))
	(setq pt2 (list (+ 40 (car pt1)) (+ 27.8 (cadr pt1)) 0.))
   (prompt "\nThanks.......")
     (command "-plot" "Y" "" "HP Deskjet 1280 series.PC3" "Iso full bleed A3 (420.00 x 297.00 MM)" "" "L" "" "Window" pt1 pt2 "F" "C" "" "" "" "" "" "" "" )
    ;(command "-plot" "Y" "" "DWG TO PDF.PC3" "Iso full bleed A3 (420.00 x 297.00 MM)" "" "L" "" "Window" pt1 pt2 "F" "C" "" "" "" "" "" "" "" )
   (princ)
)

And this is compltet erorr:

Command: XSX
Select Lower Left Hand Corner
               of Plotting Area:
Thanks.......-plot Detailed plot configuration? [Yes/No] <No>: Y
Enter a layout name or [?] <Model>: Enter an output device name or [?] <EPSON Stylus Photo 1410 Series>: HP Deskjet 1280 series.PC3 Enter paper size or [?] <Letter>: Iso full bleed A3 (420.00 x 297.00 MM)
Command: XSX
Unknown command "XSX".  Press F1 for help.
Command: L Unknown command "L".  Press F1 for help.
Command: XSX
Unknown command "XSX".  Press F1 for help.
Command: Window Unknown command "WINDOW".  Press F1 for help.
Command:
Command:
Command: F Unknown command "F".  Press F1 for help.
Command: C Unknown command "C".  Press F1 for help.
Command: XSX
Unknown command "XSX".  Press F1 for help.
Command: XSX
Unknown command "XSX".  Press F1 for help.
Command: XSX
Unknown command "XSX".  Press F1 for help.
Command: XSX
Unknown command "XSX".  Press F1 for help.
Command: XSX
Unknown command "XSX".  Press F1 for help.
Command: XSX
Unknown command "XSX".  Press F1 for help.
Command: XSX
Unknown command "XSX".  Press F1 for help.
Command:

:o:o:o:o:o:o:o:o:o:o:o:o:o

Posted

make sure the string for your printer and paper size are exactly the same when you try it 'by hand'. use -plot to step through this proces and maybe copy and paste these strings. Sometimes a printer has size 'A3' while another uses 'A3 (420 x 297 mm) and then your code will fail

 

Gr. Rlx

Posted (edited)

GREAT THANXXXXXXXXXXXXX YOUR HELP David Bethel & Commandobill & rlx

IT'S OKEY NOW WITHYOUR HELP:):):):):):):):):)

 

And are there a way watch preview before plot in above code?????

Edited by hosyn
Posted

And if i wanna draw rectangle and plot ---I added rectangle code::

(setq pt1 (getpoint "\nSelect Lower Left Hand Corner of Plotting Area: "))
(setq pt2 (list (-(car pt1) 27. (+ 40 (cadr pt1)) 0.))
(command "._rectang" pt1 pt2 pause)
(command "-plot" "Y" "" "DWG TO PDF.PC3" "Iso full bleed A3 (420.00 x 297.00 MM)" "" "P" "" "Window" pt1 pt2 "F" "C" "" "" "" "" "" "" "" )

Just plot and didnt draw rectangle???WHY???:o

Posted

why the pause in the rectangle? Think you ment "" (enter)

 

Gr. Rlx

Posted

Thanxxxxxxxxxxxxxx rlx FIXXXXXXXXXXXXXXXXX

Posted

hosyn as I posted early each of my plot routines are hard coded for printer name and sheet size so I have 6 plot routines. You could have 1 routine but must ask user so you change the printer name and sheet size.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...