It is advisable to index DeviceList before StopScanning?
ListView.Elements, for example, is populated with DeviceList, in the same order, when DeviceFound occurs. If the user selects an item from ListView in order to connect the device at that index, but suddenly, new devices is found by the scanner and DeviceList changes, then the saved index may no longer be valid, right?
If that possibility exists, what is advisable to do?
Maybe reset a timer when every DeviceFound occurs, and if timer expires (no more device found in a few seconds), then StopScanninng automatically and allow indexing of the DeviceList.
Note that this also depends on the extension version you are using. Newer versions maintain a stable ordering of the devices in the list. Older versions would produce a "random" ordering based on the hashes of the MAC addresses of all of the discovered devices, so as new devices were discovered during a scan, new devices would be inserted at random points in the exist list. For safety it is as Ghica says to stop scanning first to ensure the list won't change regardless of the BLE extension's behavior.