[mapguide-users] Digitize rectangle in Fusion

ar_gaeta ar_gaeta at yahoo.it
Wed Jun 8 04:24:26 EDT 2011


Hi all. I've read some about this topic but without found a solution. In
particular this article:

http://kb.cnblogs.com/a/1751563/

but it didn't work for me.

I have put my FlexibleLayout into a Frame called "iFrameMap", and I load in
the "TaskPane_IFRAME" a script in java named "index.jsp" that contains these
strings:




function OnDigitizeRectangle() {
		alert("OK-1");
		DigitizeRectangle(OnRectangleDigitized);
}

function OnRectangleDigitized(rect) {
		alert("OK-2");
		minX = Math.round(rect.Point1.X / 1000);
		minY = Math.round(rect.Point2.Y / 1000);
		maxX = Math.round(rect.Point2.X / 1000);
		maxY = Math.round(rect.Point1.Y / 1000);
}

<input type="button" value="Rettangolo" onclick="OnDigitizeRectangle();">

But when I click on the button "Rettangolo" nothing happen and the cursor is
still the same.
I've add the reference to the file MapGuideViewerApi.js, but I don't know if
it is recognised by the script.
In any case, I've put some "alert" message to see where the script stop to
execute, and I'm able to see the first alert ("OK-1") but not the second one
("OK-2").

Someone coul help me please to let me focus on the problem?

Thanks very much,
Riccardo

My system: Win7, MGOS 2.2, Apache/Tomcat

--
View this message in context: http://osgeo-org.1803224.n2.nabble.com/Digitize-rectangle-in-Fusion-tp6452771p6452771.html
Sent from the MapGuide Users mailing list archive at Nabble.com.


More information about the mapguide-users mailing list