I have created a console app referencing http://www.antlr.org/download/CSharp
using System;
using Antlr.StringTemplate;
using Antlr.StringTemplate.Language;
That I want to compile by command line with
csc /r:c\antlr\antlr.runtime.dll;c\antlr\StringTemplate.dll myprog.cs
It created the exe but when executing it says it cannot find StringTemplate or dependencies why ? I have all dll package in same directory.
Update: the same program build under visual studio works but I need to do this by command line.
Update 2: even copied to exe path it still can’t find them weird !
Update 3: ok finally works I confused visual studio bin output and my csc output dir.
That’s because you are not using the friendly IDE that takes care of these details for you. Since you’re doing this by hand, it is up to you to copy the DLLs yourself.
The DLLs are now in the EXE’s ‘probing path’, it won’t have any trouble finding them.