Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Force Shared Open in DBC Event?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00741206
Message ID:
00741358
Vues:
21
Nice idea. One thing I was just thinking about was the multiuser aspect of this code. If I open tables through OLEDB, I wonder what will happen if I have n simultaneous opens? DBSetProp is "very global" and I want to make sure what I do is only affecting the current single environment.

Thanks.


>Hi,
>
>Turn off DBCEVENTS to prevent recursion:
>
>
>PROCEDURE dbc_AfterOpenTable(cTableName)
>        =DBSETPROP(<database>,'dastabase',DBCEVENTS,.F.)
>	Select (cTableName)
>	Use
>	Select 0
>	USE (cTableName) In 0 Shared
>       =DBSETPROP(<database>,'dastabase',DBCEVENTS,.T.)
>ENDPROC
>
>
>HTH,
>Viv
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform