I have a textView. In my code I am adding some lines of text in it. I also want to display some image from an external URL (not from my resource folder) just in between those lines. Every thing is dynamic i.e. the text generated and the image URL will be generated on the flow.So i have to fetch the image through my code and add it.
Wondering if there is a way to insert images from external URL within text view? Also any better approach is always welcome.
You will have to use this along with asynctask, open connection in
doInbackground()
set image to textview inonPostExecute()
hope it helps
You are going to probably want to use an asynctask to grab the image. This will run in the background from your other tasks. Your code may look something like this: