I have a barcode scanner app. I am trying to scan barcode and search at google. But when I try to search as mentioned here , It says Uri.Parse()
deprecated . I couldn't find anything useful and Uri
documentation does not say anything about it.
Uri Documentation
https://developer.android.com/reference/android/net/Uri.html
Is there any other option or replacement it?
You are referencing the Uri
from System
in which Parse
is Obsolete
:
[ObsoleteAttribute("The method has been deprecated. It is not used by the system.
protected virtual void Parse()
The SO question you are referencing is using Uri
from the Android.Net
namespace:
Android.Net.Uri uri = Android.Net.Uri.Parse("http://www.google.com/#q=fish");
var intent = new Intent(Intent.ActionView, uri);
StartActivity(intent);
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.