I want to run regasm.exe from cmd. which is available in c:\windows\Microsoft.net\framework\2.057
I do like this c:\ regasm.exe
It gives regasm is not recognized as internal or external command.
So I understood that I need to set the path for regasm.exe in environment variable.
For which variable do I need to set the path to run regasm as described above?
I use the following in a batch file:
In command prompt:
If you created the DLL using .net 4.5 , then copy and paste this command on command prompt.
You don't need the directory on your path. You could put it on your path, but you don't NEED to do that.
If you are calling regasm rarely, or calling it from a batch file, you may find it is simpler to just invoke regasm via the fully-qualified pathname on the exe, eg:
Like Cheeso said:
%SystemRoot%\Microsoft.NET\Framework\v2.0.50727\regasm.exe MyAssembly.dll
I use this as post-build event in Visual Studio:
Depending on your Visual Studio version, use these environment variables instead:
VS90COMNTOOLS
VS100COMNTOOLS
VS110COMNTOOLS
VS120COMNTOOLS
VS140COMNTOOLS
VS150COMNTOOLS