BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

OnValidate event of TField firing recursively

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi VCL Components Using
View previous topic :: View next topic  
Author Message
Sarfraz Bokhari
Guest





PostPosted: Mon Oct 27, 2003 8:34 pm    Post subject: OnValidate event of TField firing recursively Reply with quote



Hi group,

I am developing DB App with D7. My problem is this.

I have a master-detail Sales Invoice form. When the form opens I want to
fill the Invoice number field with LastInvNumber+1. It is easy and I have
done it.
I have OnValidate event for Invoice# field. It checks if invoice number,
that is typed, if already exists then open it otherwise consider it new
Invoice and start input.

As I assign value to INV_NO field or TDBEdit it fires the OnValidate event
resursively.

It want that if I assing value to TDBEdit Text or Value property then
OnValidate should not fire. I have tried DisableControls/EnableControls but
all in no desied result.
Is there a way that I assign a value to TDBEdit and it only shows it in the
control but does not post it DB.
Please help I have designed more than 100 forms and now implementing code
and having no way out.
I have used DevExpress Editors and then have EditingText property wich do
the desired job but I can not use those components due to "Stay With Native"
rule for the current App.

Have a nice day.

S Bokhari


Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi VCL Components Using All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.