Getting the First Record from a Form - how to index it? (Radio button picklist)

Getting the First Record from a Form - how to index it? (Radio button picklist)

This was a bit trickier than I expected...and I looked everywhere on the Forums and Deluge Script for it...and eventually came up with this - it may be wrong, and I'd love to hear a correction...(so if I've missed something blindingly simple, I won't be surprised)

Basically, I am populating a Radio Button picklist with a series of strings which are each a field within a form record...so firstly I loop through each record, and use ui.add to add the string from each one to the picklist.

But then I want to set the first item in the picklist as being 'selected' - which meant that I had to supply the first string in the list as an argument to the 'select()' statement. 

So to do this, I had to 'isolate' the first record from the set of all form records, and the way I did this was to use 'range from 1 to 1'. I had assumed it would be easier...there are alternatives...looping and counting them off...but again, nothing nice and tidy :-)

Here is a code snippet to illustrate...

for each appRecord in Applications_Registry
{
    Application_To_Supply_Names_To:ui.add(appRecord.Application_Name);
}

// Select the last Radio Box item - easiest - FIX this to select the first...if you can...a TO DO.

selectionRec = Applications_Registry[ID != 0] range from 1 to 1;

alert "selectionString : " + selectionRec.Application_Name;

Application_To_Supply_Names_To.select(selectionRec.Application_Name);