protected override async void OnClick()
        {
            if (MapView.Active == null)
            {
                return;
            }

            // find a 3d symbol
            var spi = Project.Current.GetItems <StyleProjectItem>().First(s => s.Name == "ArcGIS 3D");

            if (spi == null)
            {
                return;
            }

            bool result = await QueuedTask.Run(() =>
            {
                var style_item = spi.SearchSymbols(StyleItemType.MeshSymbol, "").FirstOrDefault(si => si.Key == "White (use textures) with Edges_Material Color_12");
                var symbol     = style_item?.Symbol as CIMMeshSymbol;
                if (symbol == null)
                {
                    return(false);
                }

                // get the multipatch shape
                var origMultipatch = MyMultipatchBuilder.CreateTriangleMultipatchGeometry();

                // move it in the z direction
                var newMultipatch = GeometryEngine.Instance.Move(origMultipatch, 0, 0, 10) as Multipatch;

                CIMMultiPatchGraphic graphic = new CIMMultiPatchGraphic()
                {
                    MultiPatch = newMultipatch,
                    Symbol     = symbol.MakeSymbolReference()
                };

                MapView.Active.AddOverlay(graphic);

                // or just use
                // MapView.Active.AddOverlay(newMultipatch, symbol.MakeSymbolReference());

                return(true);
            });
        }
        protected override async void OnClick()
        {
            if (MapView.Active?.Map == null)
            {
                return;
            }

            // find layer
            var member = MapView.Active.Map.GetLayersAsFlattenedList().FirstOrDefault(l => l.Name == "MultipatchWithTextureSimple") as FeatureLayer;

            if (member == null)
            {
                return;
            }

            // get the multipatch geometry
            var multipatch = MyMultipatchBuilder.CreateTriangleMultipatchGeometry();

            // create a new feature
            bool result = await QueuedTask.Run(() =>
            {
                // track the newly created objectID
                long newObjectID = -1;

                var op  = new EditOperation();
                op.Name = "Create multipatch feature";
                op.SelectNewFeatures = false;
                op.Create(member, multipatch, oid => newObjectID = oid);
                if (op.Execute())
                {
                    // save the oid in the module for other commands to use
                    Module1.MultipatchOID = newObjectID;
                    return(true);
                }

                var msg = op.ErrorMessage;
                return(false);
            });
        }