o2_design

graph network layer attributes not mapping

Discussion created by o2_design on Mar 26, 2014
Latest reply on Jul 14, 2016 by mohsennazemi
Hello,

I'm attempting to implement a custom layer attribute rule for graph networks, but am running into some trouble. I modified the ce.lib\shp.ceattr file so I could automatically adjust graph network parameters from specific shapefile attributes (generated through a schema I regularly use).

The street width adjusts, but the sidewalk widths don't. Even if I remap the attributes directly to the shapefile, where I know there are values > 0 (instead of relying on an expression in the rule), still no go. The attached image shows how it looks in CE.

Other than adding a new attribute for the new landWidth parameter, I haven't changed anything since implementing this successfully code in version 2012.1...?

The layer attribute rule is as follows:

// Shape Tag Mapping

streetscale = 1  // street width scale factor

width = getObjectAttr("width")
swide = getObjectAttr("sidewalk")
lwide = getObjectAttr("VEH_WIDE")

check = getObjectAttr("ROW_WIDE")

default_road = 0
default_side = 0

attr streetWidth = 
 case check == 0:
  default_road * streetscale 
 else:
  width * streetscale
  
attr sidewalkWidthLeft = 
 case check == 0: 
  default_side * streetscale 
 else:
  swide * streetscale
  
attr sidewalkWidthRight =
 case check == 0: 
  default_side * streetscale 
 else:
  swide * streetscale
  
attr laneWidth = 
 case check == 0:
  default_road * streetscale 
 else:
  lwide * streetscale



Thanks in advance!


[ATTACH=CONFIG]32546[/ATTACH]

Attachments

Outcomes