locked
[UWP]DeviceInformation FindAllAsync BluetoothLEDevice Incorrect parameter RRS feed

  • Question

  • Hello

    I am developing a Windows Phone application, which is working with BLE devices. In Windows Phone 8.1 it works great, but after that when i updated my phone to Windows 10,the app throws "Incorrect parameter" error.

    await DeviceInformation.FindAllAsync(BluetoothLEDevice.GetDeviceSelector())

    This is the program line, which throws the error.

    Can someone help me, how can i fix this?

    Thanks.



    • Edited by david.haja Monday, January 25, 2016 2:39 PM
    • Edited by Krunal Parekh Tuesday, January 26, 2016 5:17 AM subject
    Monday, January 25, 2016 11:18 AM

All replies

  • Hello David Haja,

    >>I am developing a Windows Phone application, which is working with BLE devices. In Windows Phone 8.1 it works great, but after >>that when i updated my phone to Windows 10,the app throws "Incorrect parameter" error.

    I tested this issue with Emulator 10.0.10586 and on NOKIA - RM 1010 Model but was not able to reproduce the issue. Could you give me your sample project in which this is reproducible I will test it on my side.

    With Regards,

    Krunal Parekh


    Thanks MSDN Community Support Please remember to Mark as Answer the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Tuesday, January 26, 2016 5:16 AM
  • If it's any help, I get the exact same thing.  Krunal, to demonstrate the problem, simply make an standard Windows 10 Universal app, add in an Loaded handler in the MainPage.xaml.cs file, and literally add the single line that David has.

    Expected result: a list of devices is created.

    Actual result: it throws an exception. 

    Tuesday, January 26, 2016 6:21 AM
  • Hello PeterSmith-Shipwreck,

    >>simply make an standard Windows 10 Universal app, add in an Loaded handler in the MainPage.xaml.cs file, and literally add the >>single line that David has.

    That is exactly what i did and was not able to reproduce the issue on my side. My Target SDK is 10586. Could you check that? 

    private async void Page_Loaded(object sender, RoutedEventArgs e)
    		{
    			var x = await DeviceInformation.FindAllAsync(BluetoothLEDevice.GetDeviceSelector());
    		}

    With Regards,

    Krunal Parekh 


    Thanks MSDN Community Support Please remember to Mark as Answer the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Tuesday, January 26, 2016 6:52 AM
  • Hello Krunal Parekh,

    I am using Nokia Lumia 630 with OS build: 10.0.10586.36 . My project now contains only that one line, but it gives the same error.

    Tuesday, February 2, 2016 11:38 AM
  • Hello David Haja,

    >>I am using Nokia Lumia 630 with OS build: 10.0.10586.36 . My project now contains only that one line, but it gives the same error.

    I would recommend opening a support ticket for this since I can not confirm this from my side right now.

    1.) Go to http://aka.ms/storesupport (sign in using your MSDN Subscription if applicable)

    2.) Under "App development" click the “Windows 10 Universal app development” OR "Windows 8.x app development” link based on where they are experiencing the problem.

    3.) On the next page, choose Problem type = Support for Writing apps, Category = <<appropriate category>>

    4.) Then choose the "Start request" link to start a support request.

    Support incident charges will be refunded if they are caused by a Microsoft bug.

    With Regards,

    Krunal Parekh


    Thanks MSDN Community Support Please remember to Mark as Answer the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Thursday, February 4, 2016 8:00 AM
  • Hello David,

    Could you fix that error? I got the same error on a LUMIA 730 and a similar one on LUMIA 950! Only the old LUMIA 920 is out of error. Here my test: 

      var deviceInfoList = await DeviceInformation.FindAllAsync(BluetoothLEDevice.GetDeviceSelector());
      foreach (var di in deviceInfoList)
      {
          var bleDevice = await BluetoothLEDevice.FromIdAsync(di.Id);
          ...
    
    LUMIA 950, Windows 10, 1511, 10.0.14332.1001
    Exception thrown on FromIdAsync(): 'System.IO.FileNotFoundException' in mscorlib.ni.dll
     

    LUMIA 730, Windows 10, 1511, 10.0.10586.218
    Exception thrown on
    FindAllAsync(): 'System.ArgumentException'

    LUMIA 920, Windows 10, 1511, 10.0.10586.218
    No Error!

    This is not satisfactory. I am trying to develop an app with Bluetooth connections - and I cannot see how this can work, when the devices have such types of errors.

    With regards,
    RoDiPa

    Wednesday, May 11, 2016 9:00 PM
  • I have the same problem with a Lumia 1520 I updated to Windows 10. I am publishing a Windows Phone 8.1 app.
    • Edited by om9 Saturday, July 16, 2016 7:32 PM
    Saturday, July 16, 2016 7:32 PM
  • Same problem here. I wasn't able to reproduce the crash on my Lumia 620 (Windows Phone 8.1), but I've received emails from Windows 10 users reporting crashes at the point where Bluetooth devices are enumerated.
    Thursday, October 27, 2016 9:15 PM
  • Any news on this issue?
    Sunday, December 11, 2016 11:20 AM