I want to know the exact explanation for difference between setview() and renderview()
setview()
overrides the view set by convention (typically views/handler/action.cfm
). This renders at the end of the event.
renderview()
calls the view immediately, similar to a cfinclude
. The rendering can be captured in a variable for later use.
See the ColdBox wiki for Views & Layouts for more information.