3.0 beta 2

Setting a value to selected checkbox

I have a widget in there i have people who all have PeopleID's in my database and i am displaying those people. I am using checkboxes so that i can select any number of people so as to export them using reports.
How do i assign a selected checkbox to a value for instance if i select John, i would like the checkbox to then have John's ID inside it.

Any assistance would be greatly appreciated
Roger Mutangadura
September 12,
Please find below the file i am currently using. Its a PHP/Smarty file. So i would like that when i selected person, the the seleced person's id is added to an array of selected ID's so that i can export them and use them in another file to generate reports only for these selected people.

<link href="ActiveWidgets/runtime/styles/xp/aw.css" rel="stylesheet" type="text/css" ></link>
<script src="ActiveWidgets/runtime/lib/aw.js"></script>
.aw-controls-grid {height: 100%; font: menu;}

.aw-column-0 {width: 40px;}
.aw-column-1 {width: 250px; }
.aw-column-2 {width: 210px; }
.aw-column-3 {width: 250px; }

.aw-grid-cell {border-right: 1px solid #b7c0c7;}
.aw-grid-row {border-bottom: 1px solid #b7c0c7;}

.aw-header-0 .aw-item-box {
background: #e0dde7!important;
.aw-grid-control {
font: menu; color: #000;
<script type="text/javascript">
var Data= new Array();
var myData = new Array();

{* section name=pub loop=$pubs *}
Data[{*%pub.index%*}] = [ "","{* $pubs[pub].Surname *}, {* $pubs[pub].Title *}{* $pubs[pub].Name *}&nbsp;({* $pubs[pub].Job *})","{* $pubs[pub].publication *}","{* $pubs[pub].CompName *}&nbsp;({* $pubs[pub].BName *})"];
{* /section *}
var Columns= ["&nbsp;","Name","Publication","Company"];

var obj = new AW.UI.Grid;

var str = new AW.Formats.String;
var num = new AW.Formats.Number;


obj.setCellTemplate(new AW.Templates.Checkbox, 0);
checkbox = new AW.UI.Checkbox;

var num_rows = obj.getRowCount();
checkbox.onControlValueChanged = function(value){
for (i=0; i<num_rows; i++){

var str = new AW.Formats.String;
var num = new AW.Formats.Number;




<form action="reportsexp.php" method="post">
<input type="submit" name="submit" value="Export list of selected persons">
Roger Mutangadura
September 12,

This topic is archived.

See also:

Back to support forum


Version 2

Looking for AW 2.6 ?
The old site is here.