How do you get the path for a layer as a string (ArcGIS Pro SDK)?

Discussion created by JPHILLI2_TXDOT on May 9, 2019
Latest reply on May 9, 2019 by RRuh-esristaff

This seems like it should be pretty straight-forward but I cannot figure out how to get a layer object's filepath as a string.  Any help is much appreciated.  For example:

I have a layer object


var lyr = MapView.Active.Map.GetLayersAsFlattenedList().OfType<FeatureLayer>().First()



I would like to get lyr.Path() or something like that.  So that it will return: