2 Replies Latest reply on Sep 30, 2009 4:43 AM by Ilya Shaikovsky

    Netbeans Visual Editor Problem with Richfaces

    mustafa karakaya Newbie

      Hi,

      I am using JSF 1.2 with Richfaces and my ide is Netbeans. When i put any of the a4j or rich tags inside any page the visual editor crashes. Can someone please help what i am missing?

      An example image is at this link:

      http://img225.yfrog.com/img225/4897/a4jerror.jpg

      By the way my web.xml contains:

      <context-param>
       <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
       <param-value>client</param-value>
       </context-param>
       <context-param>
       <param-name>com.sun.faces.disableVersionTracking</param-name>
       <param-value>true</param-value>
       </context-param>
       <context-param>
       <param-name>org.richfaces.SKIN</param-name>
       <param-value>blueSky</param-value>
       </context-param>
       <context-param>
       <param-name>org.richfaces.CONTROL_SKINNING</param-name>
       <param-value>enable</param-value>
       </context-param>
       <filter>
       <display-name>RichFaces Filter</display-name>
       <filter-name>richfaces</filter-name>
       <filter-class>org.ajax4jsf.Filter</filter-class>
       </filter>
       <filter>
      <filter-mapping>
       <filter-name>richfaces</filter-name>
       <url-pattern>*.jsp</url-pattern>
       <dispatcher>REQUEST</dispatcher>
       <dispatcher>FORWARD</dispatcher>
       <dispatcher>INCLUDE</dispatcher>
       </filter-mapping>


      The error is as follows:

      java.lang.NullPointerException
      at org.ajax4jsf.renderkit.AjaxRendererUtils.buildAjaxFunction(AjaxRendererUtils.java:405)
      at org.ajax4jsf.renderkit.AjaxRendererUtils.buildAjaxFunction(AjaxRendererUtils.java:383)
      at org.ajax4jsf.renderkit.AjaxRendererUtils.buildOnEvent(AjaxRendererUtils.java:171)
      at org.ajax4jsf.renderkit.AjaxRendererUtils.buildOnClick(AjaxRendererUtils.java:147)
      at org.ajax4jsf.renderkit.AjaxCommandRendererBase.getOnClick(AjaxCommandRendererBase.java:83)
      at org.ajax4jsf.renderkit.html.CommandButtonRenderer.doEncodeEnd(CommandButtonRenderer.java:135)
      at org.ajax4jsf.renderkit.html.CommandButtonRenderer.doEncodeEnd(CommandButtonRenderer.java:182)
      at org.ajax4jsf.renderkit.RendererBase.encodeEnd(RendererBase.java:134)
      at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:836)
      at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:279)
      at com.sun.faces.renderkit.html_basic.GridRenderer.encodeChildren(GridRenderer.java:242)
      at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:812)
      at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:271)
      at com.sun.faces.renderkit.html_basic.GridRenderer.encodeChildren(GridRenderer.java:242)
      at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:812)
      at org.primefaces.ui.renderkit.CoreRenderer.renderChild(CoreRenderer.java:66)
      at org.primefaces.ui.renderkit.CoreRenderer.renderChildren(CoreRenderer.java:54)
      at org.primefaces.ui.component.dialog.DialogRenderer.encodeBody(DialogRenderer.java:118)
      at org.primefaces.ui.component.dialog.DialogRenderer.encodeDialogMarkup(DialogRenderer.java:93)
      at org.primefaces.ui.component.dialog.DialogRenderer.encodeEnd(DialogRenderer.java:32)
      at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:836)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderBean(FacesPageUnit.java:1355)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderNode(FacesPageUnit.java:1554)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderBean(FacesPageUnit.java:1342)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderNode(FacesPageUnit.java:1554)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderNode(FacesPageUnit.java:1568)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderBean(FacesPageUnit.java:1342)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderNode(FacesPageUnit.java:1554)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderBean(FacesPageUnit.java:1342)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderNode(FacesPageUnit.java:1554)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderBean(FacesPageUnit.java:1342)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.getFacesRenderTree(FacesPageUnit.java:1112)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderHtml(FacesPageUnit.java:1680)
      at org.netbeans.modules.visualweb.insync.faces.FacesPageUnit.renderHtml(FacesPageUnit.java:1633)
      at org.netbeans.modules.visualweb.insync.models.FacesModel.getHtmlDomFragment(FacesModel.java:1616)
      at org.netbeans.modules.visualweb.insync.models.FacesModel.findHtmlBody(FacesModel.java:1640)
      at org.netbeans.modules.visualweb.insync.models.FacesModel.getHtmlBody(FacesModel.java:1628)
      at org.netbeans.modules.visualweb.designer.jsf.JsfForm.getHtmlBody(JsfForm.java:1755)
      at org.netbeans.modules.visualweb.designer.jsf.JsfForm.getHtmlBody(JsfForm.java:1745)
      at org.netbeans.modules.visualweb.designer.jsf.DomProviderImpl.getHtmlBody(DomProviderImpl.java:119)
      at org.netbeans.modules.visualweb.designer.WebForm.getHtmlBody(WebForm.java:937)
      at org.netbeans.modules.visualweb.designer.DesignerPaneUI.resetPageBox(DesignerPaneUI.java:623)
      at org.netbeans.modules.visualweb.designer.WebForm.setDefaultFontSize(WebForm.java:3275)
      at org.netbeans.modules.visualweb.designer.jsf.ui.JsfTopComponent.initDesignerPreferences(JsfTopComponent.java:310)
      at org.netbeans.modules.visualweb.designer.jsf.ui.JsfTopComponent.<init>(JsfTopComponent.java:268)
      at org.netbeans.modules.visualweb.designer.jsf.ui.JsfMultiViewElement.<init>(JsfMultiViewElement.java:87)
      at org.netbeans.modules.visualweb.designer.jsf.JsfForm.createMultiViewElement(JsfForm.java:494)
      at org.netbeans.modules.visualweb.designer.jsf.DesignerJsfServiceImpl.createDesignerMultiViewElement(DesignerJsfServiceImpl.java:88)
      at org.netbeans.modules.visualweb.project.jsfloader.JsfJavaEditorSupport$DesignerDesc.createElement(JsfJavaEditorSupport.java:562)
      at org.netbeans.core.multiview.MultiViewModel.getElementForDescription(MultiViewModel.java:206)
      at org.netbeans.core.multiview.MultiViewModel.getActiveElement(MultiViewModel.java:127)
      at org.netbeans.core.multiview.MultiViewModel.getActiveElement(MultiViewModel.java:123)
      at org.netbeans.core.multiview.MultiViewPeer.showCurrentElement(MultiViewPeer.java:273)
      at org.netbeans.core.multiview.MultiViewPeer.peerComponentOpened(MultiViewPeer.java:234)
      at org.netbeans.core.multiview.MultiViewCloneableTopComponent.componentOpened(MultiViewCloneableTopComponent.java:139)
      at org.openide.windows.WindowManager.componentOpenNotify(WindowManager.java:298)
      at org.netbeans.core.windows.WindowManagerImpl.notifyTopComponentOpened(WindowManagerImpl.java:1007)
      at org.netbeans.core.windows.Central.addModeOpenedTopComponent(Central.java:764)
      at org.netbeans.core.windows.ModeImpl.addOpenedTopComponent(ModeImpl.java:311)
      at org.netbeans.core.windows.WindowManagerImpl.topComponentOpenAtTabPosition(WindowManagerImpl.java:1115)
      at org.netbeans.core.windows.WindowManagerImpl.topComponentOpen(WindowManagerImpl.java:1082)
      at org.openide.windows.TopComponent.open(TopComponent.java:434)
      at org.openide.windows.TopComponent.open(TopComponent.java:425)
      at org.openide.windows.CloneableOpenSupport.openCloneableTopComponent(CloneableOpenSupport.java:199)
      at org.netbeans.modules.visualweb.project.jsfloader.JsfJavaEditorSupport.doOpenDesigner(JsfJavaEditorSupport.java:176)
      at org.netbeans.modules.visualweb.project.jsfloader.JsfJavaEditorSupport$1.run(JsfJavaEditorSupport.java:158)
      at org.openide.util.Mutex.doEvent(Mutex.java:1335)
      at org.openide.util.Mutex.writeAccess(Mutex.java:452)
      at org.netbeans.modules.visualweb.project.jsfloader.JsfJavaEditorSupport.openDesigner(JsfJavaEditorSupport.java:150)
      at org.netbeans.modules.visualweb.project.jsfloader.JsfJspEditorSupport.openDesigner(JsfJspEditorSupport.java:210)
      at org.netbeans.modules.visualweb.project.jsfloader.JsfJspDataObject$OpenEdit.open(JsfJspDataObject.java:257)
      at org.openide.actions.OpenAction.performAction(OpenAction.java:81)
      at org.openide.util.actions.NodeAction$DelegateAction$1.run(NodeAction.java:589)
      at org.netbeans.modules.openide.util.ActionsBridge.doPerformAction(ActionsBridge.java:77)
      at org.openide.util.actions.NodeAction$DelegateAction.actionPerformed(NodeAction.java:585)
      at org.openide.explorer.view.TreeView$PopupSupport.mouseClicked(TreeView.java:1515)
      at java.awt.AWTEventMulticaster.mouseClicked(AWTEventMulticaster.java:253)
      at java.awt.AWTEventMulticaster.mouseClicked(AWTEventMulticaster.java:252)
      at java.awt.AWTEventMulticaster.mouseClicked(AWTEventMulticaster.java:252)
      at java.awt.AWTEventMulticaster.mouseClicked(AWTEventMulticaster.java:252)
      at java.awt.Component.processMouseEvent(Component.java:6219)
      at javax.swing.JComponent.processMouseEvent(JComponent.java:3265)
      at java.awt.Component.processEvent(Component.java:5981)
      at java.awt.Container.processEvent(Container.java:2041)
      at java.awt.Component.dispatchEventImpl(Component.java:4583)
      at java.awt.Container.dispatchEventImpl(Container.java:2099)
      at java.awt.Component.dispatchEvent(Component.java:4413)
      at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4556)
      at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4229)
      at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4150)
      at java.awt.Container.dispatchEventImpl(Container.java:2085)
      at java.awt.Window.dispatchEventImpl(Window.java:2475)
      at java.awt.Component.dispatchEvent(Component.java:4413)
      at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
      at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:104)
      at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
      at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
      at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
      at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)