473,403 Members | 2,354 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,403 software developers and data experts.

Need Help Displaying Image on a Form

25
Hi Everyone!
I am creating an employee database and would like to include a picture on a form of each employee. I have a text field in my employee table named "Image" that contains the path to an external JPG. My form contains an image box with picture type set to embedded named "Image18". The form is based on the employee table and I have the "Image" field on the form named "txtImage".
Here is my code in the "OnOpen" event precedure for the form:

Expand|Select|Wrap|Line Numbers
  1. Me![Image18].Picture = Me![txtImage]
I get a "type mismatch" error when I try to view the form.
Can someone help?

Thanks in advance!
Jan 26 '07 #1
5 1478
teric2
25
Ok, I solved my own problem.

The only reason it wasn't working was because the image field in my emplopyee table in my first record was blank. As soon as I entered data into the field it worked.

Thanks anyway and sorry to take up your time and bandwidth.
Jan 27 '07 #2
MMcCarthy
14,534 Expert Mod 8TB
Ok, I solved my own problem.

The only reason it wasn't working was because the image field in my emplopyee table in my first record was blank. As soon as I entered data into the field it worked.

Thanks anyway and sorry to take up your time and bandwidth.
Probably best to have a default image stored for any employee who doesn't have a photo yet.

Glad you got your problem solved.

Mary
Jan 27 '07 #3
NeoPa
32,556 Expert Mod 16PB
Answers provided by the OP (Original Poster) are actually the best result we can hope for. It means that you're learning and developing (That's pretty well what the site's all about).
In this case it also gives us the opportunity to suggest new ideas too (See Mary's post -- a very good idea btw).
Lastly, we do appreciate that you've posted that you have a solution. This makes the thread even more useful, as other members, and even the general public, can benefit from your experience :)
Jan 27 '07 #4
teric2
25
Thank you Mary and Neo!

Thank you Mary for the suggestion. I am going to do exactly that. I have planned to use an image with nothing but something like "No Image Available" in it that will show when there is no employee photo.

Thanks again for the comments!
Jan 29 '07 #5
MMcCarthy
14,534 Expert Mod 8TB
Thank you Mary and Neo!

Thank you Mary for the suggestion. I am going to do exactly that. I have planned to use an image with nothing but something like "No Image Available" in it that will show when there is no employee photo.

Thanks again for the comments!
Your welcome!
Jan 29 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

9
by: matthiasjanes | last post by:
Hi, Maybe someone of you can help me. I'm trying to display an image in memory(open file) with an cgi script - but it want work proberly: I'm running an Cgi webserver (CgiServerGui.py). ...
3
by: B Maxey | last post by:
I am storing images in a database and need a way to browse those files. I can load the files into an image list or whatever the control needs, but I need a control. It doesn't seem that any of...
4
by: redpears007 | last post by:
Hi Again, Throwing this one out to you again as i am not getting anywhere and can find little to no information out there. I am currently displaying images (Jpegs) in access via the routine...
21
by: BASSPU03 | last post by:
(Using Access 2003 on Windows XP.) I'm using the following code from http://www.databasedev.co.uk/image-form.html to display an image using an image control in my main form (frmVetted). This code...
7
by: Dave | last post by:
Hello All, These one may be a bit tricky, and what I'd like to do may not even be possible. I would love to hear any ideas you guys have for solving this. Here is the situation: I have a form...
14
by: ashraf02 | last post by:
i used a code from a website that allows you to display images. however everything works fine from storing the image to the database but it does not display the image. the following code is the...
7
by: hsegoy1979 | last post by:
Dear All Iam using file upload control and i want to display image in another pop up page .But image is not displaying in image control iam sending image path thru querystring . here is my code ...
0
by: readnlearn | last post by:
hai, i have written this below code for displaying captcha image whenever i entered incorrect uname,password in login page. for that i disable the controls of captcha like textbox,labels,button and...
0
by: asifu9 | last post by:
Hello all, I am new to MS Access VBA 2007, i need help on how to open a chart form in switchboard. SwitchBoard having options to open a form in Add mode and edit mode, in both of...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.