Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Invalid Entry message after Valid Event
Message
De
30/07/1997 05:37:53
Glenn Mcburney
Doe(Ni) Information Systems Unit
Belfast, Royaume Uni
 
 
À
29/07/1997 21:55:19
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00041746
Message ID:
00042270
Vues:
31
>>>>my problem is when the valid event fires in my forms after my own error box appears a system error 'Invalid entry, press space to continue' displays in the main foxpro window and locks the screen until spacebar is pressed.
>>>>
>>>>This happened previously and was not solved until Windows 95 was re-installed.
>>>>
>>>>It happens in all forms for all foxpro systems on my PC that worked perfectly before and still work OK on all other PC's.
>>>>
>>>>The valid event uses keypress/keycode so field level validation only fires when enter is pressed, the problem does not arise when the valid event is called at form level using a global variable to mimic the field commit.
>>>>
>>>>The only other problem I have had recently which may/may not be related is losing the path to the VFP default resource file for storing screen positions etc.
>>>>
>>>>My own error messages come from the errormessage event then the 'unwanted' error appears.
>>>Glenn,
>>>
>>>I suspect that this is on a date field and that you have not SET DATE to yoru format in the Form's Load event. SET DATE is scoped to the data session and it defaults to American, so with date set American {01/31/1997} is Jan 31, but if the user enters {31/01/1997} that is an invlaid date. The Invlaid entry is impossible to surpress for date data types when an invalid date has been entered.
>>
>>
>>Jim,
>>
>>Thanks for your reply.
>>
>>My problem is happening on all fields types.
>>
>>Set Date is British. My date fields do not have any ControlSource - the Valid event checks CTOD(This.Value) against STRTRAN(This.Value,'/','') to pick up invalids.
>>
>>Notify is off (confirmed with SET('notify') in the valid event)
>>The problem does not happen when Valid() is called at form level, returns .f. and the ErrorMessage event called.
>>
>>Any other suggestions would be much appreciated.
>>
>>Glenn
>>DOE ISU (Belfast)
>
>Hi,
>
>I encountered this problem before. To get rid of the 'Invalid entry, press space to continue'', use return 0 in your valid event instead of return .f.
>
>Hope this helps!
>
>Destine

Destine,

Using the 0 does stop the Invalid Entry message but I am using the ErrorMessage event which needs to be triggered by a .f. return.
When you had the problem did it start happening suddenly ? Have you any idea what caused it ?

My forms all worked OK before and still work when run from another machine, I am beginning to suspect it relates to the Windows95/VFP relationship. Even if VFP is deleted from hard disk and re-installed the problem still occurs but if Windows is re-installed everything is fine again (but then something upsets it again after a time).

Does any of this sound familiar to your situation ?

Thanks
Glenn.
Glenn
DOE(NI), Belfast
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform