I use a custom JS file to convert DWG/DXF files to PNG via the command line:
qcadcmd.com -platform offscreen -no-gui -autostart scripts/dwg2png.js -input input.dwg -output output.png 2>error.log
The JS file can be loaded and executed, but the conversion to PNG did not succeed.
Additionally, how to suppress debug messages in the console output and keep only errors?
Environment
Windows10
Qcad 3.23.3 pro
I use a custom JS file to convert DWG/DXF files to PNG via the command line
Moderator: andrew
Forum rules
Always indicate your operating system and QCAD version.
Attach drawing files and screenshots.
Post one question per topic.
Always indicate your operating system and QCAD version.
Attach drawing files and screenshots.
Post one question per topic.
-
- Junior Member
- Posts: 20
- Joined: Wed Jun 11, 2025 2:33 am
I use a custom JS file to convert DWG/DXF files to PNG via the command line
- Attachments
-
- 53bfe443b0e82.dwg
- (333.16 KiB) Downloaded 124 times
-
- dwg2png.js
- (7.11 KiB) Downloaded 158 times
- andrew
- Site Admin
- Posts: 8774
- Joined: Fri Mar 30, 2007 6:07 am
Re: I use a custom JS file to convert DWG/DXF files to PNG via the command line
May I ask if this is AI generated code? Since much of the API is dreamed up and non-existent.
Also, are you aware of dwg2bmp which comes with every installation of QCAD Professional and converts DXF and DWG files to many bitmap formats including PNG?
Under Linux, macOS or cygwin (Windows), you can use grep to filter messages. In the standard Windows command line, there's probably no easy way.
Also, are you aware of dwg2bmp which comes with every installation of QCAD Professional and converts DXF and DWG files to many bitmap formats including PNG?
Under Linux, macOS or cygwin (Windows), you can use grep to filter messages. In the standard Windows command line, there's probably no easy way.