473,385 Members | 1,325 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.

Windows Media Player in Access

I'm trying to insert a Windows Media Player on to my Main Menu Form that would play an introductory clip to my project Db.

I tried this my going to "More Controls" and insert the Windows Media Player. I see the Player on the form, I then went to the 'On Enter' event and placed a Macro to run a command to the location of the 'music file'. This has FAILED.

Of course it's a guess/ trial an error I'm working this with.....since it flunked, I'm now here for expert advise.

Thanks again!
Aug 14 '09 #1
7 15810
FishVal
2,653 Expert 2GB
Hi, there.
  • Control with embedded ActiveX (media player in your case) has property "Object" which returns, surprise, object of embedded ActiveX.
  • Get type of this object using TypeName() function or VBA IDE "Watch" pane.
  • Explore available methods/properties/events of the type in Object browser.
  • ????????
  • PROFIT!!!

Kind regards,
Fish.
Aug 14 '09 #2
Thanks for the reply!
:-)
Aug 14 '09 #3
ADezii
8,834 Expert 8TB
@student2
Assuming your ActiveX Control is named WindowsMediaPlayer1, to automatically Load and Play C:\Test\OhNo.wav in Media Player when your Form is first Opened:
Expand|Select|Wrap|Line Numbers
  1. Private Sub Form_Open(Cancel As Integer)
  2. Const conMEDIA_FILE_TO_OPEN As String = "C:\Test\OhNo.wav"
  3.  
  4. Me![WindowsMediaPlayer1].openPlayer (conMEDIA_FILE_TO_OPEN)
  5. End Sub
Aug 14 '09 #4
Thank you very much!!
I'm going to try it :-)
Aug 14 '09 #5
I'm able to load the W.M.P. when the form is loaded, however, it cannot find the source, says check my path, but I've placed "C:\MyComputer\FileName\Clip.wav", that's the location.

Any clues?
Thanks again!
Aug 15 '09 #6
ADezii
8,834 Expert 8TB
@student2
As long as the Path is valid, I see no reason why it should not work. Place the File in a Directory under the Root, as in: C:\Test, then see what happens.
Aug 15 '09 #7
Ok will try it thanks!
Aug 15 '09 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Mickel Grönroos | last post by:
Hi! Anybody tried using Windows Media Player 9 via win32com? (And more precisely, combining that with a Tkinter application.) I found a few earlier threads on Windows Media Player and Python,...
56
by: alan b | last post by:
I copied it and tried to edit the movie.htm below in the <PARAM NAME=*** location of the file where the videoclip is on my hard drive. It is already recorded by Windows Media Player. My version...
1
by: Anise | last post by:
I have a question concerning embedding a windows media player into a web application in .net.. I download Windows Media Player 10 and its SDK On the .ascx page I placed a windows media player...
1
by: Stephen Adam | last post by:
Hi there, Have spent a while trying to find out how to connect to Windows Media Player through COM. Unfortunately there doesnt seem to be much stuff about it on the web. What I need to do is...
0
by: icho | last post by:
Hi, I got a windows media player in an aspx page, which accesses files from a network share. I've maintain a connection using WNetAddConnection2 method of the windows API, but somehow the...
4
by: BobAchgill | last post by:
What is the best way to show a video file directly in a Form? Can I use functions of Windows Player in a Windows Form? Functions like: play video or show visualization for music, etc.
3
by: UJ | last post by:
I have a .avi file that uses the Divx codec. If I load it with windows media player program it works fine. If I load it using my control in a program, it doesn't display. Over standard media files...
1
by: sri2097 | last post by:
Basically, I want to check if a URL is playable or not (without actually playing it). i.e. given a URL I want to write an automation script to figure it out for me if it's playable or not. If...
19
by: Tony | last post by:
I'm working on project that plays movies using Windows Media Player and I'm controlling everything with JavaScript. Per the client I only need to support IE 6 or greater which happens to make...
0
by: artsohc | last post by:
Hey Everyone, this is my first time posting so go easy on me. I am trying to hook up music-on-hold at the office I work at. I got all the music loaded and I got Windows Media Player working while...
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
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: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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...

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.