This topic is locked

Display page with new data before add

2/18/2009 6:51:38 AM
ASPRunnerPro General questions
T
tinto author

Hi Guys! Hi Girls!
Sorry, but I don't find an answer on the forum at this question:
is possible display a page with new data before add this in the database?
Thaks so much
Tinto

J
Jane 2/19/2009

Tinto,
you can show it on the add page adding custom Add page: Before process and Add page: Before record added events on the Events tab.

Declare new session variable in the Add page: Before process event, check it in the Add page: Before record added and return True of False.
Here is a sample if Add page: Before process event:

if Session("addrecord_status") = "" then

Session("addrecord_status") = "0"

end if



Here is a sample if Add page: Before record added event:

if Session("addrecord_status") = "0" then

Response.Write dict("Field1")

Response.Write dict("Field2")

Session("addrecord_status") = "1"

BeforeAdd = False

else

Session("addrecord_status") = "0"

BeforeAdd = True

end if

T
tinto author 3/2/2009

THANKS JANE! All your code work very well!!!

GREAT!