This topic is locked

Button error:

3/21/2016 2:47:57 PM
ASPRunner.NET General questions
Pete K author

I want to replicate the functionality of the view record icon on a list page, but using a more noticeable button at the end of the row (user requirement -- not my idea.) I inserted a button and added server code as per the help file and instruction in the button dialog:


XVar data = button.GetCurrentRecord();

result["txt"] = data["ID"];


I then tried to redirect from the Client After event using


location.href = "/Offering/view?editid1=" + result["txt"];


Because it wasn't doing anything, I actually wrapped the server code into a try/catch block and it did throw an exception. The error message was:
"'runnerDotNet.Button' does not contain a definition for 'GetCurrentRecord'"
What did I do wrong? The button is on a list page which is using a column grid layout with 2 fields per column and the button is inserted just after the last field in the first row in case that matters. I did verify in the HTML view that the button is within the grid row. I wasn't sure if that mattered.

Sergey Kornilov admin 3/28/2016

Just wanted to say this kind of issue is hard to resolve without seeing the actual code. Feel free to post you project to Demo Account and open a ticket with Demo Account URL so we can troubleshoot this.