////////////////////////////////////////////////////////////////
// Event delegate for 'click' event
proc page1_section1_click(arg)
// Position on the correct Employeeid using SEEK()
if seek(val(arg),employees)
// Refresh the Employees Section
Lianja.getelementbyid("Page1.section2").refresh()
// Generate and print a report on the employee's orders
// using a hidden WebView Section and the Library report.rsp
myreport = createObject("webview")
myreport.url = "lib:/report.rsp?database=southwind&table=orders";
+"&fields=*&filter=employeeid=employees.employeeid ";
+"&heading=Orders for Employee {employees.employeeid}"
myreport.refresh()
myreport.print()
endif
endproc
Bookmarks