Wrox Programmer Forums
|
Access Discussion of Microsoft Access database design and programming. See also the forums for Access ASP and Access VBA.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old May 26th, 2006, 10:33 AM
Authorized User
 
Join Date: May 2006
Posts: 31
Thanks: 0
Thanked 0 Times in 0 Posts
Default Button that opens an image

Hello!

(sory for my english)

I'm trying to a create a button in a form that gets the photo of an user in the table.

How could I do that?

Thanks.

 
Old May 28th, 2006, 05:29 AM
Authorized User
 
Join Date: May 2006
Posts: 47
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Ashfaque
Default

1. Place the image frame onto the form. Give the path when ask for picture to display. (Let us say image frame name is "Image4"

2. Remove the picture source of the Image from its property. You might need to save the form.

3. Place a command button on the form without any default code.

4. Write following code in OnClick event of the command button.

Me.Image4.Picture = "Show here complete name and path of the Picture"

Like :

Me.Image4.Picture = "C:\Documents and Settings\ashfaque\My Documents\My Projects\RUNINGPRO\PicDemo\crs.jpg"

5. Re-size the frame as per need. Save and run.


Do not place direct picture on any form or report that would increase the size of database.

HTH

Ashfaque

 
Old May 29th, 2006, 04:36 AM
Authorized User
 
Join Date: May 2006
Posts: 31
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hello!

Very nice!!

Only one thing missing: is there a way to get the picture from a table (path)? Like, if I change the 'user' I'd get the respective picture.

Thanks a lot!!!

 
Old May 29th, 2006, 08:58 AM
Authorized User
 
Join Date: May 2006
Posts: 47
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Ashfaque
Default

Yes....

But then you need to write some codes line.

I will look tomorrow and let you know.

Ashfaque

 
Old May 31st, 2006, 06:21 AM
Authorized User
 
Join Date: May 2006
Posts: 47
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Ashfaque
Default

comicghozt,

Give me you email id. I will send you a sample I have.I am sure it will give you an idea. Just change the name of JPG pictures with your into the table column # 3. Play with code behind the form.

Please note that to get the picture of current user, you will need to put pictures of all the user in a folder at a certain accessable place or with each terminal. Because we dont know a user will log on from which terminal.


With kind regards,
Ashfaque


 
Old June 1st, 2006, 02:58 AM
Authorized User
 
Join Date: May 2006
Posts: 31
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hail!

Thanks a lot...

Here's my e-mail: c_serafim@yahoo.com

This will be a great help!

 
Old June 3rd, 2006, 02:29 AM
Authorized User
 
Join Date: May 2006
Posts: 47
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to Ashfaque
Default

I have sent the file to you.

Hope it will help you to have an idea.

Regards,
Ashfaque






Similar Threads
Thread Thread Starter Forum Replies Last Post
button click in modaldialog opens another browser sasidhar79 ASP.NET 2.0 Basics 9 January 24th, 2008 03:59 AM
Make a image button as default submit button toshi ASP.NET 1.0 and 1.1 Basics 1 June 1st, 2006 05:25 AM
image as button hosefo81 HTML Code Clinic 2 February 11th, 2004 03:55 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.