I am creating an executable with VB.NET using CodeDomProvider.
Is there a way to change the icon before the compiler creates the exe file?
You can set the icon of the generated exe by specifying it in the CompilerParameters , which you go to the code provider using the CompilerOptions property .
Dim parameters As New CompilerParameters() parameters.CompilerOptions = "/win32icon:C:\full\path\to\icon.ico"
Then you pass these parameters to the CompileAssemblyFromSource method . The generated exe will use the specified icon as the icon of its application.
Go to the project properties and select the icon. Just like that.
RessourcesHacker . ,