Results 1 to 6 of 6

Thread: missing a using directive

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jan 2006
    Location
    Bangalore
    Posts
    172

    missing a using directive

    hi

    I am having

    The type or namespace name 'Framework' could not be found (are you missing a using directive or an assembly reference?)

    Problem is in parameter Framework
    public static void DisplaySwitchingToRefWarning(Framework framework, string sampleTitle)
    {
    if (framework.IsShowingMsgBoxOnError)
    {

    try
    {

    }
    catch { }
    }
    }
    }


    Please Reply
    Thank you

  2. #2
    Fanatic Member Slaine's Avatar
    Join Date
    Jul 2002
    Posts
    641

    Re: missing a using directive

    Have you got the following using directives:
    Code:
    using Microsoft.DirectX;
    using Microsoft.DirectX.Direct3D;
    using Microsoft.Samples.DirectX.UtilityToolkit;
    Framework is a member of Microsoft.Samples.DirectX.UtilityToolkit
    Martin J Wallace (Slaine)

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Jan 2006
    Location
    Bangalore
    Posts
    172

    Re: missing a using directive

    hi

    Thanks for reply

    My code comes between following namespace

    namespace Microsoft.Samples.DirectX.UtilityToolkit
    {
    }

    still it shows the same error.

    Is there any thing i should add from reference window

    Thank you


    Quote Originally Posted by Slaine
    Have you got the following using directives:
    Code:
    using Microsoft.DirectX;
    using Microsoft.DirectX.Direct3D;
    using Microsoft.Samples.DirectX.UtilityToolkit;
    Framework is a member of Microsoft.Samples.DirectX.UtilityToolkit

  4. #4
    Fanatic Member Slaine's Avatar
    Join Date
    Jul 2002
    Posts
    641

    Re: missing a using directive

    Yes, you will need to add references to the three namespaces.

    You could always start out with the sample barebones application here:

    http://msdn.microsoft.com/archive/de...ptyproject.asp

    Or if you want a more detailed overview on DirectX check this out:

    http://msdn.microsoft.com/archive/de...rkoverview.asp
    Martin J Wallace (Slaine)

  5. #5
    New Member
    Join Date
    Feb 2006
    Posts
    4

    Re: missing a using directive

    Slaine, I'm having the same problem. This error message is coming from dxmutmisc.cs itself which is already in the namespace of Microsoft.Samples.DirectX.UtilityToolkit and already references the namespaces Microsoft.DirectX and Microsoft.DirectX.Direct3D.

    I think MS made breaking changes to recent SDK builds (I have Feb 06) and overlooked updating dxmutmisc.cs.

  6. #6
    New Member
    Join Date
    Feb 2006
    Posts
    4

    Re: missing a using directive

    OK, I've learned that I need to include *all* of the sample Utility Toolkit framework files, or Samples\Managed\Common\dxmut*.cs. However, it only worked if I used the .NET v1.1 DX assemblies. Using the single .NET v2 assembly, I still get compiler errors.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width