Hi Guys
I´m newbie in CGA.
I tried apply Color in (2D) Shapes based on Land Use atribute. I use 3DCIM_Parcel_Zoning Envelopes.cga as a sample, but this CGA change my geometry (Angles)
I need a simple CGA sample for apply a Color based on attribute, without geometry operations, just change colors.
This is a simple rule example. One attribute determines color. That color is shown in the other attribute, YourColor, and that color attribute can be overridden by the color picker on that attribute.
Chris
version "2014.1" @Range("Go", "Caution", "Stop") attr DeterminesColor = "Go" @Color attr YourColor = theFunctionThatGivesColorPerAttribute @StartRule ColorMeMine --> color(theFunctionThatGivesColorPerAttribute) theFunctionThatGivesColorPerAttribute = case DeterminesColor == "Go": "#00FF00" #Green case DeterminesColor == "Caution": "#FFAA00" #Orange case DeterminesColor == "Stop": "#FF0000" # Red else: "#000000" #Error! Picker value unknown. Use black.
Thank you so much Mr Chris
Work´s fine 🙂
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.