473,396 Members | 1,768 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

DirectX animation warning when running inside visual studio

I was wondering if someone could tell me why I get this message and how
to prevent it. If I hit continue, it runs fine, but want to know what I
am doing wrong so I won't get this error in the future. also what is
the file Clock.vshost.exe; my application is Clock.exe.

Z.K.
'Clock.vshost.exe' (Managed): Loaded 'C:\Documents and
Settings\Super_Wizard\My Documents\Visual Studio
2005\Projects\Clock\bin\Release\Clock.exe', Symbols loaded.
Managed Debugging Assistant 'LoaderLock' has detected a problem in
'C:\Documents and Settings\sssssss\My Documents\Visual Studio
2005\Projects\Clock\bin\Release\Clock.vshost.exe'.
Additional Information: DLL
'C:\WINDOWS\assembly\GAC\Microsoft.DirectX\1.0.290 2.0__31bf3856ad364e35\Microsoft.DirectX.dll'
is attempting managed execution inside OS Loader lock. Do not attempt to
run managed code inside a DllMain or image initialization function since
doing so can cause the application to hang.


Here is the code:

private void EnableBtn_Click(object sender, EventArgs e)
{
//create the video object
Microsoft.DirectX.AudioVideoPlayback.Video video;

//load alarm avi file
video = new
microsoft.DirectX.AudioVideoPlayback.Video("C:\\Do cuments and
Settings\\Super_Wizard\\My Documents\\Visual Studio
2005\\Projects\\Clock\\bin\\Debug\\bell_t.avi");

//set the System.Windows.Forms.Control to play it in (e.g a
panel)
video.Owner = alarmAnimatePanel;

//Play the video (put this in a buttons click event)
video.Play();

}
Aug 24 '08 #1
2 2277
On Sun, 24 Aug 2008 16:51:07 -0700, Z.K. <no****@nospam.netwrote:
I was wondering if someone could tell me why I get this message and how
to prevent it. If I hit continue, it runs fine, but want to know what I
am doing wrong so I won't get this error in the future. also what is
the file Clock.vshost.exe; my application is Clock.exe.
When you run in the debugger, VS actually hosts your real program in a
sort of wrapper .exe.

As far as the exception goes, if you Google for the exception and DirectX,
you'll see that others have had the same issue (including myself). As far
as I can tell, it's a benign error. Probably a bug in the DirectX/managed
wrapper but I haven't had it cause any trouble and saw at least one person
who heard from the actual DirectX team that it's not a problem.

Note that the exception is actually a "Managed Debugging Assistant" thing,
so you'll only ever see it when you run the program in the debugger. I
just wound up turning the LoaderLock MDA off under the Debug settings for
Visual Studio. I figure that if I ever violate the LoaderLock MDA rules
in a situation when it matters, I'll know soon enough because my program
will deadlock. :)

Pete
Aug 25 '08 #2
Peter Duniho wrote:
On Sun, 24 Aug 2008 16:51:07 -0700, Z.K. <no****@nospam.netwrote:
>I was wondering if someone could tell me why I get this message and
how to prevent it. If I hit continue, it runs fine, but want to know
what I am doing wrong so I won't get this error in the future. also
what is the file Clock.vshost.exe; my application is Clock.exe.

When you run in the debugger, VS actually hosts your real program in a
sort of wrapper .exe.

As far as the exception goes, if you Google for the exception and
DirectX, you'll see that others have had the same issue (including
myself). As far as I can tell, it's a benign error. Probably a bug in
the DirectX/managed wrapper but I haven't had it cause any trouble and
saw at least one person who heard from the actual DirectX team that it's
not a problem.

Note that the exception is actually a "Managed Debugging Assistant"
thing, so you'll only ever see it when you run the program in the
debugger. I just wound up turning the LoaderLock MDA off under the
Debug settings for Visual Studio. I figure that if I ever violate the
LoaderLock MDA rules in a situation when it matters, I'll know soon
enough because my program will deadlock. :)

Pete

That's good to know.

Thanks,

Z.K.
Aug 25 '08 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Leon | last post by:
How to listen to user's interaction with visual studio.Net IDE? For example, how do I know when user has clicked on the compile button. I would like to interact with visual studio IDE (the editor...
2
by: Andreas Klemt | last post by:
Hello, for what is the label good when programming in visual studio like this: Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Label1: ...
4
by: Richard Bell | last post by:
I'm new to visual studio. Is there an easy way to 'snap shot' a copy of a project from inside visual studio? Thanks
3
by: Rob Nicholson | last post by:
How do you determine if a program is running in the Visual Studio IDE/debugger as opposed to standalone? We often include support files in the same folder as the executable and would so something...
1
by: uncah91 | last post by:
I am runnning some very simple performance tests using a vb.net winform to invoke a vb.net webservice. The webservice simply returns a string literal. I invoke the service 1000 times in a row...
9
by: Michael.Suarez | last post by:
Suppose I have a program that prompts you with a dialogbox to enter a password. If you get the password correct, it allows you into the program, else it kills the program. Suppose that when I...
1
by: mjobbe | last post by:
Hi, I'm creating an MSI for a client app using a Visual Studio Setup Project. I'm trying to detect if Internet Explorer is running on the target computer before I start the installation. How do I...
4
by: linda.chen | last post by:
Greeting. We have a 6 year old application, which contains both managed (C#) and unmanaged code (C++). For all the new components we try to create them in C#. We build all projects (both C++...
2
by: Microsoft Newsserver | last post by:
Hi, we have a progress bar which is revealsed before the postback occurs. basically, we add an onclick attribute to the submit button which reveals the progress.gif. This has the effect of...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.