Usuario anónimo  |  Ingresar  |  Regístrate
Mensaje dentro Bugs and Improvements

Dynamically added GMap

#1 - 31/03/2010 13:01:12 Reporta abuso | Link permanente
Fecha de registro: 02/02/2009
1 post en todos los foros
Dynamically added GMap

Responder Citar

Have seensome people with the same kind of problem, without a solution,  so this post Issimply what was causing my problem, and how I solved it.

I havebeen using GoogleMaps.Subgurim since  and have successfully upgraded to inthe past, but I was getting 2 exceptions when I tried  to upgrade to newer, on all browsers.

Have found out that the first exception occurred because of thefollowing code:


DragZoomControl dragZoomControl = new DragZoomControl();


DragZoomOtherOptions dragZoomOtherOptions = new DragZoomOtherOptions();

dragZoomOtherOptions.buttonHTML = "Zoom";


dragZoomControl.dragZoomOtherOptions = dragZoomOtherOptions;


DragZoomBoxStyleOptions dragZoomBoxStyleOptions = newDragZoomBoxStyleOptions();

dragZoomBoxStyleOptions.opacity = 0.5;

dragZoomBoxStyleOptions.fillColor = Color.Blue;

dragZoomControl.dragZoomBoxStyleOptions =dragZoomBoxStyleOptions;


GControl dragzoom =new GControl(dragZoomControl,new GControlPosition(GControlPosition.position.Top_Left));



The error occurredon line 2 in some dynamic file, where“DragZoomControl.prototype=new GControl();”is stated, and returns an MicrosoftJSCript-error which states that 'GControl' isn’t defined.


The secound exception occures on line 298 in the same dynamic file, butthe statement is “addEvent(window,'unload',GUnload);”, where it also returns an Microsoft JSCript-error which states that 'GUnload' isn’t defined.

Both errorsoccurred because I was adding the GMap dynamically onto a panel, so the problemwas solved when they were statically added to the page with visible = false.

The weird thingis that I worked perfectly before, but couldn’tfind a reason in the changelog.



Volver arriba

De en 15
#2 - 07/04/2010 8:56:16 Reporta abuso | Link permanente
Fecha de registro: 18/10/2006
2003 posts en todos los foros
RE: Dynamically added GMap

Responder Citar
Volver arriba
De en 15

Powered by Subgurim.NET