views:

66

answers:

2

In a .NET Compact Framework application we are using ocx media player component written by coppercoins.

The media player launches on a new screen when ever user clicks a button. The media player works well on the first time. When we close the media player form and launch it once again on click of the button, it breaks with the following exception

ExceptionCode: 0xc0000005
ExceptionAddress: <address location>

Can someone tell me how to resolve this issue?

Note: we are disposing the media player form as well as the media player activeX wrapper control when the form is closed. The media player is disposed inside the designer code( using as shown below

    protected override void Dispose(bool disposing)
    {
        if (disposing && (components != null))
        {
            components.Dispose();
        }
        if (disposing)
        {

            _axPlayer.Dispose();
            _axPlayer = null;
        }
        base.Dispose(disposing);
    }
A: 

That probably isn't going to be something you'll be able to fix your side and is an issue for forward to the component designer.

As a work around I would suggest retaining the object reference for the duration of the application and not disposing it. Obviously this blows if it occupies a lot of memory.

Quibblesome

related questions