SpriteFlags in D3D (C#)

woodsman

Newcomer
Joined
Feb 13, 2004
Messages
3
I'm attempting to run code from the book Managed DirectX 9 and seem to have run into a problem on the chapter where the author discussed using sprites.
sprite.Begin(SpriteFlags.AlphaBlend)

The errors are:
E:\Prog\Visual Studio Projects\C# Projects\DXTest1\Form1.cs(104):
The type or namespace name 'SpriteFlags' could not
be found (are you missing a using directive or an assembly reference?)
E:\Prog\Visual Studio Projects\C# Projects\DXTest1\Form1.cs(204):
No overload for method 'Draw' takes '5' arguments
I can probably figure out the Draw function given the MSDN, but for the life of me I can't seem to see my error.
MSDN says:
Namespace Microsoft.DirectX.Direct3D
Assembly Microsoft.DirectX.Direct3DX (Microsoft.DirectX.Direct3DX.dll)

Which I've included. Has anyone else run into this or know what is wrong? I'm stumped.
 
use a newer VS.NET

Hi,

I ran into this problem. You are using older version of DirectX9 or VS.NET

1. Be sure to use the Managed DirectX9 DLLs build 1126.
2. Be sure to use VS.NET 2003

LDV.
 
I don't think you do. I'm using VS.NET 2002, and although it is a pain sometimes, it does work.

Make absolutely sure you've updated your .NET Framework (to at least 1.1) and Managed DX 9.0b Summer Update.
 
I had this problem. And i solved it by:

1. Installing .NET framework 1.1
2. Installing the latest DirectX9 SDK Managed
3. Visual Studio .NET 2003

As much as i know, you must use the VS.NET 2003 (it is version 7.1.3088 - check it in the help-about menu)

LDV
 
Back
Top