Yeah. Dump the ?? and use the Windows API. (I think I found the API stuff on the news2news site a long time ago. Wouldn't want anyone here think I was smart enough to figure that out on my own.) The rest of it is just some defensive coding.
FUNCTION playSound(m.soundFile AS Character, m.soundMode AS Int) TRY IF VARTYPE(m.soundMode)=[L] m.soundMode=0 && SND_SYNC ENDIF IF VARTYPE(m.soundFile)=[L] m.soundFile=[ding.wav] ENDIF DECLARE INTEGER sndPlaySound IN WinMM.dll STRING lpszSoundName, INTEGER uFlags sndPlaySound(FULLPATH(m.soundFile), m.soundMode) CATCH TO m.loError FINALLY ENDTRY ENDFUNC
--
rk
-----Original Message----- From: ProfoxTech [mailto:profoxtech-bounces@leafe.com] On Behalf Of Wes Wilson Sent: Wednesday, August 16, 2017 8:55 AM To: profoxtech@leafe.com Subject: Set bell to anyfile.wav
set bell to anyfile.wav?? chr(7) does not work in vfp9 any suggestions? Thanks,Wes Text CONVERTVFPNOW to 44222 to stay informed about the end of Visual FoxPro or email back to us and ask us to put you on our newsletter list. Wes Wilson, President ERW Custom Programming, Inc. Crescent Lake Plaza 5459 Elizabeth Lake Rd. Waterford, MI 48327 (248) 683-4182 LinkedIn Profile "Companies pay too much attention to the cost of doing something. They should worry more about the cost of not doing it" Philip Kotler www.erw.com wes@erw.com
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html ---
_______________________________________________ Post Messages to: ProFox@leafe.com Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/1049735392.2833123.1502888123032@mail... ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious. Report [OT] Abuse: http://leafe.com/reportAbuse/1049735392.2833123.1502888123032@mail.yahoo.com