Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How do I sound the bell on error?
Message
De
18/08/1998 17:47:17
 
 
À
18/08/1998 16:51:14
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00127863
Message ID:
00127926
Vues:
34
>>>I am developing a custom textbox sub-class. I am monitoring each keystroke in the keypress event. Some keystrokes are obvious errors and I want to sound the "bell" when those keys are pressed rather than accept them. I specify NODEFAULT on those keystrokes and so I therefore do not accept them, but I want the user to be aware so that is why I want to sound the "bell". The users only look up when they hear a "bell". I cannot find a way to make the bell sound.
>>>
>>>Can anyone help me?
>>
>>??CHR(7)
>
>Fred,
>
>I use that successfully in Foxpro 2.0 even when it is running in a DOS window under Windows 95, but in Visual Foxpro running under Windows 95, CHR(7) only produces an almost inaudible tick sound. I want the old fashioned beep sound that I grew to know and love in DOS. I know that I can SET BELL TO a .wav file, but .wav files are not played through the tiny on board speaker. You have to buy a sound card to play a .wav file.
>
>Any other ideas?


I don't know if this still works or not, but can you:

SET BELL TO frequency,duration like you could in FP2.0?

I don't have any machines that don't have a sound card anymore so I can't test it.

FPW and FPD still work that what way on W95. Not sure about VFP.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform