Hello everyone.

The Mixed Reality Forums here are no longer being used or maintained.

There are a few other places we would like to direct you to for support, both from Microsoft and from the community.

The first way we want to connect with you is our mixed reality developer program, which you can sign up for at https://aka.ms/IWantMR.

For technical questions, please use Stack Overflow, and tag your questions using either hololens or windows-mixed-reality.

If you want to join in discussions, please do so in the HoloDevelopers Slack, which you can join by going to https://aka.ms/holodevelopers, or in our Microsoft Tech Communities forums at https://techcommunity.microsoft.com/t5/mixed-reality/ct-p/MicrosoftMixedReality.

And always feel free to hit us up on Twitter @MxdRealityDev.

'UnityGenerated' does not exist in the namespace 'Unity'

I have been scanning the general Net for answers to this:- Error CS0234. I really think it must be something extremely obvious or my set up is not correct. I recently updated and downloaded some stuff. I am using Unity version 5.5.0b-7 (Personal) to get the use of 'WorldAnchorStore' features. I just downloaded the latest HoloToolkit-Unity and reimported it also. The problem comes when Unity creates an App.cs script which it seems to automatically generate or modify when it launches from Unity using the 'Build Settings/Build' key. This is the problematical code which it creates:-

        private void SetupOrientation()

What am I doing incorrectly here?


Best Answer


  • UnityGenerated.cs is a class that Unity will create for you under UWP\ProjectName

  • Looks like this error is back again.
    You can update App.cs to have a:
    using Unity;
    and then remove Unity as qualification level on the SetupDisplay() statement:

    private void SetupOrientation()

  • it happens when you Project end with "Unity" then your root namespace will be a distraction to compiler

    for example your root namespace is "FPMV.Unity" (my case now) , compiler cannot find "UnityGenerated" in "FPMV.Unity"

Sign In or Register to comment.