Forum Discussion
Pre Build Action in Windows Application Project
scoban Thanks - will try this.
The scenario I am trying to enable is this.
Project has a reference to LibraryA.dll , which is AnyCPU.
This LibraryA uses some platform specific dlls which are dynamically loaded using assembly resolver.
On the pre-build action, we copy files for both platforms to the output folder under sub folders x64 and x86, and then load depending on the platform on which app is running.
Do I need to do anything else to package above ?
Thanks
scoban Getting this error
Severity Code Description Project File Line Suppression State
Error PRI175: 0x8007000b - Processing Resources failed with error: An attempt was made to load a program with an incorrect format. AppSystem.Wap GENERATEPROJECTPRIFILE 1
Package format selected is neutral.
- scobanApr 22, 2020
Microsoft
abhisinghal Thats not enough to go off of, do you have a sample project I can look at? Try building for x86/x64 instead?
- abhisinghalApr 23, 2020Copper Contributor
scoban Tried with that too but no change.
PFA a simple sample project where the error is thrown when creating the package.
Please advise.
- scobanApr 23, 2020
Microsoft
abhisinghal I was able to successfully package that app with a more recent version of Visual Studio and even tried with a slightly older version. Try deleting your bin/obj folders (Clean the project).
Did you see the error with the sample project as well?