This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
protected override void OnMouseDown(ESRI.ArcGIS.Desktop.AddIns.Tool.MouseEventArgs arg) | |
{ | |
//create geometery | |
if (ArcMap.Document != null) | |
{ | |
IScreenDisplay screenDisplay = ArcMap.Document.ActiveView.ScreenDisplay; | |
// Constants | |
screenDisplay.StartDrawing(screenDisplay.hDC, (System.Int16)esriScreenCache.esriNoScreenCache); | |
// Explicit Cast |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public ICursor QueryRowViaQueryDef(IFeatureWorkspace featureWorkspace, String tables, String subFields, String whereClause) | |
{ | |
// Create the query definition. | |
IQueryDef2 queryDef = featureWorkspace.CreateQueryDef() as IQueryDef2; | |
// Provide a list of table(s) to join. | |
queryDef.Tables = tables; | |
// Declare the subfields to retrieve. | |
queryDef.SubFields = subFields; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
IMxDocument pMxDocument = ArcMap.Application.Document as IMxDocument; | |
IMap pMap = pMxDocument.FocusMap; | |
ILayer pLayer = pMap.get_Layer(0); | |
IFeatureLayer pFeatureLayer = (IFeatureLayer)pLayer; | |
IFeatureClass pFeatureClass = pFeatureLayer.FeatureClass; | |
IFields pFields = (IFields)pFeatureClass; | |
ITable pTable = (ITable)pFeatureClass; | |
ICursor pCursor = pTable.Search(null, false); | |
IRow pRow = pCursor.NextRow(); | |
while (pRow != null) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import org.json.JSONArray; | |
import org.json.JSONObject; | |
import java.sql.ResultSet; | |
import java.text.DecimalFormat; | |
import java.text.DecimalFormatSymbols; | |
import java.util.Locale; | |
/** | |
* Utility for converting ResultSets into some Output formats |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Install Ghost script before python package's installation from: http://www.a-pdf.com/convert-to-pdf/gs.exe | |
from wand.image import Image | |
from wand.display import display | |
fileDirectory = "D:/files/" | |
inFileName="infile.pdf" | |
outFileName="outfile.png" | |
imageFromPdf = Image(filename=fileDirectory+inFileName) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
from PIL import Image | |
imageFullPath = sys.argv[1] | |
rasterImage = Image.open(imageFullPath) | |
width,height = rasterImage.size | |
rasterImage = rasterImage.convert('RGBA') | |
pix = rasterImage.load() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var indexes = {}; | |
Data.forEach(function(indexPoint){ | |
var zoneIndexes = indexes[indexPoint.zoneId]; | |
if(zoneIndexes == null){ | |
indexes[indexPoint.zoneId] = zoneIndexes = {}; | |
} | |
zoneIndexes[indexPoint.date] = indexPoint.indexValue; | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<meta charset=utf-8 /> | |
<title>Identifying Imagery</title> | |
<meta name='viewport' content='initial-scale=1,maximum-scale=1,user-scalable=no' /> | |
<!-- Load Leaflet from CDN--> | |
<link rel="stylesheet" href="//cdn.jsdelivr.net/leaflet/0.7.3/leaflet.css" /> | |
<script src="//cdn.jsdelivr.net/leaflet/0.7.3/leaflet.js"></script> | |
<!-- Load Esri Leaflet from CDN --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name" : "", | |
"children" : | |
[ | |
{ | |
"name" : "Softwoods", | |
"children" : | |
[ | |
{ | |
"order" : 1, |
OlderNewer