1

我正在使用 codedom 从我自己的代码中即时创建一个 EXE。

我可以设置所有属性,如 Title、Description、Company... 但我不能设置AssemblyName。任何想法如何做到这一点?这是我在 Class 之前添加的代码部分:

Imports System.Reflection
'This works but the AssemblyName is set to the name of the exe file:
'If I rename the exe the assembly name also changes.
<Assembly: System.Reflection.AssemblyTitle("Title123"> )
<Assembly: System.Reflection.AssemblyDescription("Description123">)
<Assembly: System.Reflection.AssemblyCompany("qxxx enterprises">)


'I tried to add the following but it throws me an error
'"AssemblyName" cannot be used as an attribute because it does not inherit from 'System.Attribute'
<Assembly: System.Reflection.AssemblyName("Testapp123"> )

关于如何设置 AssemblyName 的任何想法?(我不要求在 exe 编译后更改它。)

4

0 回答 0