Help with CSC.EXE

A

AA2e72E

I am trying to compile a COM Interrop DLL from the command line and need to
pass this information

<RegisterForCOMInterop>true</RegisterForCOMInterop>

to CSC. This is usually found in the *.csproj file when 'Register For COM
Interop' is enabled from the VS2005 IDE.

I am not having any success; I am asking for guidance on the following:

1. HOw can I pass a *.csproj file together with *.cs files to CSC.EXE? I
have tried several ways without success.

2. Is there a way to include the XML snippet in the *.CS file?

3. Is there another way to switch RegisterforCOMInterop on for the DLL?

Thanks for your help.
 
M

Marc Gravell

1. HOw can I pass a *.csproj file together with *.cs files to CSC.EXE? I
have tried several ways without success.

You don't; you use "msbuild" to process a csproj, and it calls the C#
compiler for you.

I suspect that doing this will solve the other issues too.

Marc
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top