Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Getting a deletion to be seen right away
Message
From
26/10/2006 13:59:39
Mike Yearwood
Toronto, Ontario, Canada
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 8
OS:
Windows 2000
Network:
Windows NT
Miscellaneous
Thread ID:
01164770
Message ID:
01164788
Views:
9
>using a free 26 dbf.
>set resource is at 1,1
>set deleted is ON
>
>The problem: a deletion is not being seen by the program until 1.5 seconds go by.
>
>The code deletes a record and then does a seek with a key that matches the deleted record and another record that was just inserted in the same table. The seek finds the first record, which is the deleted record.
>
>We tried flush , locate and go (reccount()) but none worked at ensuring that the deleted record gets seen as being deleted. The only thing that worked was:
> do while !deleted()
> wait window 'record not deleted yet' timeout .1
> enddo
>
>
>Open to suggestions and ideas on how to get the deletion seen right away.

Does this help?
LOCAL m.lcAlias
m.lcAlias = ALIAS()
IF ISRLOCKED(RECNO(m.lcAlias), m.lcAlias) 
 ELSE
  IF RLOCK(m.lcAlias)
    UNLOCK RECORD (RECNO(m.lcAlias)) IN (m.lcAlias)
  ENDIF
ENDIF
Previous
Reply
Map
View

Click here to load this message in the networking platform