Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Set Deleted On does not work properly with RVs on Grids.
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00658791
Message ID:
00662175
Vues:
18
Jess -
I think your user interface is fine, and in fact we do the same thing in our app: if a child record is deleted, the delete is not committed immediately; rather, the user has to hit Save at the parent level for the change to take effect.

We haven't encountered this issue, but I wonder if your SKIP isn't useful because you're on the last record? Try LOCATE instead and see if that works -- if it does, maybe you can use logic like:
DELETE
IF on last record in grid
    GO TOP
    GO BOTTOM
ELSE
    SKIP
ENDIF
REFRESH()
This still wouldn't be foolproof, as I believe it still won't behave right if you've deleted the last record. But it might be a start.
zahid

>Ok. There is a little change of behaviour. The problem only occurs when deleting the LAST ROW in the Grid. Deleting other records works properly.
>
>>>Using Remote Views, Set Deleted On doesn't to seem work properly on Grids. Here is the scenario:
>>>
>>>I have a grid that uses RV as recordsource. The RV is buffered. Using command buttons, I do Inserts and deletes. No problem with Inserts. However, deleting a record, Skip, and then Refresh... the record is still displayed in the grid. Only upon issuing TableUpdate gives the expected behaviour. Am I missing something here?
>>
>>Two possible problems occur to me:
>>
>>
  • SET DELETED ON is scoped to the current datasession. Try issuing SET DELETED ON in the current form.
    >>
  • DELETE, just like doing any other change, should be followed by TableUpdate(). Otherwise, the change (deleting the record, in this case) isn't comitted to disk.
    >>
    >>HTH, Hilmar.
  • Précédent
    Suivant
    Répondre
    Fil
    Voir

    Click here to load this message in the networking platform