<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#ffffff">
    The get/setActiveLayer methods are in the Map object (ie. the
    Fusion.getWidgetById('map') object) since the active layer can be
    set to any of the layers (ie. more than just aMaps[0]) <br>
    <br>
    Mike<br>
    <br>
    On 21/02/2011 6:31 AM, BTenBroeck wrote:
    <blockquote cite="mid:4D624D25.8070601@gmail.com" type="cite">
      <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
      <title></title>
      No, I'm trying to set a layer active, and then tell the selection
      tool to only use items on the active layer. I have the second
      piece working , but I don't want the user to have to manually set
      the layer active.<br>
      <br>
      On 2/20/2011 7:39 PM, zspitzer [via OSGeo.org] wrote:
      <blockquote
        cite="mid:AANLkTi=2ovSYVx5WEeN-J_Y-7p5J_Ok2hMASVFVtAWPZ@mail.gmail.com"
        type="cite"> what are you trying to do, turn a layer on? <br>
        <br>
        On Mon, Feb 21, 2011 at 2:39 AM, BTenBroeck &lt;<a
          moz-do-not-send="true"
href="/user/SendEmail.jtp?type=node&amp;node=6047126&amp;i=0&amp;by-user=t"
          target="_top" rel="nofollow" link="external">[hidden email]</a>&gt;
        wrote:
        <div class="shrinkable-quote"><br>
          &gt; <br>
          &gt; Hello all. This is a cross-post from the Fusion-users, as
          I had no luck <br>
          &gt; getting a response there. Hopefully the heavier traffic
          over here may bear <br>
          &gt; fruit. :) <br>
          &gt; <br>
          &gt; As the subject says, I'm trying to figure out the
          appropriate syntax to <br>
          &gt; set the active layer via Javascript in Fusion. <br>
          &gt; <br>
          &gt; What I've tried is: <br>
          &gt; <br>
          &gt;         var oMap = Fusion.getWidgetById('Map').aMaps[0];
          <br>
          &gt;         var activeLayer = oMap.setActiveLayer("Parcels");
          <br>
          &gt; <br>
          &gt; which seems like it's appropriate by looking at the
          Map.js widget. <br>
          &gt; However, it tossess an error, and if I view in Firebug,
          there is no method <br>
          &gt; in oMap for <br>
          &gt; setActiveLayer or getActiveLayer as I would expect. <br>
          &gt; <br>
          &gt; If anyone has a clue, or can point me in the right
          direction, I would <br>
          &gt; appreciate it. <br>
          &gt; <br>
          &gt; Thanks <br>
          &gt; -- <br>
          &gt; View this message in context: <a moz-do-not-send="true"
href="http://osgeo-org.1803224.n2.nabble.com/Syntax-to-set-Active-layer-in-Mapguide-via-Fusion-tp6045953p6045953.html?by-user=t&amp;by-user=t"
            target="_top" rel="nofollow" link="external">http://osgeo-org.1803224.n2.nabble.com/Syntax-to-set-Active-layer-in-Mapguide-via-Fusion-tp6045953p6045953.html</a><br>
          &gt; Sent from the MapGuide Users mailing list archive at
          Nabble.com. <br>
          &gt; _______________________________________________ <br>
          &gt; mapguide-users mailing list <br>
          &gt; <a moz-do-not-send="true"
href="/user/SendEmail.jtp?type=node&amp;node=6047126&amp;i=1&amp;by-user=t"
            target="_top" rel="nofollow" link="external">[hidden email]</a>
          <br>
          &gt; <a moz-do-not-send="true"
            href="http://lists.osgeo.org/mailman/listinfo/mapguide-users"
            target="_top" rel="nofollow" link="external">http://lists.osgeo.org/mailman/listinfo/mapguide-users</a><br>
          &gt; </div>
        <br>
        <br>
        <br>
        -- <br>
        Zac Spitzer <br>
        Solution Architect / Director <br>
        Ennoble Consultancy Australia <br>
        <a moz-do-not-send="true" href="http://www.ennoble.com.au"
          target="_top" rel="nofollow" link="external">http://www.ennoble.com.au</a><br>
        <a moz-do-not-send="true" href="http://zacster.blogspot.com"
          target="_top" rel="nofollow" link="external">http://zacster.blogspot.com</a><br>
        +61 405 847 168 <br>
        _______________________________________________ <br>
        mapguide-users mailing list <br>
        <a moz-do-not-send="true"
href="/user/SendEmail.jtp?type=node&amp;node=6047126&amp;i=2&amp;by-user=t"
          target="_top" rel="nofollow" link="external">[hidden email]</a>
        <br>
        <a moz-do-not-send="true"
          href="http://lists.osgeo.org/mailman/listinfo/mapguide-users"
          target="_top" rel="nofollow" link="external">http://lists.osgeo.org/mailman/listinfo/mapguide-users</a><br>
        <br>
        <br>
        <hr color="#cccccc" noshade="noshade" size="1">
        <div style="color: rgb(68, 68, 68); font: 12px
          tahoma,geneva,helvetica,arial,sans-serif;">
          <div style="font-weight: bold;">If you reply to this email,
            your message will be added to the discussion below:</div>
          <a moz-do-not-send="true"
href="http://osgeo-org.1803224.n2.nabble.com/Syntax-to-set-Active-layer-in-Mapguide-via-Fusion-tp6045953p6047126.html?by-user=t"
            target="_top" rel="nofollow" link="external">http://osgeo-org.1803224.n2.nabble.com/Syntax-to-set-Active-layer-in-Mapguide-via-Fusion-tp6045953p6047126.html</a>
        </div>
        <div style="color: rgb(102, 102, 102); font: 11px
          tahoma,geneva,helvetica,arial,sans-serif; margin-top: 0.4em;">
          To unsubscribe from Syntax to set Active layer in Mapguide via
          Fusion, <a moz-do-not-send="true"
href="http://osgeo-org.1803224.n2.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&amp;node=6045953&amp;code=YmlsbHRlbmJyb2Vja0BnbWFpbC5jb218NjA0NTk1M3w1MzM0ODEyNTU=&amp;by-user=t"
            target="_top" rel="nofollow" link="external">click here</a>.
        </div>
      </blockquote>
      <br>
      <hr width="300" align="left">
      View this message in context: <a moz-do-not-send="true"
href="http://osgeo-org.1803224.n2.nabble.com/Syntax-to-set-Active-layer-in-Mapguide-via-Fusion-tp6045953p6048362.html">Re:
        Syntax to set Active layer in Mapguide via Fusion</a><br>
      Sent from the <a moz-do-not-send="true"
href="http://osgeo-org.1803224.n2.nabble.com/MapGuide-Users-f1803227.html">MapGuide
        Users mailing list archive</a> at Nabble.com.<br>
      <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
mapguide-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:mapguide-users@lists.osgeo.org">mapguide-users@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/mapguide-users">http://lists.osgeo.org/mailman/listinfo/mapguide-users</a>
</pre>
    </blockquote>
  </body>
</html>