Build error after importing Net Express project with import wizard

I imported an NX project with 7 programs and no Dialog System screenset.  When I build the resulting solution I get this error:

Could not copy the file "obj\x86\Debug\AW100" because it was not found.  Microsoft.Common.Targets line 3364.

We are running Visual Studio 2010 SP1 and Visual COBOL 2.1.  The project name is AW100 and includes a program named AW100.  It is an INT/GNT project.


  • This happens for every INT/GNT project I import and only when building a project in this directory.  I imported INT/GNT projects in another directory and I don't get the error.  Link library (dll) projects do not give this error when built.  The output path is set to DEBUG for all projects which is one level down from the directory holding the source, VS solution and VS project files.

  • Hi Phil, Can you please open up a support incident for this issue?

    I will most likely have to get you to zip up the original folder and send it to me.

    Reference my name in the incident to ensure that it is assigned to me.


  • Verified Answer

    Worked with customer on support incident.

    This problem is caused by using the same root folder for multiple projects that are imported where some projects are .dll projects and some are .int/.gnt.

    Because the projects are in the same folder they share a common obj\x86\debug folder which is where the build places the temporary .obj files when linking.

    The build process checks to see if there is an .obj file present in obj\x86\debug folder and if there is it will trigger a copy of the output file from the obj\x86\debug folder to the actual output folder.

    This works fine for .dll projects as the output file .dll will be placed in the obj\x86\debug folder and the copy will suceed.

    Under normal circumstances this will also work for an .int/gnt project because they do not generate .obj files into obj\x86\debug so the copy will not be attempted. The .int or .gnt is created directly in the output folder.

    The problem occurs when a .dll project build is done prior to an .int/gnt project build because the resulting .obj file will still remain in obj\x86\debug so it tries to copy an output file that doesn't exist.

    This problem can be solved by adding a prebuild event command of

       del $(SolutionDir)\obj\x86\debug\*.obj

    under Project-->Properties-->COBOL-->Build events.

    This causes the .obj files to be removed from obj\x86\debug before starting the build.