The sort records script step allows you a number of sort options--including the ability to sort on more than one field. It uses the same dialog for setting up a sort as the sort records menu option.
Beyond that, please explain in more detail where you are encountering problems getting the results that you want.
I know how to use a script to sort records based in one field.
Because there are 5 combinations available to sort records, I'd like to create just one script that could get assigned fields, such as by checkbox and sort records at a layout.
I dont'want to create 25 possible scripts for these 5 available combinations.
Am I going in a wrong direction to solve this issue?
Why not create a global field to which you attach a value list with your five sort options, and access the field via a checkbox set. You script can then reference this field and sort by what ever fields the user has checked.