I have a web that works if I come through the front-door and drill down to a page where I Add a record.
I am adding a record to a table called "WebChat" and I get the Master Key in teh Add Page - Before Processing event by using
Session("LINK")=Session("dbo.WebChat_masterkey1")
However, I can also link direct to the WebChat record via a url link I send to the user. It is basically "Your Discussion Item has been accepted and can be found at .............."
The Url takes then straight to the correct View without the preceding drill-down. If they press Back to List then I allow them to add some more Discussion. However, since this jumps into my Web then I have no Master Key to reference and so Session("LINK")=Session("dbo.WebChat_masterkey1") fails.
If my new code goes into Before Process Add event (BeforeProcessAdd(dbConnection)) what syntax can I use to get that Master Key in this situation?
If I put some code in the Before Display Add event (BeforeShowAdd(xt,templatefile)) is there something here I can use to reference the key I want in the field "WebLink"?