D
doyle60
I have a subform with styles (which can have one or more colors) in it
and a field for a photograph for each Style/Color record.
When the user puts his curser on the style or when the record has got
the focus, an image box on the main form shows the photograph of the
style/color. The photos are linked and the event that runs when the
record has the focus is this:
Forms!SelfPrintNewfrm!Photo.Picture = PhotoPathStyle
An example of the text in the field "PhotoPathStyle" would be this:
\\Saint\GroupPhotos\91460SEBlack.jpg
Now all works well.
But when there is NOctual file named "91460SEBlack" in the
"GroupPhotos" folder, I get an error:
Run-time error 2220':
Microsoft Access can't open the file: '\\Saint\GroupPhotos
\91460SEBlack.jpg'.
How can I get rid of this error? When the error occurs what I would
like to happen is for the words "No Photo Available" to appear instead
of a photograph. I can create an actual photograph with the words "No
Photo Available" too. (I solved this problem by having photographs
registered in a table and if they were not on the table, the query
would automatically show the "NO Photo" photograph. But I want to
know if there is a way around this without adding this registration
process.)
By photograph I mean any jpeg, which could be an illustration, but the
files are always jpegs.
Thanks in advance,
Matt
and a field for a photograph for each Style/Color record.
When the user puts his curser on the style or when the record has got
the focus, an image box on the main form shows the photograph of the
style/color. The photos are linked and the event that runs when the
record has the focus is this:
Forms!SelfPrintNewfrm!Photo.Picture = PhotoPathStyle
An example of the text in the field "PhotoPathStyle" would be this:
\\Saint\GroupPhotos\91460SEBlack.jpg
Now all works well.
But when there is NOctual file named "91460SEBlack" in the
"GroupPhotos" folder, I get an error:
Run-time error 2220':
Microsoft Access can't open the file: '\\Saint\GroupPhotos
\91460SEBlack.jpg'.
How can I get rid of this error? When the error occurs what I would
like to happen is for the words "No Photo Available" to appear instead
of a photograph. I can create an actual photograph with the words "No
Photo Available" too. (I solved this problem by having photographs
registered in a table and if they were not on the table, the query
would automatically show the "NO Photo" photograph. But I want to
know if there is a way around this without adding this registration
process.)
By photograph I mean any jpeg, which could be an illustration, but the
files are always jpegs.
Thanks in advance,
Matt