Page 1 of 1

Photos in database

PostPosted: Thu Oct 09, 2014 10:17 am
by pslates
I keep a Staff database and a while back added a photo of everyone because of getting lots of new people to work with and a way for me to easily relate to a person. The problem is I bring up the database and the majority of the time it takes seconds for the photo to be displayed. I wonder what I can do to have them appear quicker. I learned how to set this up initially from a DDH person and I have

ImageDate text filed
Image External field, Photo Picker
ImageLink Link field

I wondered if the problem was the resolution of the photo. I have been reducing the resolution to 150 x 225.

I had this problem for months using an iPhone 4 and just yesterday got an iPhone 6 and still have the same problem so it must not relate to the processor of the phone.

Re: Photos in database

PostPosted: Fri Oct 10, 2014 11:13 pm
by dhaupert

Thanks for your post- should be pretty instant to show the photo. Can you provide some more detail on what the third field is? Is this for some other purpose? Are you having a slow time opening the database list view, or opening a single record? Are you using a form or the Edit Record screen when it's slow?

Re: Photos in database

PostPosted: Mon Oct 13, 2014 10:37 am
by uboche
Prompted by the posts in this thread, I started adding jpg images to two of my databases. I'm running into some problems doing this and I'm wondering if there is any documentation available that could be helpful.

With the first database I modified I'm using the Edit Record window to display records (no forms). I can see the image but is is fairly small. Tapping on it only has effect if I tap the edit button first. Then I get the Select Photo window with a larger image. Is there a way to display the image in larger size without editing the record? Also, after syncing with the Windows PC, the image is not displayed on the PC. Is there a way to get that to work?

With the second database I've added images to I'm using a form to display and edit the records (I'm using a relationship field there for xref between records). There I added a text field and an image field to the database and an image field to the form, but I can't get the image displayed.

Re: Photos in database

PostPosted: Tue Oct 14, 2014 5:50 am
by Brian_Houghton
Regarding the image display without a form, a smaller version will be shown than the original size of the photo as the app is trying to show data from several fields and does not fill up the screen with a photo preview.

The solution is to use a custom form where you can specify the dimensions of the preview to your liking.

Now, in regards to the form not displaying the image, let's make sure you have the image control parameters set up properly. Which field do you have it configured to use?

Re: Photos in database

PostPosted: Tue Oct 14, 2014 11:03 am
by uboche
Talking about "photo preview", is there a way to show the photo full size (a button, tap on the preview, or some such)?

With the form, I probably used the wrong field type. I'm seeing now that the "Picture" type creates a button with a custom picture but not a preview of a photo. Which field type do I need to use?

Re: Photos in database

PostPosted: Tue Oct 14, 2014 1:02 pm
by dhaupert

On the edit record screen, the full screen preview indeed only works when in edit mode. I suppose that could be changed in the future, but right now it's locked down that way. That said, as you and Brian discussed you can design a form and have a much larger photo included. It's a little bit confusing as to fully function you need several fields and controls. Here's an overview:

Create your text field for storing the photo filename if you haven't already.
Create your external photo field that points to the above field if you have not already.

Now on your form add a picture control. Set the data source to the text field (not the external field!) and set it to use the field value for the image source. Now you can size this to be as big as you need and see the photo for that record.

To be able to go to the full screen preview/picker aspect, you'll also need a button. Assign the button's data source to be the External field and the button action to the Follow Link/linked/external. Now this button when pressed will let you select a new image and see it full screen.

Hope this makes sense!

Re: Photos in database

PostPosted: Wed Oct 15, 2014 6:03 am
by Alanwestwood
I just have a smaller image on my first form and give it an action to open a new form which has only one field/control - a full screen view of the image. On that second form the image also has an action, which is to return to the first form (all the default buttons are removed in its properties). This way, a tap on the image in the first form simply opens a full screen view of the image, and a tap on it there returns me to the first form, which doesn't have to be in edit mode (it isn't in my case, as I have an edit button which takes me to the edit form).

So basically, my image has both a text source field and an action. Not sure if I have explained that well, but it works a treat and is instantaneous (even though I have about 600 images in my library) ;-)

Cheers, Alan.

Re: Photos in database

PostPosted: Sun Oct 19, 2014 6:42 am
by uboche
Thanks for your help, Dave. With your instructions I managed to get the image display on the form right.

Alan's tip to use a second form for a full screen view was also very helpful, this works like a charm.