title: Troubleshooting Web Extensibility Add-Ins In QTP 11.0
body: <p>I am trying to get custom Web element types to show up under Object Identification using QTP 11.0 Web Extensibility Add-Ins.</p>
  
  <p><img src="https://i.stack.imgur.com/Gv7DY.png" alt="add-in manager showing gwt and hidden"></p>
  
  <p>I have four files in my extension as shown at the end of the question. My problem is that none of the objects show up in the <code>Object Identification</code> window. I thought I might be doing something wrong, so I loaded the <code>GWT</code> sample that comes with the SDK, but it doesn't show anything in Object Identification either!</p>
  
  <p><strong>Does QTP keep a log or any sort of debugging information about what kind of error I might have, or is it working as intended and these custom objects aren't even <em>supposed</em> to show up in the Object Identification window? If so, why?</strong></p>
  
  <p><img src="https://i.stack.imgur.com/f3ION.png" alt="object identification window showing nothing"></p>
  
  <h2><code>$INSTALLDIR\dat\Extensibility\Web\HiddenTestObjects.xml</code></h2>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;TypeInformation Load="true" AddinName="Web" PackageName="Hidden" DevelopmentMode="true" priority="1"&gt;
      &lt;ClassInfo Name="Hidden" BaseClassInfoName="WebElement" GenericTypeID="object" DefaultOperationName="Set" FilterLevel="0"&gt;
          &lt;Description&gt;Input field of type="hidden".&lt;/Description&gt;
          &lt;TypeInfo&gt;
              &lt;Operation ExposureLevel="CommonUsed" Name="Set" PropertyType="Method"&gt;
                  &lt;Description&gt;Sets the content of the value attribute.&lt;/Description&gt;
                  &lt;Documentation&gt;&lt;![CDATA[Enter %a1 in the %l hidden field.]]&gt;&lt;/Documentation&gt;
                  &lt;!-- The text to enter in the box. If this argument is not provided, the box is cleared. --&gt;
                  &lt;Argument Name="text" IsMandatory="false" Direction="In"&gt;
                      &lt;Type VariantType="String"/&gt;
                  &lt;/Argument&gt;
              &lt;/Operation&gt;
          &lt;/TypeInfo&gt;
          &lt;IdentificationProperties&gt;
              &lt;IdentificationProperty ForDefaultVerification="true" ForVerification="true" ForDescription="true" Name="value"/&gt;
              &lt;IdentificationProperty ForDefaultVerification="false" ForVerification="false" ForDescription="true" Name="html tag" ForOptionalSmartID="true" OptionalSmartIDPropertyValue="1"/&gt;
              &lt;IdentificationProperty Name="html id" ForDefaultVerification="false" ForVerification="false" ForDescription="false"/&gt;
              &lt;IdentificationProperty Name="innerhtml" ForDefaultVerification="false" ForVerification="false" ForDescription="false"/&gt;
              &lt;IdentificationProperty Name="innertext" ForDefaultVerification="false" ForVerification="false" ForDescription="false" ForOptionalSmartID="true" OptionalSmartIDPropertyValue="2"/&gt;
              &lt;IdentificationProperty Name="outerhtml" ForDefaultVerification="false" ForVerification="false" ForDescription="false"/&gt;
              &lt;IdentificationProperty Name="outertext" ForDefaultVerification="false" ForVerification="false" ForDescription="false"/&gt;
          &lt;/IdentificationProperties&gt;
      &lt;/ClassInfo&gt;
  &lt;/TypeInformation&gt;
  </code></pre>
  
  <h2><code>$INSTALLDIR\dat\Extensibility\Web\Toolkits\Hidden\Hidden.xml</code></h2>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;Controls xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;
      &lt;Settings&gt;
          &lt;Variable name="common_file" value="HiddenCommon.js"/&gt;
      &lt;/Settings&gt;
      &lt;JSLibrariesToInject&gt;
          &lt;JSLibrary path="INSTALLDIR\bin\JSFiles\jQuery-1.3.2.js" /&gt;
          &lt;JSLibrary path="INSTALLDIR\bin\JSFiles\jQuery.simulate.js" /&gt;
      &lt;/JSLibrariesToInject&gt;
      &lt;Control TestObjectClass="Hidden"&gt;
          &lt;Settings&gt;
              &lt;Variable name="default_imp_file" value="Hidden.js"/&gt;
          &lt;/Settings&gt;
          &lt;Identification&gt;
        &lt;Browser name="*"&gt;
          &lt;HTMLTags&gt;
            &lt;Tag name="input"/&gt;
          &lt;/HTMLTags&gt;
          &lt;Conditions type="IdentifyIfPropMatch"&gt;
            &lt;Condition prop_name="type" expected_value="hidden" is_reg_exp="false" equal="true"/&gt;
          &lt;/Conditions&gt;
        &lt;/Browser&gt;
          &lt;/Identification&gt;
          &lt;Record&gt;
              &lt;EventListening use_default_event_handling_for_children="true" use_default_event_handling="true" type="javascript" function="ListenToEvents"/&gt;
          &lt;/Record&gt;
          &lt;Run&gt;
              &lt;Methods&gt;
                  &lt;Method name="Set" function="Set"/&gt;
              &lt;/Methods&gt;
          &lt;/Run&gt;
          &lt;Filter&gt;
              &lt;Spy is_control_spyable="Yes"/&gt;
              &lt;Learn learn_children="No" learn_control="Yes"/&gt;
          &lt;/Filter&gt;
      &lt;/Control&gt;
  &lt;/Controls&gt;
  </code></pre>
  
  <h2><code>$INSTALLDIR\dat\Extensibility\Web\Toolkits\Hidden\Hidden.js</code></h2>
  
  <pre><code>/////////////////////////////////////////////////////////////////////////
  // Hidden.js
  //
  // This file contains the implementation of the support for Hidden input controls.
  //
  /////////////////////////////////////////////////////////////////////////
  
  var HIDDEN_CATEGORY = 7;
  
  function get_property_value(property) {
      if (property == "logical name") {
          return "Hidden";
      }
      if (property == "type") {
          return "hidden";
      }
  
      if (property == "value") {
          return window.$(_elem).value;
      }
  
      if (property == "disabled") {
          return false;
      }
  }
  
  function Set(text) {
      preventReplayOnDisabledControl("Set");
      // NULL or empty text string can be used to clear the text area.
      // Convert both to an empty string.
      window.$(_elem).value = (text != null? text : "");
  
      var reportParams = new Array(text);
      _util.Report(micDone, "Set", toSafeArray(reportParams), "Set the following text:" + text);
      return true;
  }
  
  function ListenToEvents(elem) {
  
      return true;
  }
  </code></pre>
  
  <h2><code>$INSTALLDIR\dat\Extensibility\Web\Toolkits\Hidden\HiddenCommon.js</code></h2>
  
  <pre><code>/////////////////////////////////////////////////////////////////////////////////
  // HiddenCommon.js
  //
  // This file contains shared JavaScript functions that can be called by functions  
  // in other JavaScript files in the Hidden toolkit support set. 
  // 
  /////////////////////////////////////////////////////////////////////////////////
  
  function HTMLElemArrayToString(HTMLElemArray) 
  {
      var ElemArrayAsString = new Array();
      for (var i = 0; i &lt; HTMLElemArray.length; i++)
      {
          ElemArrayAsString.push(window.$(HTMLElemArray[i]).text());
      }
      return ElemArrayAsString.join(";");
  }
  
  function preventReplayOnDisabledControl(action) {
      if (get_property_value("disabled")) {
          _util.Report(micFail, action, toSafeArray(new Array()), "Cannot Replay On Disabled Control");
          throw "Cannot Replay On Disabled Control";
      }
  }
  
  function shouldIgnoreEvent(eventObj) {
      if (get_property_value("disabled")) {
          return true;
      }
      if (eventObj.button &amp;&amp; eventObj.button != QtpConstants.LEFT_BUTTON()) {
          return true;
      }
  
      return false;
  }
  </code></pre>