I have the scenario were user would click and identify any feature layer on the webmap.
how can i select the feature after it was identified in the 'identifyLayersWithMaxResults' scenario?
how can i get the layer url path?
The referenced sample should get you on the right track. The key is to call "identifyLayers" (with an "s"), which will search for clicked features in any layer in the map. If you use "identifyLayer", you will need to pass in specific layer objects into the method.
The result is an identify result object, which you can get the features/geo elements from and make a selection. Check out this sample for that workflow - arcgis-runtime-samples-qt/FeatureLayer_Selection.qml at master · Esri/arcgis-runtime-samples-qt · Gi...