This topic is locked
[SOLVED]

 before record deleted

5/19/2011 5:08:17 PM
ASPRunnerPro General questions
T
Tim author

Hello,
When a user deletes a record from a list page I'd like to update the "Remove" field and not delete the record. Here is what I've tried:
Before record deleted -
deleted_values("Remove") = "1"

BeforeDelete=false
I'm pretty sure this used to work in older versions (with values("Remove") instead of deleted_values) but now it does nothing. I'm using 6.3 7474. Am I doing something wrong? Is there another way to accomplish this?
(on a side note, and as an fyi, i tried to search the forum and was sent to a page that looked messed up... no results and missing things.)
Thanks,

Tim

T
Tim author 5/19/2011

SORRY!!!
So I actually found the old application were I do this and what I posted is not how I did it at all! (I would have just deleted this post but I didn't see a way to, so instead I'll update with the correct way to do this.)
Here is what I did
Before record deleted -
dal.Table("MyTable")

dal.Table("MyTable").Param("ID")=deleted_values("ID")

dal.Table("MyTable").Value("Remove")="1"

dal.Table("MyTable").Update()
BeforeDelete=false
Sorry for being lazy... my only excuse is I've been sick for a few days and I'm tired.
Move along, nothing to see here.

Thanks

Tim