I suspect that the "llbbox" value is not correct.
Where does it come from and what does it look like ?

Pierre

On Thu, Jan 13, 2011 at 11:00 AM, Robert Buckley
<[email protected]> wrote:
> Hi,
>
> I have an ext window that reads my getcapabilities doc. thee BBar has a
> button which then add the layer to the map. However, when this is added it
> is zoomed right the way in to the largest scale.
>
> Why is this not working as it should?
>
> thanks for any help...
>
> here is the code
>
>  bbar: [{
>         text: "Add To Map",
>         handler: function() {
>             capabilitiesgrid.getSelectionModel().each(function(record) {
>                 var clone = record.clone();
>                 clone.get("layer").mergeNewParams({
>                     format: "image/png",
>                     transparent: true
>                 });
>                 mapPanel.layers.add(clone);
>                 map.zoomToExtent(
>                     OpenLayers.Bounds.fromArray(clone.get("llbbox"))
>                 );
>             });
>         }
>     }]
>
>
> yours,
>
> Robert
>
>
> _______________________________________________
> Users mailing list
> [email protected]
> http://www.geoext.org/cgi-bin/mailman/listinfo/users
>
>



-- 
Pierre GIRAUD
Géomaticien, Analyste

Camptocamp France SAS
Savoie Technolac, BP 352
73377 Le Bourget du Lac, Cedex

Tel : 00 33 4 79 44 44 93
Mail : [email protected]
http://www.camptocamp.com
_______________________________________________
Users mailing list
[email protected]
http://www.geoext.org/cgi-bin/mailman/listinfo/users

Reply via email to