I’m using the DHTMLXgrid component in an Iframe. Now when i click on a row (which causes an event to run) or uncheck a checkbox (also event runs), i need the event to affect the parent window.
For example: (this function runs when a row is selected)
function doOnRowSelected(id){
protocolIt(“Rows with id: “+id+” was selected by user”)
//alert(LocationChecks[id].long);
map.setCenter(new GLatLng(LocationChecks[id].lat,LocationChecks[id].long), 10);
}
So this function works when its NOT in an iframe. But when in a Iframe my research leads me to believe that i would have to add a [parent.document/parent.] command infront of these commands, but this doesn’t work.
Do you have any ideas???
Thanks in Advance.
Mac
You need to add “parent” ( or “top” in case of multilevel frame structure ) when reffer to object|functions defined in top frame
function doOnRowSelected(id){
top.protocolIt(“Rows with id: “+id+” was selected by user”)
//alert(LocationChecks[id].long);
top.map.setCenter(new GLatLng(LocationChecks[id].lat,LocationChecks[id].long), 10);
}
There is no any grid-specific rules for iframe operations.