This example illustrates how to page pass a newly created record ID value (primary key value) from an Add Record page to another page. In this example, the user is redirected to another page when a “Save” button is clicked on an Add Record page. The newly created record ID is passed as a URL parameter to the redirected page.
Step 1: In Iron Speed Designer, double click the Save button on the Add Record page to display the Save button’s Properties dialog. Go to the Bindings tab on the Page Properties dialog and set the following:
|
Tag Property |
Setting |
|
Code generation tag |
SaveButton |
|
Button Command |
Save data on page |
|
Action After Command |
Go to specific URL |
|
URL |
../Employees/EditEmployeesRecord.aspx |
|
URL parameter |
EmployeeID=[Data Value From: EmployeeRecord] |
Step 2: In the Bindings tab, click Add to add the URL parameter.
|
URL Parameter |
Setting |
|
URL parameter name |
EmployeeID |
|
Data Value From |
EmployeeRecord |
|
Parameter Value |
Primary key |
Press OK on the URL Parameter dialog.
Press OK on the Page Properties dialog.
Step 3: Build and run your application.