Android : Load images from external folder in Server - android

I am relatively new to android and I am currently working on an android app that displays and stores profile information of registered users:
The app communicates with a server using .Net(WCF) webservice and a
PostgreSQL Database.
In the Server(Virtual Machine), I have an existing folder containing hundreds of pictures(named after the username of each user). Example: A User login is Aadrian, then his picture is found in the folder under the name "Aadrian.jpg" in the folder.
Question: I have a custom listview (with imageview and textviews) showing each user information and I would like to ask for help to know how to load these images from the folder in the server and assign each user in the list to his corresponding picture in the external folder. Kind of like how social apps like whatsapp and facebook do. Please let me know if I need to clarify any point more.
Thank you in advance

Related

Android App Viewing Images Uploaded on Cloud Storage

I have a catalog Android App that I am building to showcase different catalogs from different local stores. The Catalogues are basically pages in Image(JPG) format. I would like each store to have its own activity that launches a catalog.
From my research, I can achieve this by creating a storage reference to a storage bucket that holds these images on google cloud storage. I have created one storage bucket that is holding about 8 images of a catalog. I am not sure how to implement this connection to my app.
What would be the best way to go about this? Should I create a tabbed activity for the images to be swiped through and if so, how is this created and referenced to the images from the android studio?
Any help or resource on this would be highly appreciated.
I have already connected the App to firebase which is working fine.
I have the activity_main.xml layout file with all stores and upon clicking on a store the idea is to launch the catalog images for that particular store.
Please help!
You can see Firebase storage quickstart which can give you an idea on how to setup your app. For displaying images, it would be easier if you use Firebase UI, here's a link to the related documentation.
EDIT:
By the way, you are in the right track of setting different references to your buckets.

How to attach a picture from android gallery into my note app?

I'm developing a simple note app, some kind of diary but I need a function where I click on the "attach" button so I could attach files from internal and external memory from the phone, the files would be pictures and maybe, if possible, video and wav files, all of them together with the text file on the note app, and I would need to save all this in a database, so I would like to know if that is possible and how do I do it , I read about sharing files from apps to apps on android developer site but I got confused, so I would like someone to help if possible, btw sorry for my bad English I'm not a native English speaker and it's my first time asking here, so I would be glad of somebody could help with this.
Hi Leonardo Medina Lango,
You do not need to save whole file in your app's folder. Save only file path to your sqlite database. If you that files in your cloud than sync sqlite database with your cloud server from background service.

how can i keep a folder in my mobile storage and a folder in my dropbox space in Sync?

i have developed a android app for farmers. it is a informative app for indian farmer.The users will be sending me the images and video files to me through my app. here i used (integrated) dropbox to receive those files directly to my dropbox space. whatever the image or video taken by the user, it will be stored on a folder in my mobile storage. Here what i want is, i want the folder in my mobile storage to be in sync with the folder in my dropbox.
How can i do this?
there is a app in market called Foldersync which exactly fulfil my requirement. how they are doing it? How can i keep a folder in my mobile storage and a folder in my dropbox to be in Sync?
Note :
i have gone through drop-box api and created a simple app to send files directly to my dropbox space and i know how to download a entire folder from dropbox.
But here my question is unique from that... pls don't answer the above points which i already know..
Please help!
Thank You
You can use the Dropbox API to keep a local client in sync with Dropbox. There are two main pieces to this:
1) Metadata:
Assuming you're using the Core API, the best way to get information about all of the file and folders in an account (or optionally under a specific path) is to use /delta:
https://www.dropbox.com/developers/core/docs#delta
With this, you can get information about everything your app can see, and then easily stay up to date with changes. There are some useful blog posts on using /delta here:
https://blogs.dropbox.com/developers/2013/12/efficiently-enumerating-dropbox-with-delta/
https://blogs.dropbox.com/developers/2013/12/filtering-dropbox-delta-results-by-path/
2) File content:
Using the metadata retrieved from #1, you can download any files you need access to locally using /files (GET):
https://www.dropbox.com/developers/core/docs#files-GET
You can upload locally changed files using /files_put:
https://www.dropbox.com/developers/core/docs#files_put
Or, for larger files, use chunked uploading:
https://www.dropbox.com/developers/core/docs#chunked-upload
https://www.dropbox.com/developers/core/docs#commit-chunked-upload
The main work here will involve programming the logic in your app to correctly receive changes from the server as well as upload local changes, in order to keep everything in sync.
Also, be aware that on mobile devices, bandwidth can be limited and/or expensive, so be careful to not accidentally automatically download a lot of data the user doesn't want or need.

Sharing Files in Android with some partners using Dropbox

this is the first time I'm taking a look at the Dropbox API so I'm afraid I kinda don't understand much.
My purpose is to develop an App in which I place some files into a directory so as to be automatically uploaded to the server and synced in another device whose owner I'm sharing them with, so different accounts are being used of course.
In the end, it has to be something similar to Dropbox app itself: you are able to create a file, upload it and share it with some friends.
Any idea if this is possible, what to begin with, is it possible to use for this goal any folder i want or it has to be one particularly chosen by Dropbox...?
If you're asking for a way to programmatically share a folder with another user, the API doesn't currently support that. To do what you're doing, you would need to manually (with the Dropbox app or via dropbox.com) share a folder with the other user. From then on, you could use the Dropbox API to read from and write to that shared folder. (And the same would work from the other account, since the folder would be visible to both of you.)

Distribute air apps without recompiling

I'm developing an air image viewing application for Windows and Android that will allow some special users to import bitmaps to it. The user can click on a button, browse to a bitmap stored locally and then the app saves the image to the documentsDirectory.
Later on, other users (let's call then common users) will get this already compiled app and view the images imported by the special users.
My question is how can I make the app save the images within it without recompiling it?
Any ideas are welcome! Thank you all!
The only option I can think of, is to make a web server to store and load the images by those users. That's because the images will be stored in the documents or cache directory of the device which means that there is no automatic way to bring them to other devices.
You need a web server that the images will be uploaded and saved, and later on retrieved by other clients. It's called centralized assets system.

Categories

Resources