Reputation: 11
Hi im using codename one for a study project(mobile project) im resending data from symfony
I resended all the attributes and they are displayed except one which is the image is there any way for displaying the image to codenameone ?
Upvotes: 1
Views: 169
Reputation: 67
Since the Codenamone doesn't support direct connection to database , you can't directly get access the images so you will just have to download the pictures and save them to your projects ,as for loading pictures i will assume you have a "path" variable in your entity so u can use this :
Image img = null;
try {
img = Image.createImage("/"+ a.getPath());
} catch (IOException ex) {
}
a is the entity on load
Upvotes: 0