Can no longer build vb.net solution due to missing file error

wayneray
wayneray used Ask the Experts™
on
I am building an inventory solution for a friend and after making changes to the solution, I cannot get the solution to build. The error is "Cannot find file 'filename'.  The associated error number is MSB3113. When I double-click the error it opens a target file and  the line of the error starts with <GenerateApplicationManifest. I am using the express version of Visual Studio 2017. The solution will allow me to revert to the last successful build which was last night.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Shaun VermaakTechnical Specialist
Awarded 2017
Distinguished Expert 2018

Commented:
Can you share the project?

Author

Commented:
Hi Shaun. I have never shared one of my projects. Do you mean attach all the vb files?

Author

Commented:
I mean project files?
Bootstrap 4: Exploring New Features

Learn how to use and navigate the new features included in Bootstrap 4, the most popular HTML, CSS, and JavaScript framework for developing responsive, mobile-first websites.

Shaun VermaakTechnical Specialist
Awarded 2017
Distinguished Expert 2018

Commented:
Yes, zipping and attaching the project so that I can see error and try to fix it.

If it is confidential you should not share it
DevAdminSystem Engineer | .NET Developer | Microsoft MVP | Technical Speaker

Commented:
From this https://docs.microsoft.com/en-us/previous-versions/ms228164(v=vs.140) the reason of the error can be a reference of your project

Author

Commented:
There are parts of my project that are sensitive to my client. I am really trying to understand what I did between last night and this morning for my project to forget where the database file is when building. My computer did shut down last night and the program was still open. I don't recall changing any references.
Peter HutchisonSenior Network Systems Specialist

Commented:
Open the project or solution file in notepad and check that all files listed are actually in the project. If its referencing a DLL then make sure that is installed too.
Do you know what references the project has included? Are they all .NET references or does it has some old COM references?

Author

Commented:
When I open the solution file in notepad, this is the contents of the file.

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.27703.2026
MinimumVisualStudioVersion = 10.0.40219.1
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "PolydyneInventory", "PolydyneInventory\PolydyneInventory.vbproj", "{C77EBBB2-1A77-498F-A313-565D7959FCF4}"
EndProject
Global
      GlobalSection(SolutionConfigurationPlatforms) = preSolution
            Debug|Any CPU = Debug|Any CPU
            Release|Any CPU = Release|Any CPU
      EndGlobalSection
      GlobalSection(ProjectConfigurationPlatforms) = postSolution
            {C77EBBB2-1A77-498F-A313-565D7959FCF4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
            {C77EBBB2-1A77-498F-A313-565D7959FCF4}.Debug|Any CPU.Build.0 = Debug|Any CPU
            {C77EBBB2-1A77-498F-A313-565D7959FCF4}.Release|Any CPU.ActiveCfg = Release|Any CPU
            {C77EBBB2-1A77-498F-A313-565D7959FCF4}.Release|Any CPU.Build.0 = Release|Any CPU
      EndGlobalSection
      GlobalSection(SolutionProperties) = preSolution
            HideSolutionNode = FALSE
      EndGlobalSection
      GlobalSection(ExtensibilityGlobals) = postSolution
            SolutionGuid = {75D10608-770E-4DB0-9D31-901D8FFDFE11}
      EndGlobalSection
EndGlobal

Author

Commented:
I opened the project file and I am looking through the file. When I try to start the program inside the solution I get the error message " There are build errors. Would you like to Continue and run the last successful build? Below is content from the output window.

Severity      Code      Description      Project      File      Line      Suppression State

Error            Could not find file 'Polydyne.accdb'.      PolydyneInventory      C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets      3863      

The file is there but ...

Author

Commented:
When I opened the project file I located the database file section. Here it is.

<ItemGroup>
    <PublishFile Include="Polydyne.accdb">
      <Visible>False</Visible>
      <Group>
      </Group>
      <TargetPath>
      </TargetPath>
      <PublishState>DataFile</PublishState>
      <IncludeHash>True</IncludeHash>
      <FileType>File</FileType>
    </PublishFile>
  </ItemGroup>
Senior Network Systems Specialist
Commented:
A database really should not be part of a Visual Studio project. Try removing it from the project and rebuild. If it is not showing in the solution explorer, enable 'Show all files' in the Project menu.

Commented:
I have faced this error before ..... I think it's simple to fix .....
First which build method do you use .... ? ...... if you use "setup project" ....Try to close your Visual studio then open it again i think the problem will disappear .... If not check in the solution explorer of your setup project name (right click on it and choose view to open  file system)===>>>from file system open application folder and check if any file has underline with a blue line (try to right click to the application folder then add file and choose it again"file which has the problem") and remove the underline one ....that's all
hope it helps

Author

Commented:
Thanks to everyone for your assistance. Peter, your suggestion worked fine. Thanks again.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial