Android framework version
net9.0-android
Affected platform version
VS 2022
Description
So I get an item from AdapterView using GetItemAtPosition and I get a JavaObject with an instance field in there that I need but I cannot access unless with Reflection as per some Stackoverflow posts on how to get the C# instance object out of a JavaObject. Why is this not available to us? Could someone make it available? :)
Steps to Reproduce
- Make new Android Project
- Use
ListView
- Have an
ArrayAdapter (for example)
- Use a class that is not
Java.Lang.Object for the items in ArrayAdapter.
- Add an Item Click
- Try using
AdapterView to GetItemAtPosition and be surprised that you can only get a Java.Lang.Object without being able to access the instance.
Did you find any workaround?
No response
Relevant log output
Android framework version
net9.0-android
Affected platform version
VS 2022
Description
So I get an item from
AdapterViewusingGetItemAtPositionand I get aJavaObjectwith an instance field in there that I need but I cannot access unless with Reflection as per some Stackoverflow posts on how to get the C# instance object out of a JavaObject. Why is this not available to us? Could someone make it available? :)Steps to Reproduce
ListViewArrayAdapter(for example)Java.Lang.Objectfor the items inArrayAdapter.AdapterViewtoGetItemAtPositionand be surprised that you can only get aJava.Lang.Objectwithout being able to access the instance.Did you find any workaround?
No response
Relevant log output