Information générale
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Hi again,
This is the code I am using right now for my locking problem, and it's working.
**************************************************************
CLOSE DATABASES ALL
SELECT 0
USE data\leden INDEX data\lidnr SHARED
GO TOP
SET MULTILOCKS ON
SET REPROCESS TO AUTOMATIC
IF SEEK(ALLTRIM(ThisForm.txtlidnr.Value))
RLOCK(ALLTRIM(STR(RECNO())), 'leden')
IF ISRLOCKED()
m_wijziglid = .T.
WITH ThisForm
.cmbbranches.Enabled = .T.
.txtbedrnm.Enabled = .T.
.txtcontactpersoon.Enabled = .T.
.txtadres.Enabled = .T.
.txtpostcode.Enabled = .T.
.txtplaats.Enabled = .T.
.txtbankgiro.Enabled = .T.
.cmdopslaan.Enabled = .T.
.cmdnieuw.Enabled= .F.
.cmdzoeken.Enabled = .F.
.cmdzoekfactuur.Enabled = .F.
.cmdverwijderen.Enabled = .F.
ENDWITH
ThisForm.txtlidnr.SetFocus
ENDIF
ENDIF
***************************************************
In the Quit button of the form I put:
CLOSE DATABASES ALL
SELECT 0
USE data\leden INDEX data\lidnr SHARED
UNLOCK IN leden
*************************************************
I want to thank you for your help today, I was working for a deadline. And because of your help I was finnished right in time.
Greetings and thanks,
Ron
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement