Anonymous user  |  Log in  |  Create Account
Mensaje que reportas
Titulo:  Serverevent Asynchrone?
Autor: Mansur
Fecha:  11/6/2009 1:03:30 PM
Texto: Hello,

What I think is that the ServerEvent is asynchrone:

var ev = new serverEvent('dblclick', {0});
ev.send();        // <-- Asynchrone Call?


If yes. Is there an Event like "onreadystateChanged"?

What I try is to use the Serverevent for some Zoomin-Events (dblclick, zoomend, moveend) on the Server. in the Servercode I tryed to access Objects on the page which failed.

Samplecode:
protected string GoogleMap_ServerEvent(object s, GAjaxServerEventOtherArgs e)
{

Label myLabel = (Label)Page.FindControl("myLabelID");

}

I think this fails because the ServerEvent is not in the regular Page-Livecycle. Am I right?

So Question:

Does anybody has an good Idea on how to access the Page while in the ServerEvent?

Other Question:
I try'ed to add on the GMap1.addListener - JavaScript code somethink like:

document.getElementById('SomeAspButtonClientId').click();

Basically this works, but because the ServerEvent-send() Method is asynchrone it fails because the Serverevent may is not completed .. and so I miss Information in the Button-Click-Event.

Any Suggestions?

Mansur


¿Qué es reportar?
Por reportar entedemos que has leído algo en la Web que no te parece correcto y crees conveniente avisar a los administradores y moderadores para que revisen lo que reportas y decidan si deben editar o en el peor caso borrar.
Ejemplo de reporte pueden ser los siguientes:
- El mensaje debería estar en otra sección de la página, por ejemplo en otro foro.
- Un enlace está roto.
- El mensaje es SPAM y no aporta ningún contenido a la Web. Por ejemplo un mensaje de alguien publicitando su página web sin motivo alguno.
- Es un mensaje con malas intenciones, que no responde a la filosofía de la web, por ejemplo porque insulta a otro mensaje.

Rellenar reporte
Nivel de urgencia:
Motivos del reporte:
Powered by Subgurim.NET