Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Displaying Image Error

Status
Not open for further replies.

humbletechie

IS-IT--Management
May 3, 2001
33
0
0
US
Hi,

I am trying to display an image based off the value that is stored in a database field. I put the following code in the Forms On Current event and I have the forms data source set to the proper table.

Dim Path
Path = CStr(Me![ImagePath])
Me!Image7.Picture = Path

ImagePath is a text box in the form that holds the image path that's in the database.

Whe I run the form I get the following error:

Run-time errro '2220'

Microsoft Access can't open the file '#\\server\images\bmp\image1.bmp#'

If I hard code the image path into Me!Image7.Picture, it works fine. Does this have something to do with # writing out in front of the path? If so does anyone know how I can make it write out without the #'s?

Thanks!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top