Darren DICK
d.dick at uws.edu.au
Tue Mar 1 19:18:56 CST 2005
Hi Rocky I have a folder in the App home folder for sounds. Also one for Images and Skins etc EG C:\Program Files\My app will be the 'home' folder And in it will be C:\Program Files\My app\Sounds (About 5 or 6 files in here) C:\Program Files\My app\Images (3 more folders and about 20 files in here) C:\Program Files\My app\Skins (1 folder (but it can grow) and many files in here) I install them when I install the app. They are my 'standard' folders and files and go with every app. And I refer to them now by heart with lines like (I actually use globals for the length of the session But can be done at a form Sub level just as easy) EG Dim strSkinToUse as String Dim strSkinFolder as String Dim strImagesFolder as String strSkinToUse = Dlookup("[SkinName]","tblOptions") strSkinFolder = Left(CurrentDb.Name, Len(CurrentDb.Name) - Len(Dir(CurrentDb.Name)) - 1) & "\Skins\" & strSkinToUse strImagesFolder= Left(CurrentDb.Name, Len(CurrentDb.Name) - Len(Dir(CurrentDb.Name)) - 1) & "\Images" strSoundsFolder= Left(CurrentDb.Name, Len(CurrentDb.Name) - Len(Dir(CurrentDb.Name)) - 1) & "\Sounds" Then I refer to each skin component like.....('Cause I know 'em off by heart) Me.picture = strSkinFolder & "\Background.jpg" Me.imgMyLogo = strImagesFolder & "\OurLogo.jpg" I use the API code "PlaySound" for Playing Sounds Eg Private Sub Form_Load() PlaySound (strSoundsFolder & "\Logon.wav") End sub It works and is pretty simple. HTH See ya Darren