Set the defaultLengthUnit to esriFeet and the defaultAreaUnit to esriSquareFeet.
Example:
measurement = new Measurement({
map: map, defaultLengthUnit: "esriFeet", defaultAreaUnit: "esriSquareFeet"
}, dom.byId('measurementDiv'));
measurement.startup();
Ian,
Look here for more documentation:
Measurement | API Reference | ArcGIS API for JavaScript
What I found unclear about this Measurement | API Reference | ArcGIS API for JavaScript documentation is that it references this Object: Units page, but when I used just "FEET" & "SQUARE_FEET" in the Measurement's parameters I get errors. Hunting around I found the reference to set the parameter values to esriFeet & esriSquareFeet in the
Web AppBuilder's API reference for the Measurement widget.
Přihlášení členové mohou přispívat, sledovat aktualizace a další. Jste tu noví? Zaregistrujte si bezplatný účet.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.