Hi there I am trying to implement simple functionally but I am unable to make it. I have a list view with some elements and that elements have an image (Since there is no control for images, I have a Visualelement with a background image).
I will like to change the image texture by code but I am unable to access that property
I have tried the following code but StyleBackground is not a variable. Any help will be appreciated
VisualElement mainImg = adapter.Q<VisualElement>("MainImg");
StyleBackground background = mainImg.style.backgroundImage;
background.value.texture = module.moduleIcon;