POST
|
A simple print doesn't work. Of course, I want an array like you said, but the event is blocked by the line drawing (doesn't even print the x, y of onMouseDownMap). That's the issue I'm having.
... View more
09-09-2018
10:16 PM
|
0
|
0
|
139
|
POST
|
Hi Randy, Yes, I read that, as you see, this code uses None shape, and i need the mouse events to work while in line shape event. Do you hace a solution to that? Yoav.
... View more
09-09-2018
02:42 PM
|
0
|
0
|
958
|
POST
|
Do you know if there is something like that in arcobjects, in case illI have to rewrite everything in c# for skipping a point? I want just the coords of the points whike there been drawn 😕
... View more
09-08-2018
07:04 PM
|
0
|
1
|
958
|
POST
|
Hi Mark, Thanks for replying. What do you mean by following? I did read all the documentations and every existing post here/gis-stockexcstock before I posted this . But, i didn't see anywhere a mention about one event blocking the other. I did see that by using None shape, you can utilize the on events handlers, but as I mentioned above, I must have a line drawing while using them 😕 I you have any idea what to do, it will be much appreciated! Yoav.
... View more
09-08-2018
06:41 PM
|
0
|
1
|
958
|
POST
|
Hi, Not sure I've understand you correctly, if you are trying to filter out null values, you can do that with sevral ways: 1. inside the SearchCursor itself, with a where_clause sql expression: wc = '{} IS NOT NULL'.format('CityName')
rows1 = arcpy.SearchCursor(Cities, 'CityName', where_clause=wc)
# The Rest of your code Alternatively, you could filter the null values while iterating: with arcpy.da.SearchCursor(Cities, 'CityName') as cursor:
for row in cursor:
if row[0] is not None:
# The Rest of your code Hope it helps, Yoav.
... View more
09-08-2018
05:30 PM
|
1
|
1
|
780
|
POST
|
Hi, I'm having issuses while developing a new addin - it seems that ALL mouse event handlers (except onMouseMove[Map]), doesn't work / blocked when I draw a line in on the map. I really need that functionality, since my tool need to ignore certain points on the polyline, indicated by ctrl+left mouse click. Does anybody knows how can I get thouse events while drawing a line? Thanks, Yoav. P.S: There's a code example: class DrawLine(object):
"""Implementation for SomeToolExample.drawline (Tool)"""
def __init__(self):
self.enabled = False
self.shape = "Line"
def onMouseDown(self, x, y, button, shift):
# This DOESN'T work (blocked?) while a drawing a line
pass
def onMouseDownMap(self, x, y, button, shift):
# This DOESN'T work (blocked?) while a drawing a line
pass
def onMouseUp(self, x, y, button, shift):
# This DOESN'T work (blocked?) while a drawing a line
pass
def onMouseUpMap(self, x, y, button, shift):
# This DOESN'T work (blocked?) while a drawing a line
pass
def onMouseMove(self, x, y, button, shift):
# This is working while a drawing a line
pass
def onMouseMoveMap(self, x, y, button, shift):
# This is working while a drawing a line
pass
def onDblClick(self):
pass
def onKeyDown(self, keycode, shift):
# This DOESN'T work (blocked?) while a drawing a line
pass
def onKeyUp(self, keycode, shift):
# This DOESN'T work (blocked?) while a drawing a line
pass
def deactivate(self):
pass
def onLine(self, line_geometry):
# Main Logic here, not important for this example
pass
... View more
09-07-2018
11:36 AM
|
0
|
10
|
1600
|
Title | Kudos | Posted |
---|---|---|
1 | 09-08-2018 05:30 PM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:25 AM
|