473,385 Members | 1,379 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,385 software developers and data experts.

How to dispose MediaPlayer object?


Hello,

How do I explictly destruct a MediaPlayer object?

The compiler complained about overriding Finalize.
MediaPlayer does not implement IDisposable.

Any suggestions?

Thanks,
William Johnston

Mar 14 '08 #1
3 2935
On Mar 14, 2:13 pm, "William Johnston" <willi...@tenbase2.comwrote:
The compiler complained about overriding Finalize.
MediaPlayer does not implement IDisposable.
What was it's complaint, exactly?
Mar 14 '08 #2
If it is not implimenting IDisposable, then just let it go, as in objMP =
null.

"William Johnston" wrote:
>
Hello,

How do I explictly destruct a MediaPlayer object?

The compiler complained about overriding Finalize.
MediaPlayer does not implement IDisposable.

Any suggestions?

Thanks,
William Johnston

Mar 15 '08 #3
"William Johnston" <wi******@tenbase2.comwrote in message
news:12*************@news.newsville.com...
>
Hello,

How do I explictly destruct a MediaPlayer object?

The compiler complained about overriding Finalize.
MediaPlayer does not implement IDisposable.

Any suggestions?

Thanks,
William Johnston

MediaPlayer is a COM object, so you have to call Marshal.ReleaseComObject
when you want to "release" it's instance.

Willy.

Mar 15 '08 #4

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

Similar topics

0
by: DotNetMania | last post by:
hi.. i have some questions about media player article on codeproject website...... http://www.codeproject.com/cs/media/directshowmediaplayer.asp?df=100&forumid=4399&select=820191#xx793428xx ...
0
by: Christian Steck | last post by:
Hello all, sorry about my english, i donīt speak english very well, but i try it ;-) at the time i write my own ui for the mediaplayer 10 and i have a problem with changing the visualization...
0
by: Nonee | last post by:
Hello- I have a form with the mediaplayer referenced to play mp3's and avi's and I believe that is what is causing the problem. I am not sure, but I am hoping. Anyway, I "published" the vb.net...
1
by: Stephen | last post by:
Here is my issue. I have a <asp:listbox control that is populated with movie titles and url for the media file from a database. No problem. No what I want is the OnSelectedIndexChanged event...
2
by: Sagaert Johan | last post by:
Hi I have 2 audio cards and want my first mediaplayer object to play through soundcard 1 and the other object on card 2. I can't find any properties to set, so i fear this will not be...
7
by: xhunter | last post by:
ok here is my problem, I am trying to change the source file of the mediplayer using javascript, my script works perfectly in "Internet Explorer", but no matter what I do, it doesn't work in...
1
by: William Johnston | last post by:
Hi, I modified a thumbnail creation app and get black images since the first second is black as well. My questions are: 1. How do I set the MediaPlayer.Clock property to start screen capture...
2
by: William Johnston | last post by:
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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...

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.