Build custom action HTML view with selected records only

Build custom action HTML view with selected records only

I am able to build my Custom Action HTML View with all records, but I only want to build the View with the few records I've selected.

I have a line of code in my view to fetch the records that looks like this:

<% test123 = info[ID != 0] sort by Release_Date;

Obviously my code is acting on ALL of the record sets, but I only want it to act on the ones I've checked in my view.  I cannot figure out how to filter based on being checked in a view.

Please help.