As I have sometimes problems with intellisense in visual studio using unity, I searched for some answers. It was almost everytime pretty much the same: Reloading the project. But in my solution explorer, there is not even a project shown that i could reload. Are you able to manually create the project or are there some reasons for that behaviour?

ps: I just updated unity from version 2017.3.0f3 to 2018.1.0f2, may that be the problem? (I'm using visual studio 2017 (i'm updating in the moment on version 15.7.1) community)

edit: What I've tried so far:

  1. Simply re-launching Visual Studio by double-clicking on the script file inside unity (-> DMGregory)
  2. reloading the project
  3. reimport all in the asset-explorer inside unity (S. Tarik Cetin)
  4. deleting the .sln file to force Unity to regenerate them from scratch (-> Ed Marty) + opening the solution from inside Visual Studio

    Doing the last point created - as intended - a new solution, but there is still no project created, as you can see in the following picture (Projektmappe = solution). That's how the solution looks like.That's how the solution looks like. While opening the script from Unity, it shows the message in the following picture. Translation:Message when opening "The following files were stated in the command line: [source path (name censored)] These files were not found and are not loaded."

When trying opening a script from a different (new) Project, it showed the same message, which leads to a new problem: Even in new unity projects, the solution cannot be opened, and the scripts are all assigned to a certain solution ("solution1"), which is the one that was generated. (Even scripts from different projects end up in the same solution!)

So in the moment, I have no idea what else to do. Is there something simple I'm just missing? Or should I reinstall one of the 2 programs? Or might the update of unity be the problem? (exact versions mentioned above)

If there's any extra information needed, please just mention it in the comments. (I'm not so sure what might be helpful and what isn't)

  • \$\begingroup\$ Usually I close Visual Studio and re-launch it by double-clicking on one of my script files inside Unity. \$\endgroup\$ – DMGregory May 13 '18 at 13:55
  • \$\begingroup\$ @DMGregory I already tried it a couple of times, didn't work. \$\endgroup\$ – SomeWindowsUser May 13 '18 at 13:56
  • \$\begingroup\$ Try Reimport All option in the context menu of asset explorer. \$\endgroup\$ – S. Tarık Çetin May 13 '18 at 15:02
  • \$\begingroup\$ Listing the full version numbers for both Unity & visual Studio might help. \$\endgroup\$ – Pikalek May 18 '18 at 16:03

It seems there is a problem with asmdef files in Unity 2018 with Visual Studio 2017, you'll need an update.




You can try the following:

  • Update your Visual Studio 2017 to the latest version. (v15.7.1)

This will most likely solve your problem. If not:

  • Delete asmdef files from packages folder of Unity. But this may cause your project to not compile if you have a dependency on those packages. The folder should be in C:\Users\ {UserName}\AppData\Local\Unity\cache\packages\packages.unity.com
| improve this answer | |

It happened to me too. I solved it by updating visual studio.Try installing the latest version.

| improve this answer | |

I wasn't able to find anything that specifically targeted the problem you described. It's possible that this might be an issue that occurs only from updating one of the products from one version to another. As a general troubleshooting solution, try the following:

  1. Back up your work!
  2. Uninstall Unity.
  3. Uninstall Visual Studio
  4. Reinstall Visual Studio using the most recent stable version available.
  5. Reinstall Unity using the most recent stable version available.
| improve this answer | |
  • \$\begingroup\$ Thanks for the answer, but updating visual studio was sufficient. =) \$\endgroup\$ – SomeWindowsUser May 19 '18 at 8:57

Have you tried simply deleting the .sln and .csproj files from the root directory of your project? That’s will force Unity to regenerate them from scratch if they got mangled somehow Unity doesn’t recognize as a problem.

| improve this answer | |
  • \$\begingroup\$ That didn't work, too. There was just a new solution created. \$\endgroup\$ – SomeWindowsUser May 13 '18 at 14:58
  • \$\begingroup\$ That’s what’s supposed to happen. Have you tried just opening the solution from Visual Studio directly? If the same problem occurs try a blank Unity project, and/or a blank Visual Studio project. Depending on the results you may want to try uninstalling/reinstalling one or the other. \$\endgroup\$ – Ed Marty May 13 '18 at 15:04
  • \$\begingroup\$ I made another blank unity project, and its scripts are now opened under the same solution that was generated. Is this intended? \$\endgroup\$ – SomeWindowsUser May 13 '18 at 15:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.