How to directly compile dll using Digital Mars in VS-Code

Hi All,

Is there any way to use compile the dll using Digital Mars directly from VS-Code?

I am not a professional programmer, so I am not really familiar with how to use any programing toolchain in detail…

Appreciate the support.
Thanks
Arief

Hi, Arief.

Attached is my build configurations file. Includes DMC, MSVC, and MinGW configs.

To use it, rename to *.json and put it in the project .vscode folder. Alternatively, edit your existing tasks.json file to add the DMC configuratiion from my config.

In the Terminal menu, select Configure Default Build Task, and then select the *** DMC 32-bit DLL *** item. To compile, make your *.cpp file the active open editor tab, then select Run Build Task from the Terminal menu.

–robert

tasks.json.txt (2.2 KB)

Hi Rob,

Excellent…thanks for quick response…

I am improving the PWM block example and modularize the code.

Without modularization, for a more complex circuit, my original code will become spaghetti monster soon

Thanks,
Arief

Hi, physicboy
Can use command line as .bat, then using Coder Runner in VS-Code, so you can compile all .dll by one click.
Command line:
cd “C:\QSpice\cpp_test”
“C:\program files\qspice\dm\bin\dmc.exe” -mn -WD cpp_test1_x1.cpp kernel32.lib

This command is provided by @RDunn , thanks a lot.
-Peter