I have a problem viewing my Form in Form Designer; however, this only happens with the current project i'm working on. When I try to view my form i get the following error:
One or more errors encountered while loading the designer. The errors are listed below. Some errors can be fixed by rebuilding your project, while others may require code changes. | |
at Microsoft.DirectX.Direct3D.Effect.FromFile(Device device, String sourceDataFile, Macro[] preprocessorDefines, Include includeFile, ShaderFlags flags, EffectPool pool, String& compilationErrors) at Microsoft.DirectX.Direct3D.Effect.FromFile(Device device, String sourceDataFile, Include includeFile, ShaderFlags flags, EffectPool pool) at D3DSurfaceControl.D3DViewportControl.InitVertexElement() in C:\Documents and Settings\Paul\My Documents\Visual Studio 2005\Projects\D3DSurfaceControl\D3DSurfaceControl\D3DViewportControl.cs:line 295 at D3DSurfaceControl.D3DViewportControl..ctor() in C:\Documents and Settings\Paul\My Documents\Visual Studio 2005\Projects\D3DSurfaceControl\D3DSurfaceControl\D3DViewportControl.cs:line 57 |
Immediately the "Microsoft Visual C# has encountered a problem and needs to close." window popus up and the program shuts down.
The strange thing is, is that when I comment out line 57 (which calls a function at line 295), rebuild and then try to reopen the designer the problem persists. Also, even though VC# tells me it needs to close, I can just ignore that message and continue developing my project. Furthermore, my program runs without any trouble in both debug and release. I have to admit I added a line in Form.Designer.Cs (which I probably shouldn't do), but I haven't had any problem after that. The problem started to pop up after having implemented a HLSL shader (DirectX 9.0c). At first I didn't really bother to solve this problem because I was only coding, not designing, but now I want to add more controls to the form and it would be a pain to do that manually.
Maybe it's of importance to note that my form currently only displays a single customized control i made which displays a rotating volume texture using DirectX. I searched the web for a solution but couldn't find one, maybe one of you guys (or gals) could help me out.
Thanks in advance,
Paul
Oh, i'm using VC# Express 2005 btw.