Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Tracking record locks by WinNT user
Message
 
To
11/10/2001 10:45:13
General information
Forum:
Visual FoxPro
Category:
Third party products
Miscellaneous
Thread ID:
00566971
Message ID:
00567028
Views:
35
Hello Christopher

Well this is a long argued thing with many opinions, this is mine (and I have incorperated it into a working program)

I add a charictor field (lockedby) to every table the maximum lenght of users last name plus the maximum lenght of users first name + 2 spaces
so it can look like this
"Smith, John" 2 spaces 1 for the comma and one for the space after the comma

ok then in my code every time I do a rlock() I also do a replace

if rlock() = .t.
rlock()
replace lockedby with alltrim(gc_lastname)+', '+alltrim(firstname)
else
wait 'record locked by '+alltrim(lockedby) window

then right before the unlock I blank the lockedby

replace lockedby with ''
unlock


hope this helps


>Hello all...
>
>I am in a class to learn VFP this week (John Petersen is teaching). We are discussing record locking, and an interesting question came up: how can I find out who has a record locked?
>
>I need to know if there's a third party piece of software that will track which user has a lock on a specific record in a VFP table. Alternatively, I'd like to know if I can easily develop such a thing myself.
>
>We have Windows 98 SE clients with a Windows NT 4.0 server, so a lot of the Windows NT workstation information is not there for these clients.
>
>Any help will be appreciated!
>
>
>- Chris Style.
Stephen McLaughlin
"Sexy Steve Valenteno", "Blastmaster"
stephenmclaughlin@gmail.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform