User Controls not showing up in the toolbox

前端 未结 29 2176
暗喜
暗喜 2020-12-13 12:21

I have some UserControls that I created in ProjectA. I have ProjectB that has a windows form that I want to put the controls on. Both of these projects are in a single sol

29条回答
  •  隐瞒了意图╮
    2020-12-13 12:29

    I was trying to build a x64 only application, so my platform target was set to x64 of course.

    However, even in 2016, Visual Studio (devenv.exe) is still a 32 bit process and it cannot load 64 bit assemblies. To check the bitness of your Visual Studio, open Task Manager and check for *32 at the name of the process.

    Workaround to see the Controls in the toolbox: set the platform target to Any CPU in the project settings. Do that for Debug and Release build, if necessary.

提交回复
热议问题