[jboss-user] [Beginners Corner] - Simple action not called

hispeedsurfer do-not-reply at jboss.com
Mon Jan 15 04:44:30 EST 2007


Hi,

perhaps a cap in my mind. 
I try to call an action, but the method is never called

here the jsf code fragement
<div class="entry">
  | 				<a4j:log hotkey="M" />
  | 				<a4j:commandButton value="Reload" action="#{measureEdit.onListLoad}" reRender="Sensor"/>
  | 				<div class="label">Sensor:</div>
  | 				<div class="input">
  | 					<a4j:region renderRegionOnly="false">
  | 						<h:selectOneMenu id="Sensor" value="#{messkette.sensor}"
  | 							converter="#{selectItemHelfer}" required="true" disabled="#{gesperrt}">
  | 							<f:selectItems value="#{measureEdit.alleSensorenMitBlank}" />
  | 							<a4j:support event="onchange" reRender="Funktion, Sensormessbereich, Einheit, Sensorwarnung" />
  | 						</h:selectOneMenu>
  | 					</a4j:region>
  | 					<h:message for="Sensor" styleClass="message" />
  | 					<div><h:outputText id="Sensorwarnung" value="#{measureEdit.sensorWarnung}" styleClass="kursiv" /></div>
  | 				</div>		
  | 			</div>	

When I press the button the onListLoad() method from class MeasureEdit should be called, but nothing is done.
<a4j:commandButton value="Reload" action="#{measureEdit.onListLoad}" reRender="Sensor"/>

The pojos
MeasureEditBean.java
@Stateful
  | @Scope(ScopeType.CONVERSATION)
  | @Name("measureEdit")
  | public class MeasureEditBean extends AbstractUnderEditorBean<	MeasuringChain, Testbed> implements MeasureEdit{
  | ....
  | public String onListLoad() {
  | 		// TODO Auto-generated method stub
  | 		System.out.println("invoked");
  | 		selectItemHelfer.onListLoad();
  | 		return null;
  | 	}
  | }

MeasureEdit.java
@Local
  | public interface MeasureEdit extends AbstractEditor<MeasuringChain> {
  | 	
  | 	...
  | 	
  | 	public String onListLoad();
  | }

What's wrong in my mind? 



Thanks
andi

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4001704#4001704

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4001704



More information about the jboss-user mailing list