1

I am trying to receive the user name on a mobile device. I have tried

Plugin.DeviceInfo;

but i get info only about the device. I need to get info about the name and the number that the user has. Any suggestions?

kostas
  • 779
  • 4
  • 13
  • 20

1 Answers1

0

Getting the User name will not work with Plugin.DeviceInfo; Plugin. This plugin is used to access DEVICE INFORMATION, such as OS, Device type... If you want to get the user name on Xamarin.Forms, you should do it separately on each platform and call the appropriate implementation with the Dependency Service. HERE is a great blog post which describes fully how to get the user name of a device owner with Xamarin.Forms. I think it is exacltly what you are looking for.

Damien Doumer
  • 1,991
  • 1
  • 18
  • 33