API_PlaySound

N

NNlogistics

I maintain a Database for about 10 fellow employees. I have the Front end
(SplitDatadase_Fe) in each of their systems in My Documents\Database. All is
well. Lately I have been playing with API_PlaySound. The Wav file location
needs to be specified and here where I have the problem. I want to
distribute the database and wav files uniformily to each user. I would like
to add a subfolder and call it "Assess_Sounds" folder in "Database. The
problem I have is I cant give it an absolute value because some of the
systems have a C: and some have a D:. I tried

API_PlaySound "..\AccessSounds\glass_breaking_2.wav"


I thought it would go up one directory and down to "AccessSounds" but Nooo.

Anybody have any ideas.

Thanks as always for any assistance
 
B

Brendan Reynolds

I'm not sure I followed your description of where the .wav file is located.
The following example assumes that the .wav file is located in a
'AccessSounds' folder that is a sub folder of the folder that contains the
application MDB ...

API_PlaySound CurrentProject.Path & "\AccessSounds\glass_breaking_2.wav"
 
N

NNlogistics

Brendan

Thankyou. You were correct, the sub directory is looked in the current
directory.

Current Project.path - Live and learn. I can use this in a few other
applications. Sometimes it pays to play around (this time with sounds) - You
always learn.

Thanks again -
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top