Hi,
 I am writing a custom tag in Struts which will create a radio button and assign it a value. When the user submits the form, i need to set the property corresponding to this radio button in the ActionForm(similar to what <html:radio> tag does). Can anyone tell me how can i achieve this through my custom tag.

Here's what i have come up with so far:

public class SearchResultTag extends TagSupport
{
static Logger logger=Logger.getLogger("PersonInfoLogger");

public String value=null;
public String name=null;



public void setName(String aName)
{
name=aName;
}

public String getName()
{
return name;
}

public String getValue()
{
return value;
}

public void setValue(String aValue)
{
value=aValue;
}



public int doStartTag() throws JspException
{
try
{
JspWriter out=pageContext.getOut();

out.print("<input type=\"radio\" name=\" "+name+" \" value=\" "+value+" \" >");


//out.println("<html:radio property=\" "+property+"\" idName=\" "+idName+"\" value=\" "+value+"\" />");
}
catch(Exception e)
{
logger.error("Exception occured: "+e.toString());
}
return SKIP_BODY;
}

}

Then in the jsp i use it as follows:

<logic:iterate id="result" name="searchResult" scope="request" type="personinfo.SearchResult" >
<tr>
<td>

<PersonInfo:radio name="empId" value="<%= String.valueOf(result.getEmpId()) %>" />

This works fine as far as rendering the radio button is concerned. However, i need to set the corresponding property value in ActionForm.

Can anyone help?