How to blur the windows media player in windows form on a button click?

Assaliam-o-Alaikum
i want to disable the functionality of media player by default.But when button clicked it would enabled.
Any idea how to implement it.
thanks

Assaliam-o-Alaikum
i want to disable the functionality of media player by default.But when button clicked it would enabled.
Any idea how to implement it.
thanks
Hi,
It seems that you want to disable that media player, the way shared by Pisteuon works for creating a blur for both window and controls.
If you want to disable that media player, you could consider using the following way, in this case we need the class below.
ImageCapture.
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace YourNamespace
public class ImageCapture
[StructLayout(LayoutKind.Sequential)]
public struct RECT
public int left;
public int top;
public int right;
public int bottom;
[DllImport("User32.dll", CharSet = CharSet.Auto, SetLastError = true)]
public static extern IntPtr SendMessage(IntPtr hWnd, uint msg, IntPtr wParam, IntPtr lParam);
[DllImport("User32.dll")]
public static extern IntPtr GetDesktopWindow();
[DllImport("User32.dll")]
public static extern IntPtr GetWindowDC(IntPtr hWnd);
[DllImport("User32.dll")]
public static extern IntPtr ReleaseDC(IntPtr hWnd, IntPtr hDC);
[DllImport("User32.dll")]
public static extern IntPtr GetWindowRect(IntPtr hWnd, ref RECT rect);
public const int SRCCOPY = 0x00CC0020;
[DllImport("gdi32.dll")]
public static extern bool BitBlt(IntPtr hObject, int xDest, int yDest, int width, int height, IntPtr hObjectSource, int xSrc, int ySrc, int dwRop);
[DllImport("gdi32.dll")]
public static extern IntPtr CreateCompatibleBitmap(IntPtr hDC, int width, int height);
[DllImport("gdi32.dll")]
public static extern IntPtr CreateCompatibleDC(IntPtr hDC);
[DllImport("gdi32.dll")]
public static extern bool DeleteDC(IntPtr hDC);
[DllImport("gdi32.dll")]
public static extern bool DeleteObject(IntPtr hObject);
[DllImport("gdi32.dll")]
public static extern IntPtr SelectObject(IntPtr hDC, IntPtr hObject);
public static Image CaptureControlImage(Control c)
IntPtr hSrc = c.Handle;
IntPtr hdcSrc = GetWindowDC(hSrc);
RECT rWindow = new RECT();
GetWindowRect(hSrc, ref rWindow);
int width = rWindow.right - rWindow.left;
int height = rWindow.bottom - rWindow.top;
IntPtr hdcDest = CreateCompatibleDC(hdcSrc);
IntPtr hBitmap = CreateCompatibleBitmap(hdcSrc, width, height);
IntPtr hOld = SelectObject(hdcDest, hBitmap);
BitBlt(hdcDest, 0, 0, width, height, hdcSrc, 0, 0, SRCCOPY);
SelectObject(hdcDest, hOld);
DeleteDC(hdcDest);
ReleaseDC(hSrc, hdcSrc);
Image img = Image.FromHbitmap(hBitmap);
return img;
Add a panel to bring to front, and draw what that media player looks as its background image.
Panel myPanel; //add that panel to disable that media player
private void button2_Click(object sender, EventArgs e)
if (this.myPanel == null)
myPanel = new Panel();
myPanel.Size = this.axWindowsMediaPlayer1.Size;
myPanel.Location = this.axWindowsMediaPlayer1.Location;
DWM_BLURBEHIND bb = new DWM_BLURBEHIND(true);
DwmEnableBlurBehindWindow((IntPtr)this.axWindowsMediaPlayer1.Handle, ref bb);
myPanel.BackgroundImage = ImageCapture.CaptureControlImage(this.axWindowsMediaPlayer1 );
this.Controls.Add(myPanel);
myPanel.BringToFront();
//remove that panel to enable that media player
private void button3_Click(object sender, EventArgs e)
{ if (this.myPanel != null)
this.Controls.Remove(myPanel);
myPanel = null;
Result:
 Regards,
Carl
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey.

Similar Messages

  • How do I change which media player adobe reader X uses when I click a link that directs me to a vid

    There is a link in a pdf file I use, and when I click on it i receive this message:
    "This media requires an additional player. Please click 'Get Media Player' to download the correct media player. To play the media, you will need to close and restart the application once the player installation is complete."
    However, I am in possession of several media players that I know are able to play the file that the link is referring to.
    I do not want to download additional media players. I just want to figure out how to play the video when I click on the link.
    Thanks for your time.

    Andy, is your profile signature "iMac (27-inch Mid 2010), Mac OS X (10.7.5)" still correct or has your system changed since you set it up?
    the Aperture database that is under Media - Photo is the wrong one
    This may be a problem of a wrong entry in the Aperture preferences file. The Media Browser will use the most recently opened Aperture library . Try first to switch to a new empty Aperture library and then back (you can switch using the File menu in Aperture (File > Switch to Library > Other/New). Then restart your Mac to ensure, that all applications terminate properly.
    If you are running Aperture 3.5.1 in Mt. Lion or later, you may need to enable the option "Share XML with other applications" in the Aperture preferences "Preview" tab. This is only necessary for non-Apple apps (Aperture 3.5: Set "Share XML with other applications" to "Never" for better performance and faster quit times).
    If that does not correct the Aperture library in the Media Browser, quit Aperture and remove the "com.apple.Aperture.plist" file from the Preferences folder as described in Aperture 3: Troubleshooting basics.
    -- Léonie

  • How To Fix The Nokia Media Player Not Opens Proble...

    My mum buyed the Nokia Asha,And After The Critical Restart Phone Not Opens Nokia Media Player and calculator.Whats Problem Solution?

    hi mate, have you checked that you are up to date with the latest firmware for the device ? also try re-installing the latest firmware via Nokia Suite on PC, and if that doesn't work either, then Restoring the phone to factory settings.

  • How to open A Windows Form from Crystal Reports

    Hello All
    We are using crystal Repors 10 with Visual studio .Net 2005. Our requirement is to open the Windows Form when a user click on the respective Hyperlink. Simillarly popping up the MessageBox when clicking hyperlink.
    How this is possible, I will be really thankful to anyone who solves my problem

    Depending if this is a web or win app, you have different solutions.
    Web or win, use hyperlinks and redirect to an aspx page (I think hyperlinks are supported in CR 10.2).
    Win, use events as described in the sample app csharp_win_viewer_events.zip / vbnet_win_viewer_events.zip. I have never used the events to pop up a new form, but you should be able to do this.
    BTW.; make sure you have sp 1:
    https://smpdl.sap-ag.de/~sapidp/012002523100006007872008E/crvs05sp1.exe
    Ludek
    Follow us on Twitter http://twitter.com/SAPCRNetSup

  • How to use the windows phone default media player from my app

    hello every one,
    I build a windows phone 8 app , and i used this code, to play a video in the phone media player (didn't want to use MediaElement)
    using Microsoft.Phone.Tasks;MediaPlayerLauncher mediaPlayerLauncher = new MediaPlayerLauncher();
    i just see that in windows phone 8.1 i can't use this namespace and a lot of others, (I didn't understand why...)
    and i want to lunch a video in the phone media player instead using a MediaElment
    how can i do it?
    thanks,
    Or

    Hi Or,
    Using
    Launcher class is fine (not sure if you are playing with 8.1 Silverlight or runtime), you can launcher default system app by following code:
    var success = await Windows.System.Launcher.LaunchFileAsync(file);
    --James
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Why does my iTunes window freeze and wont close until i shut my computer down, when the "iTunes is not the default media player" message appears? and how do i fix this? i just want to fix my music, but it freezes and i can't use my computer correctly.

    when i plug my iPod into my computer, iTunes opens as normal, but for a while it's been giving me a message that says "iTunes is not the default media player" and after i 'tried' to do that, i'll close the settings window and my iTunes window will freeze and not close, reload, or anything. and if i "open drvice to view files" that window will freeze too, the internal storage window. i can't get iTunes to close with ALT+F4, or right clicking the tab on the bottom of the screen to close it, or clicking the 'X' button. the only way it closes is when i shut down my computer. please help me fix this. Its getting Really Really tiring having to restart my computer over and over.

    What Windows version?

  • Help...How to Play Video and Auido using windows media player in developer forms?

    I am using the Windows NT workstation and Oracle Forms6i, I want to know how to use window media player in oracle forms? I have insert an OLE object and add Windows media player as an control object, but I don't know how to play the audio and video.
    I always have this error...why?? How can I solve this??
    FRM-41344: OLE object not defined for VIDEO in the current record.
    Cause:     An empty OLE container is defined.
    Action:     Define an OLE object to reside in the OLE container.
    Level:     20
    Type:     Error
    This is my final year project, anyone can help me?
    Thanks a lot!!!

    UKNightOwl wrote:
    ... providing the computer has Windows Media Player installed, ...
    ... This saves you having to bother with portable/travel speakers,
    Mains lead for the computer is a bit of a problem on the bus though!

  • How to remove "Ads by Media Player" using Chrome? Online solutions are for Windows

    How to remove "Ads by Media Player" using Chrome? Online solutions are for Windows.
    Having relentless pop up ads which open new browser windows. Searched all over for a Mac solution and can't seem to find one. Help please!?

    http://www.adwaremedic.com/index.php
    (Read the whole page to learn about adware!)

  • How to blur the background behind the AIR application?

    Dear fellow developers and Adobe gurus,
    With the BlurFilter, I can easily blur everything inside of
    an AIR application.
    But, figure this for a moment: I'll have an application with
    some sort of transparent background, which results in all the items
    and programs behind the AIR application shining through. Further
    imagine that I have some kind of blurred background in my
    application from which I want the UI components to stick out nicely
    and sharply.
    But here's the suprise: no matter how I blur the contents of
    my AIR application, everything behind the app stays sharp and
    crystal clear.
    Now my idea of the whole picture is that the Flash Player
    somehow "hands through the application" what is behind it when
    system chrome is off and transparency mode is on, but it only seems
    to "pipe" it through without applying any effects/filters to it.
    So, my question is: is there a good reason for this (maybe it
    would be a serious performance and/or platform alignment issue), is
    there a workaround (like "plugging into" the piped stream of
    background information), or will there some first-hand solution in
    the future?
    Best regards
    C.

    Thanks a lot for this quick, plausible, and clarifying
    answer.
    I feared it was something like that... it leaves me a wee
    disappointed.
    I was hoping to be able to create some sleek blur effects in
    the background of my application with AIR...
    With the fullscreen capabilities of the Flash Player in mind,
    I was also hoping it was possible to create some kind of fullscreen
    blur-fade effect, with all the other items fading/blurring to black
    when turning my app into fullscreen mode. Something like the effect
    of the Steam Media Player, if you happen to know that. But since
    that is built upon the Windows Media Player, I already feared that
    it would be something specific to WMP in combination with the OS.
    I also understand that it would be very difficult to achieve
    a similar effect with something like screenshots since it is almost
    impossible to do that real time.
    Is there any faint chance that AIR/the Flash Player might be
    able to do something like filtering/affecting what is shown behind
    the app in the future?
    Best regards
    C.

  • Satellite Pro M70-273: Functionality of the Express Media Player feature

    I bought a Toshiba Satellite Pro M70-273 "Limited Edition" (?) two weeks ago. The model number is PSM76E-00J00QDU, model name SPM76, production date 2006-02-21. According to the specifications I found in the online user's manual or in a folder with publication references
    "TEG October 2005, Art. N0. DSSSPM70 10/05NLBE", there is an "Express Media Feature" "on some selected models" ...
    It is not clear if yes or no, the model I bought has it. I have a "CD/DVD Button" that I use to launch my built-in dvd player (e.g. WinDVD), but this does not work as specified as "a standalone disc drive" that plays a dvd (film) without needing to startup Windows.
    To watch the dvd film, after using the CD/DVD button, I have to boot into Windows, login into Windows XP and when the desktop is started, the WinDVD screen will show the film.
    This is not what I'm expecting from a standalone dvd player. My old notebook has a "dj function" with which one can play a cd without booting into Windows, (or powering up the notebook), just by pressing a special key on the front . How about the promised feature of the Toshiba Satellite Pro?
    Is there an "Express Media Player" functionality at all? How can I check if the feature is provided? I used the setup provided, the first time I used my notebook. I don't wish to use the recovery cd rom provided unless it might be absolutely indispensable to install this missing feature.

    John
    With the laptop you should have received a restore/recovery disc. This contains utilities to either replace individual drivers and tools, plus a complete 'image' of the base build that your laptop has when it is built at the factory
    Although I have never used this, it is supposed to completely wipe all data and setings from ythe laptop by first formatting the hard drive then reinstalling the operating system and applications back to factory settings. From comments elsewhere on this forum one of the few options you can have when you do this is to choose to partition the hard drive into 2 sections, one for the Express Media player, the other for the operating system etc. (as the Express Media operates without booting into the operating system).
    The process is designed to be user friendly as it guides you through it, but as I said it does wipe EVERYTHING you have on the laptop currently, which is why I never bothered after I realised it wasn't installed. By the sounds of it though it won't be too much hassle for you to do that as you have data/settings you can easily transfer afterwards (Win XP has a tool to help with this)
    The Gigastore hub I have found very good, and likewise the Gigastore hard drive, although others have posted here about their laptops not 'seeing' the hard drive in certain conditions
    If you want anything further I check here fairly regularly, or you can mail me - [email protected]
    Steve

  • How can I use Microsoft Media Player with my new iPod Nano?

    I do not like the iTunes player.  I want to use the Microsoft Media Player with my iPod Nano.  I dislike the iTunes player so much that if I don't get this resolved I will have to return the iPod Nano.

    Michelle,
    You can download media components for QuickTime which will enable you to play WMA files through QuickTime on your Mac:
    http://windows.microsoft.com/en-gb/windows/windows-media-components-quicktime
    Alternatively, Get the free VLC player for Mac, which will play almost all media types:
    http://vlc-media-player.en.softonic.com/mac
    If the interview requires Windows Media Player to be running to conduct the interview, then I fear you may be stuck, there is not a version of Windows Media Player for Mac - It is for Windows.  Your options in this case would be to borrow a Windows PC or install a valid copy of Windows on your MacBook under BootCamp.

  • Ubuntu 10 (Linux) & Firefox 3.6 ~ How to uninstall the Adobe Flash Player plug-in & ActiveX control

    Ubuntu 10.045 (Linux) and Firefox 3.6.3  ~  How to uninstall the Adobe  Flash Player plug-in & ActiveX control
    In general Adobe needs to offer Ubuntu (Linux) support.  I don't use Windows anymore and will go with whatever company provides me the Plug In's I need to function.  In this case at the current time, I can't use Adobe flash Player to view You Tube video's.  I followed the link that helps a user fix the problem:
    Solve a Problem: The video won't play:
    http://www.google.com/support/youtube/bin/answer.py?answer=56115
    I then saw that you suggested that I first needed to uninstall any older versions of the Flash Player and then install the latest version of the Flash player.  I clicked on the link find out how to uninstall it here:
    How to uninstall the Adobe Flash Player plug-in and ActiveX control
    http://kb2.adobe.com/cps/141/tn_14157.html
    They didn't offer any help with Ubuntu 10.045 (Linux).  Please offer the instructions and automatic (non-terminal) uninstaller.  Also, I want an automatic installer for Ubuntu 10 (Linux) & Firefox 3.6 that is easy like like you have for Windows and like Sun's Java has for Linux.
    Message was edited by: u2rcrazy  ~   Edited Title

    You should go to this site to see what versions of Flash Player and Shockwave Player you have installed.
    http://www.adobe.com/shockwave/welcome/
    The versions you are listing (10.0 r12, 10.0 r2) appear to be Shockwave Plauer versions, not Flash Player.
    If you want to uninstall Flash Player, there should be an uninstaller in the install directory.  I do not know where that is on Linux.

  • On certain websites, when opening a wmv file it will open as an ascii file, instead of the microsoft media player.

    this website used to work at one time. What could cause this. This may have happened after upgrading to Firefox 4.0, but I am not sure. I am using Windows XP. I have checked that I have the latest media player plugin installed.

    Clear the cache and the cookies from sites that cause problems.
    "Clear the Cache":
    * Tools > Options > Advanced > Network > Offline Storage (Cache): "Clear Now"
    "Remove the Cookies" from sites causing problems:
    * Tools > Options > Privacy > Cookies: "Show Cookies"
    If the file is opened in Firefox as a text (ASCII) file then that means that the HTTP response header specify a content type text/plain instead of a content type that identifies the file as a media file. That can be a problem with that website, but another possibility is that security software like a firewall has changed the response headers as a security precaution because that content isn't trusted.
    A possible cause is security software (firewall) that blocks or restricts Firefox or the plugin-container process without informing you, possibly after detecting changes (update) to the Firefox program.<br />
    Remove all rules for Firefox from the permissions list in the firewall and let your firewall ask again for permission to get full unrestricted access to internet for Firefox and the plugin-container process.
    See:
    * https://support.mozilla.com/kb/Server+not+found
    * https://support.mozilla.com/kb/Firewalls

  • How to blur the background in potraits ?

    I am using lightroom 5 in Windows 8.Please tell me how to blur the backgrounds in portraits .

    i would used the adjustment tool with clarity slider set to -100. It may take several or more brushes and so other adjustments
    but as far as I know there are no blurring tools as in PS
    will be interesting to hear other ways/ideas
    Have fun

  • What is the best media player for Ipad 2

    what is the best media player for Ipad 2?
    Is it VLc? if so, where can I find the VLC media player

    Im going to go ahead and assume your talking to me?
        I ended up in this thread in search of a functional Exchange ready mail client capable of supporting multiple mail profiles. Since there are no free applications to accomplish this in the app stor, which I can find, I figured I'd leverage the 'community' for some direction before throwing good money after bad.
       As I assume Im not the only one to do this, I figured I'd help straighten these folks out on the lingo (as they werne't applying it properly) and the sassy 'sound like apple users' comment references the way ANTI-apple folks assume you people are less than adequite users.
       If I called an apple an orange, you would say I was wrong. If I did it repeatedly, after correction, you would assume Im incompetant.
       Seriously, its a stupid machine and will only do what you tell it. (true for all computers, apple or otherwise)
       So if I ask for a mail client, dont give me a provider. If I ask for a service, dont name a client. 
        Your right, this post is old. And stilll doesnt have an answer. . .
        In response to MichelPM, I didnt call your baby ugly. The 'Bandwagoning' is cute though. My advice is sound, and helping you folks not to look so... well... stupid.
        Since you interceded though, how about a little help? What mail client do you use? Is it exchange Compatible, with active sync? Does it offer multi-profile support? And the clients want images in their signatures, and multi signature support. (I can do this with my android phone ) 
    Im looking forward to your responses.

Maybe you are looking for