PDA

Click to See Complete Forum and Search --> : missing a using directive


CodeMaker
Feb 10th, 2006, 02:33 AM
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

Slaine
Feb 10th, 2006, 03:42 AM
Have you got the following using directives:
using Microsoft.DirectX;
using Microsoft.DirectX.Direct3D;
using Microsoft.Samples.DirectX.UtilityToolkit;


Framework is a member of Microsoft.Samples.DirectX.UtilityToolkit

CodeMaker
Feb 10th, 2006, 06:11 AM
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


Have you got the following using directives:
using Microsoft.DirectX;
using Microsoft.DirectX.Direct3D;
using Microsoft.Samples.DirectX.UtilityToolkit;


Framework is a member of Microsoft.Samples.DirectX.UtilityToolkit

Slaine
Feb 10th, 2006, 07:32 AM
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/default.asp?url=/archive/en-us/directx9_m_Oct_2004/directx/direct3d/samples/emptyproject.asp

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

http://msdn.microsoft.com/archive/default.asp?url=/archive/en-us/directx9_m_Oct_2004/directx/sampleframework/frameworkoverview.asp

Stimpy_77
Feb 26th, 2006, 04:37 AM
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.

Stimpy_77
Feb 26th, 2006, 05:22 AM
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.