• djCombobox + Event Handler

    By Claude Sammut 1 decade ago

    When an eventHandler is added, in my case to partially refresh a control onChange the following error is logged in the "Problems" tab

     

     

    <span style="color:#ff0000;"><em>Description Resource Path Location Type</em></span></div>
    
    <span style="color:#ff0000;"><em>The unknown tag xe:eventHandler cannot be used as a control. ccEventDetails.xsp eventbookings_master.ntf/CustomControls line 21 com.ibm.designer.domino.ide.resources.designerproblem</em></span></div>
    
    &nbsp;
    

    This is my code

     

     

    <span style="color:#0000ff;"><em>&lt;xe:djComboBox id=&quot;eventList&quot;&nbsp;</em></span></div>
    
    <span style="color:#0000ff;"><em>autoComplete=&quot;true&quot; ignoreCase=&quot;true&quot;&gt;</em></span></div>
    
    <span style="color:#0000ff;"><em>&lt;xp:selectItems&gt;</em></span></div>
    
    &nbsp;
    
    <span style="color:#0000ff;"><em>&lt;xp:this.value&gt;&lt;![CDATA[#{javascript:var val = EventList.getColumnValues(0);</em></span></div>
    
    <span style="color:#0000ff;"><em>var val2 = [&quot;&quot;];</em></span></div>
    
    &nbsp;
    
    <span style="color:#0000ff;"><em>return val2.concat(val);}]]&gt;&lt;/xp:this.value&gt;</em></span></div>
    
    <span style="color:#0000ff;"><em>&lt;/xp:selectItems&gt;</em></span></div>
    
    &nbsp;
    
    <u><span style="color:#0000ff;"><em>&lt;xe:eventHandler event=&quot;onChange&quot; submit=&quot;true&quot;</em></span></u></div>
    
    <u><span style="color:#0000ff;"><em>refreshMode=&quot;partial&quot; refreshId=&quot;infoPannel&quot;&gt;</em></span></u></div>
    
    <u><span style="color:#0000ff;"><em>&lt;/xe:eventHandler&gt;</em></span></u></div>
    
    &nbsp;
    
    <span style="color:#0000ff;"><em>&lt;/xe:djComboBox&gt;</em></span></div>
    

     

    • Known Issue

      By Darin Egan 1 decade ago

      Claude,

      This is a known issue regarding adding events to controls from the extension library when in Design view. The problem is that the eventHandler tag is being wrongly associated with the xe namespace rather than xp. The solution is to correct this in source view as follows:

       

      <span style="font-family:courier new,courier,monospace;">&lt;<strong>xp</strong>:eventHandler event=&quot;onChange&quot; submit=&quot;true&quot;</span></div>
      
      refreshMode=&quot;partial&quot; refreshId=&quot;infoPannel&quot;&gt;
      
      <span style="font-family:courier new,courier,monospace;">&lt;/<span style="color:#ff0000;"><strong>xp</strong></span>:eventHandler&gt;</span></div>
      
      &nbsp;