<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
</head>
<body bgcolor="#ffffff" text="#000000">
Yes I now have two separate pages.&nbsp; The example URLs in my earlier
message will be broken now.<br>
That works but there are some bugs.<br>
The base layer switching still doesn't work - having two pages is
merely a work around.<br>
<br>
I've also found a problem with Firefox (but not IE). My OpenLayer's div
has a 100% width setting (in CSS). This works fine for the other
layers, but the VE layer does not respect it and appears to use a
default fixed setting.<br>
Overriding a fixed width for the div appears to work, but this doesn't
fit with my site style/template very well!<br>
<br>
And another issue is that only v3 &amp; v4 are supported - both are
being retired by Microsoft at the end of August. I've filed a ticket on
this one.<br>
<br>
For positive news, I've also sent a "how to" article to ViaVirtualEarth.<br>
<br>
My maps are at:<br>
<br>
<a class="moz-txt-link-freetext"
 href="http://www.ecomapcostarica.com/map/index.shtml">http://www.ecomapcostarica.com/map/index.shtml</a><br>
<a class="moz-txt-link-freetext"
 href="http://www.ecomapcostarica.com/map/index_ve.shtml">http://www.ecomapcostarica.com/map/index_ve.shtml</a><br>
<br>
<br>
We hope to have some updates (map updates and student blogs) whilst
we're out in the field from the 27th onwards.<br>
<br>
Richard Marsden<br>
Winwaed Software Technology LLC<br>
<a class="moz-txt-link-freetext" href="http://www.winwaed.com">http://www.winwaed.com</a><br>
<a class="moz-txt-link-freetext" href="http://www.mapping-tools.com">http://www.mapping-tools.com</a><br>
<br>
<br>
getdano wrote:
<blockquote cite="mid:17236190.post@talk.nabble.com" type="cite">
  <pre wrap="">I am experiencing the same behavior. The VE Layer works great by itself but
as soon as you select another base layer, selecting the VE layer does not
bring it back. 

I don&#8217;t believe this was a problem in the previous version of OpenLayers. In
fact, I replaced the 2.6 lib files with the 2.5 lib files and the base
layers example works fine with the older lib. 

Is there some change that I have missed in the upgrade? Any advice would be
greatly appreciated.




Richard Marsden-119 wrote:
  </pre>
  <blockquote type="cite">
    <pre wrap="">I am currently using MapServer and OpenLayers for an online mapping 
project to display a rain forest study area - unfortunately I'm a bit 
of  a beginner with both! I'm currently having problems using Virtual 
Earth in OpenLayers: in particular switching between layers, and with VE 
versions.

Virtual Earth isn't suitable for the main map because our study area is 
only about 10ha of Costa Rican rain forest - ie. the detail just isn't 
there. However, I am try to use Virtual Earth as an optional base map to 
show the study area in context.

I've managed to get the OpenLayers Virtual Earth sample working with a 
MapServer WMS hydrology overlay ('synthetic streams').
I'm currently trying to get it to work with an alternative "outline map".

Ie. there are two base layers that can be chosen with a pair of radio 
buttons in the LayerSwitcher:  'Virtual Earth Base Layer',  and  
'Outline'   (WMS delivered shape file)
An optional overlay  is selected with a checkbox:  'Synthetic streams' 
(also via WMS).

This is a work in progress so the colours could be improved, but my 
results are here:

<a class="moz-txt-link-freetext"
 href="http://www.ecomapcostarica.com/map/map_beta.html">http://www.ecomapcostarica.com/map/map_beta.html</a>

Virtual Earth imagery loads okay at first. Switching to the 'Outline' 
works as well. However, when I switch back to Virtual Earth, it fails to 
re-appear. Instead, Outline is replaced with a white fill.

What am I doing wrong?  Or is this kind of behaviour not supported?

This is my Javascript:

&lt;script
src=<a class="moz-txt-link-rfc2396E"
 href="http://dev.virtualearth.net/mapcontrol/v3/mapcontrol.js">"http://dev.virtualearth.net/mapcontrol/v3/mapcontrol.js"</a>&gt;&lt;/script&gt;

    &lt;script src="./OpenLayers.js"&gt;&lt;/script&gt;

    &lt;script type="text/javascript"&gt;
        var lon = -84;
        var lat = 10;
        var zoom = 7;
        var map;
        var stream_layer, velayer, bound_layer, outline_layer;

        function init(){
            map = new OpenLayers.Map( 'map' );

            velayer = new OpenLayers.Layer.VirtualEarth("Virtual Earth
Base Layer", 
{ minZoomLevel: 4, maxZoomLevel: 8, 'type': VEMapStyle.Aerial } );
            map.addLayer(velayer);


            outline_layer = new OpenLayers.Layer.MapServer( "Outline", 
                   
<a class="moz-txt-link-rfc2396E"
 href="http://www.ecomapcostarica.com/map/mapserv.cgi?map=/usr/home/winwaed/mapdata/cr_outline.map">"http://www.ecomapcostarica.com/map/mapserv.cgi?map=/usr/home/winwaed/mapdata/cr_outline.map"</a>,
{layers: 'outline'},
                    {gutter: 15});
            map.addLayer(outline_layer);

            stream_layer = new OpenLayers.Layer.MapServer( "Synthetic
Streams", 
                   
<a class="moz-txt-link-rfc2396E"
 href="http://www.ecomapcostarica.com/map/mapserv.cgi?map=/usr/home/winwaed/mapdata/cr_stream.map">"http://www.ecomapcostarica.com/map/mapserv.cgi?map=/usr/home/winwaed/mapdata/cr_stream.map"</a>,
{layers: 'streams', transparent:'true'},
                    {gutter: 15});
            map.addLayer(stream_layer);



            map.setCenter(new OpenLayers.LonLat(lon, lat), zoom);
            map.addControl( new OpenLayers.Control.LayerSwitcher() );
        }
                  
    &lt;/script&gt;


----

I've also tried changing the script to use v6.1 of the Virtual Earth 
Control,  ie.:

&lt;script 
src=<a class="moz-txt-link-rfc2396E"
 href="http://dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=6.1">"http://dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=6.1"</a>&gt;&lt;/script&gt;

The results can be seen here:

<a class="moz-txt-link-freetext"
 href="http://www.ecomapcostarica.com/map/map_ve.html">http://www.ecomapcostarica.com/map/map_ve.html</a>

The default "North America" map appears  - not my selected area at all, 
and none of the OpenLayers controls (zoom, layer selection, etc) appear.

Is v3 the latest version supported by OpenLayers?  Are there any plans 
to update this in the near future?  I see that Microsoft are actively 
retiring old versions of the Virtual Earth API.

Thanks in advance.  OpenLayers and MapServer are both capable of some 
pretty neat stuff - I have high hopes regarding the final result!


Richard Marsden
Wiwnaed Software Technology LLC
<a class="moz-txt-link-freetext" href="http://www.winwaed.com">http://www.winwaed.com</a>
<a class="moz-txt-link-freetext" href="http://www.mapping-tools.com">http://www.mapping-tools.com</a>







_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@openlayers.org">Users@openlayers.org</a>
<a class="moz-txt-link-freetext"
 href="http://openlayers.org/mailman/listinfo/users">http://openlayers.org/mailman/listinfo/users</a>


    </pre>
  </blockquote>
  <pre wrap=""><!---->
  </pre>
</blockquote>
</body>
</html>