Hi there,
I am trying to get my UserControl be found like this:
ICommandItem pItem = pApplication.Document.CommandBars.Find(pUID, false, false);
MyUserControlType pMyTool = pItem.(Command as MyUserControlType);
But I cannot see the row with word "Command" (when drop down menu appears - see the image attached).
What I do wrong?
I am in 10.3 Desktop ArcObjects C#.
Any help will be appreciated.
Solved! Go to Solution.
I can't find command property too but when I typed the property it works fine.
ICommand pCommand = pItem.Command as ICommand;
Then you can cast it to your type.
I can't find command property too but when I typed the property it works fine.
ICommand pCommand = pItem.Command as ICommand;
Then you can cast it to your type.