Make 'Current Selection' from TList results

Hi, I'm not sure if this is where it belongs, but I am trying to make the results of a tlist query the current selection so I can work with those students. I'm looking and still will but if anyone know... I would appreciate it. Thank you, Mark

I added a link to the body of the document:
<a class="button" id="currentSelection">Make Selection</a>

Then added the following script to create the selection.

var all = "ids=";
var ids = [~[tlist_sql;select id from students where rownum <= 10;]~(1),[/tlist_sql]0];
all += ids.join('&ids=') + '&selectionAction=replace&temp=false';
$ "/admin/SaveSelectedStudentsToSelection.action", all.replace(/ids=&/gi, ''), function() { closeLoading(); });

Just change your tlist_sql to select the student' s id needed for your query.
I also notice that this post is 2 years old. But, if any one else stumbles on it, maybe this help help point them in the direction needed.

Subscribe to Comments for "Make &#039;Current Selection&#039; from TList results"