Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. How to play Windows Media Player in VC++.NET

How to play Windows Media Player in VC++.NET

Scheduled Pinned Locked Moved C / C++ / MFC
csharpc++comhelptutorial
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    shiv nand
    wrote on last edited by
    #1

    Hi all, i want to play Media player in application im using VC++ 2005,i have added Windows Media Player via COM, and added buttons play stop and pause. In VC++ 6 there is options like m_player.SetUrl ("c:\\abc.wmv"); m_player.GetControls().play(); But in VC++ 2005 I am not Getting those options? plz help me. I wanted to play the WMP in Windows CE? So please Help me. I have no Idea how to play a Vedio files? Thanks in advance.

    C 1 Reply Last reply
    0
    • S shiv nand

      Hi all, i want to play Media player in application im using VC++ 2005,i have added Windows Media Player via COM, and added buttons play stop and pause. In VC++ 6 there is options like m_player.SetUrl ("c:\\abc.wmv"); m_player.GetControls().play(); But in VC++ 2005 I am not Getting those options? plz help me. I wanted to play the WMP in Windows CE? So please Help me. I have no Idea how to play a Vedio files? Thanks in advance.

      C Offline
      C Offline
      Cool_Dev
      wrote on last edited by
      #2

      if you are using .NET framework, please post it in Managed C++/CLI forums

      D 1 Reply Last reply
      0
      • C Cool_Dev

        if you are using .NET framework, please post it in Managed C++/CLI forums

        D Offline
        D Offline
        Destiny777
        wrote on last edited by
        #3

        I too am looking to do the same thing in an existing large Visual Studio 2005 MFC C++ Application. - Have added the Windows Media Player Control but can't seem to find the way at runtime to add a URL to point to a local file or point to an http:// Address. So some details would be helpful for the person that originally asked the question and those that are looking for similar answers. In a Visual Studio 2005 C# project it is very simple to do... just add the Windows Media Player Control to the form. Call the Control "MediaPlayer". Then in your code set the URL to a file or a http:// value as needed.

        // Set the media to be played by our Windows Media Player Control on our C# Form
        MediaPlayer.URL = "C:\Windows\Media\FileToBePlayed.avi";

        It is quite a bit different in Visual Studio 2005 MFC C++... the Windows Media Player Control objects that are exposed in C# are not exposed in C++... perhaps there is something that got missed along the way. My search goes on... :suss:

        -- Modified Tuesday, April 5, 2011 3:48 PM

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups