I'm trying to find a Line Symbol in the project style items but the function returns an empty collection. This is my reference
//Get all styles in the project
var styleProjectItem2D = Project.Current.GetItems<StyleProjectItem>().FirstOrDefault(s => s.Name == "ArcGIS 2D");
//Get a specific style in the project by name
var arrowLineSymbol = styleProjectItem2D.SearchSymbols(StyleItemType.LineSymbol, "Arrow Line 2 (Mid)")[0];
The 'Arrow Line 2 (Mid)' symbol cannot be found even though it is available in the ArcGIS Pro project style
Solved! Go to Solution.
Hi,
You can repair project manually. Project file is renamed zip file. You can extract it and modify damaged part.
More info in my own question here:
Hi,
I have similar situation with color ramps month ago. It was problem with ArcGIS Pro project. Have you tried your code on new created ArcGIS Pro project?
Thanks for the suggestion, running the code on another project found the symbols.
How to solve this problem in those projects where symbols are not found?
Hi,
You can repair project manually. Project file is renamed zip file. You can extract it and modify damaged part.
More info in my own question here: