Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
? IsFlocked() behavior
Message
 
 
À
21/06/2001 12:49:43
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00521938
Message ID:
00522028
Vues:
11
Richard,

Strange, but I replicated this behavior too:
local lnHandle
lnHandle = fopen('jobs.dbf',0) && returns 6 (file opens)
? 'First time: '+transform(m.lnHandle)
if lnHandle>0
  ? fclose(m.lnHandle) && return .T. (file closed)
endif  
select 0
use jobs shared in 0
wait window "Let's see..."
lnHandle= fopen('jobs.dbf',0) && returns -1 (unable to open file)
? 'Second time: '+transform(m.lnHandle)
if lnHandle>0
  ? fclose(m.lnHandle) && return .T. (file closed)
endif  
?ferror()
use in select('jobs')
use jobs excl
? fopen('jobs',12) && returns -1 (unable to open file)
use in select('jobs')
>I must be missing something:
>
>All from the command window VFP6 - clean load of VFP.
>
>? fopen('inv_mast.dbf',12) && returns 6 (file opens)
>? fclose(6) && return .T. (file closed)
>select 0
>use inv_mast shared
>? fopen('inv_mast.dbf',12) && returns -1 (unable to open file)
>use in inv_mast
>use inv_mast excl
>? fopen('inv_mast.dbf',12) && returns -1 (unable to open file)
>use in inv_mast
>
>What gives? - I do have Hackers Guide - great reference - I have tried all the other fopen parameters - all return the same for me.
>
>Thank you very much for your help.
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform