PC Review


Reply
Thread Tools Rate Thread

Access can't open the file "image.jpg"????

 
 
Chris K
Guest
Posts: n/a
 
      12th Aug 2010
I have linked an image as background to some reports - because I am
developing the database on different machines and the image is always in the
same folder I have removed the path to the image - so it just read
"image.jpg" - I've done this before extensively but for some reason I
occasionally get an error

Access can't open the file "image.jpg"????

 
Reply With Quote
 
 
 
 
John Spencer
Guest
Posts: n/a
 
      13th Aug 2010
Without a specific path Access won't know where the file is. I think it will
try a default of the last directory accessed in Windows Explorer. The prior
statement is just a wild guess as I really don't know for sure that is what is
happening.

John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County

Chris K wrote:
> I have linked an image as background to some reports - because I am
> developing the database on different machines and the image is always in
> the same folder I have removed the path to the image - so it just read
> "image.jpg" - I've done this before extensively but for some reason I
> occasionally get an error
>
> Access can't open the file "image.jpg"????

 
Reply With Quote
 
Chris K
Guest
Posts: n/a
 
      18th Aug 2010
Like I say - have used this methods lots times - including a database I
still have with me right now and the reports work fine in that

I'm not sure how developers get on with Access spending so much time
reconnecting report backgrounds, mail merges, and tables every time the
database moves location

I think I'll have to put the path in using code but seems overkill

"John Spencer" <(E-Mail Removed)> wrote in message
news:i43iuv$t2l$(E-Mail Removed)...
> Without a specific path Access won't know where the file is. I think it
> will try a default of the last directory accessed in Windows Explorer.
> The prior statement is just a wild guess as I really don't know for sure
> that is what is happening.
>
> John Spencer
> Access MVP 2002-2005, 2007-2010
> The Hilltop Institute
> University of Maryland Baltimore County
>
> Chris K wrote:
>> I have linked an image as background to some reports - because I am
>> developing the database on different machines and the image is always in
>> the same folder I have removed the path to the image - so it just read
>> "image.jpg" - I've done this before extensively but for some reason I
>> occasionally get an error
>>
>> Access can't open the file "image.jpg"????


 
Reply With Quote
 
Rob Parker
Guest
Posts: n/a
 
      19th Aug 2010
Hi Chris,

You could try using ".\image.jpg" as the full image path/filename. . is the
shorthand form for the current directory. This works in a quick test - I
just have to ignore the error when I actually enter it in the Picture
property of the image control.

Or you could prepend CurrentProject.Path to the image name to get around the
potential problem of hard-coding a path; you'd have to do this in code,
since it won't work as an entry in the Picture property of an image control.

HTH,

Rob


Chris K wrote:
> Like I say - have used this methods lots times - including a database
> I still have with me right now and the reports work fine in that
>
> I'm not sure how developers get on with Access spending so much time
> reconnecting report backgrounds, mail merges, and tables every time
> the database moves location
>
> I think I'll have to put the path in using code but seems overkill
>
> "John Spencer" <(E-Mail Removed)> wrote in message
> news:i43iuv$t2l$(E-Mail Removed)...
>> Without a specific path Access won't know where the file is. I
>> think it will try a default of the last directory accessed in
>> Windows Explorer. The prior statement is just a wild guess as I
>> really don't know for sure that is what is happening.
>>
>> John Spencer
>> Access MVP 2002-2005, 2007-2010
>> The Hilltop Institute
>> University of Maryland Baltimore County
>>
>> Chris K wrote:
>>> I have linked an image as background to some reports - because I am
>>> developing the database on different machines and the image is
>>> always in the same folder I have removed the path to the image - so
>>> it just read "image.jpg" - I've done this before extensively but
>>> for some reason I occasionally get an error
>>>
>>> Access can't open the file "image.jpg"????



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
vista setup: "failed to open windows image file" =?Utf-8?B?Sm9obiBTdWRkcw==?= Windows Vista Installation 0 21st Jun 2006 04:53 AM
"Installation Could Not Open Windows Image file" Error Jake Henderson Windows Vista Installation 7 15th Jun 2006 11:17 PM
"Setup failed to open the windows image file" - Many Many attempts =?Utf-8?B?TWlrZSBpbiBQYXJhZGlzZQ==?= Windows Vista Installation 5 12th Jun 2006 03:10 PM
"Setup failed to open the windows image file" =?Utf-8?B?UiBvX08gayBZ?= Windows Vista Installation 1 11th Jun 2006 06:53 AM
"Installation Could Not Open Windows Image file" =?Utf-8?B?Z2xlbm4ucGhw?= Windows Vista Installation 3 10th Jun 2006 02:37 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:10 PM.