Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Tabela buferizada
Message
De
07/02/2002 11:56:45
Alexandre Sola
Witwise Adm de Bems S/C Ltda
São Paulo, Brésil
 
 
À
07/02/2002 10:54:08
Alexandre Sola
Witwise Adm de Bems S/C Ltda
São Paulo, Brésil
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00616320
Message ID:
00616706
Vues:
36
Ok Claudio
Fiz ok voce me pediu e deu certo (OBRIGADO) pois bem gostaria de saber aonde eu posso consistir se o codigo ja existe.. para dar a mensagem para o usuário..

tenho o seguinte codigo no metodo do lostfocus() do campo da chave primaria cgc

nRec=Recno()
set exact on

SEEK ThisForm.Pag1.Pg2.Text1.Value

If Found()
ThisForm.Pag1.Pg2.Text2.Value = Saifd ->znom
ThisForm.Pag1.Pg2.Text3.Value = Saifd ->zie
ThisForm.Pag1.Pg2.Text4.Value = Saifd ->zest
ThisForm.Pag1.Pg2.Text5.Value = Saifd ->zmun
ThisForm.Pag1.Pg2.Text6.Value = Saifd ->zemp
wait window timeout 3 "Chave ja Existente "
GO nRec
DELETE
TABLEREVERT(.T.)

ThisForm.cmdbotao.cmdproximo.Enabled = .t.
ThisForm.cmdbotao.cmdfinal.Enabled = .t.
ThisForm.cmdbotao.cmdinicio.Enabled = .t.
ThisForm.cmdbotao.cmdanterior.Enabled = .t.
ThisForm.cmdbotao.cmdnovo.Enabled = .t.
ThisForm.cmdbotao.cmdvolta.Enabled = .t.
ThisForm.cmdbotao.cmdaltera.Enabled = .t.
ThisForm.cmdbotao.cmdapaga.Enabled = .t.
ThisForm.cmdbotao.cmdvisualiza.Enabled= .t.
ThisForm.cmdbotao.cmdapaga.Enabled = .t.
ThisForm.cmdbotao.cmdimprime.Enabled = .t.
ThisForm.Pag1.Pg2.cmdGrava.Enabled = .f.
ThisForm.Pag1.Pg2.cmdCancela.Enabled = .f.

else
ThisForm.cmdbotao.cmdproximo.Enabled = .f.
ThisForm.cmdbotao.cmdfinal.Enabled = .f.
ThisForm.cmdbotao.cmdinicio.Enabled = .f.
ThisForm.cmdbotao.cmdanterior.Enabled = .f.
ThisForm.cmdbotao.cmdnovo.Enabled = .f.
ThisForm.cmdbotao.cmdvolta.Enabled = .f.
ThisForm.cmdbotao.cmdaltera.Enabled = .f.
ThisForm.cmdbotao.cmdapaga.Enabled = .f.
ThisForm.cmdbotao.cmdvisualiza.Enabled= .f.
ThisForm.cmdbotao.cmdapaga.Enabled = .f.
ThisForm.cmdbotao.cmdimprime.Enabled = .f.
ThisForm.Pag1.Pg2.cmdGrava.Enabled = .t.
ThisForm.Pag1.Pg2.cmdCancela.Enabled = .t.
endif
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform