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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Access & Bound Images 3

Status
Not open for further replies.

Beiber39

Vendor
Apr 8, 2004
8
GB
Hi,

I am an IT professional using Access for a hobby requirement (Roman Coin Collectors Database) and have a few questions.

1)... Can you use .jpg images instead of .bmp on the forms? If so how?

2)... I have created a working table and form but have one last problem with images of the coins. When I insert the images into the OLE field it only displays a small picture with the file name text underneath it. To view it you click on it and it opens up a full view ontop of the form, when you cancel the image it reverts to the form view.

I want the image to just fill the field without opening up the application, just like a standard web page or word document. As I open the record I want to see the front and reverse images of the coins without clicking on them and using another application.

Any help would be appreciated.

Thanks

Beiber39

Peter Rhodes

 
1)... Can you use .jpg images instead of .bmp on the forms? If so how?

My fave is to embed a webrowser control (activeX) into the form, then load any type of image into it, based on a recordset.

Another way is to use an image control, set the picutre type to be linked, then the picture location from there. Can be done through code if necessary (not sure of your VBA ability level, hence the glossing over for the time being)

2)... I have created a working table and form but have one last problem with images of the coins. When I insert the images into the OLE field it only displays a small picture with the file name text underneath it. To view it you click on it and it opens up a full view ontop of the form, when you cancel the image it reverts to the form view.

I want the image to just fill the field without opening up the application, just like a standard web page or word document. As I open the record I want to see the front and reverse images of the coins without clicking on them and using another application.

Again IMO, if you created a form, with a could of web browser controls, you can get this functionality pretty easily.

If you like the idea, and need some help with getting this up and running, please let me know and I will try and help :D
 
Thanks for the response, my VBA is none existant.

On the web link, I assume you store the image and link to it. Can this be activated automatically?

Don't know how to use active X either, I am just playing with Access, not my work, hence the ignorance.

The rest looks and works really well

Thanks, look forward to your comments.

Regards
 
Ok, it would take a book perhaps for me to explain this to you.. not cus I doubt your learning ability, but Im crap at explaining things :D

So.. if you want me to email you a sample db with the above in it, I can do so.

Si

------------------------
Hit any User to continue
 
How are ya Beiber39 . . . . .

This reply in on the premise your talking a [blue]Bound OLE Field[/blue] (in form design view, properties titlebar saids [blue]Bound Object Frame[/blue].

1st . . . Yes you can use *.jpg

It appears you have the [blue]Display Type[/blue] property set to [blue]Icon[/blue]. You need to change it to [blue]Content[/blue]. But before you do, follow the steps below:

1) Open the form and delete all the images. Your gonna put them back in the last step. The deletion is necessary as changing [blue]Display Type[/blue] won't take unless the OLE fields are empty.

2) Put all your coin graphics is a seperate folder. I believe you already have.

3) Open the form in design view and set the [blue]OLE Type Allowed[/blue] property to [purple]Linked or Embedded[/purple]. If you have alot of coin graphics I would set the property to Linked. Embedded stores the graphics in the DB and can really blow it up, impacting performance. Either way its your choice.

4) Set the [blue]Display Type[/blue] property to [purple]Content[/purple].

5) Save the form. Open the form and Reinsert your graphics.

6) If the graphics are not fitting properly, play with the [blue]Size Mode[/blue] property.

cal.gif
See Ya! . . . . . .
 
Beiber39 . . .

By the way . . . When you reinsert your graphics, right-click the field, select [blue]Insert Object[/blue], make sure [blue]Create From File[/blue] is selected, browse and get the coin graphic file, click OK.

[purple]Do Not Paste Into The Field![/purple]

cal.gif
See Ya! . . . . . .
 
Thanks guys, great info.

I do use the insert objevt and select from file, it just comes up with the small icon and the file name underneath.

I will follow the advice and come back to you all.

Thanks

 
Hi ACEMAN1

tried to follow all your instructions, all was clear and seemed to go OK but the result is exactly the same.

Any other ideas any else ? or ACEMAN1

Still getting the very small image with the file man under neath and you have to select the icon (NO - icon is NOT set in tyhe properties) to open up the image in a viewer.

Thanks
 
Beiber39 . . . .

Yes, everything should have been OK. Your last post indicates its the graphics. I don't know the source, but in enough graphic applications they'll attach a hidden header that does this. It has to be turned off in options somewhere.

For instance in Encharta does this. You can get the Icon with name, with Encarta signature, or clean.

Check the application you used to store the coin graphics.

Let me know. . . . . .

cal.gif
See Ya! . . . . . .
 
Beiber39 . . .

Oh yeah . . . . insert some other graphics from your system just as a test to see it is working right. Do a .bmp & ,jpg!

cal.gif
See Ya! . . . . . .
 
Hi,

will do, I have Photoshop & & I also use a digital camera utility called Cammedia, I may have used it on the images as it down loads from the cammera.

I will down load the images and use in photoshop, I will also download a couple of images from the webb and see what happens.

I will try to use a number of applications and report back.

Thanks again guys.

 
Hi guys,

a long time since I posted - progress todate.

I have tried different images and edited files for bitmaps without success, I still get the small icon with the file name under it.

HOWEVER !!

I have 2 computers, 1 is a portable, both have Windows XP and Office XP. On the portable all works fine, I can load in a bitmap image and it displays fine, the desktop will not show the image correctly. I have compared properties between both PCs' and they are the same. If I load a good working image from the portable onto the desktop it is still not displaying right.

The only variation I can see is that when I go to the tables and look at the cell information on the portable (works fine) it says bitmap image.

On the desktop PC (won't display the image correctly) it says "package" and I cannot get it to change. This looks like the OLE cell is set to package??? If it displayed bitmap I assume it would work OK.

Not sure what this means but hope someone can give me some help

Thanks

 
How are Beiber39 . . . . Your Alive!
Beiber39 said:
[blue]On the desktop PC (won't display the image correctly) it says "[purple]package[/purple]"[/blue]
According to your quote above your desktop is installing graphics thru an old well known program called [blue] Object Packager (Packager.exe)[/blue], and your laptop is not. I had no Idea this program carried thru to XP or any equivalent thereof!

I'm not quite sure where to go from here, but something seems to have enabled Packager on the DeskTop and not the LapTop.

Try looking in the database options for anything to do with OLE or Packaging . . . . .

cal.gif
See Ya! . . . . . .
 
Just idle curiousity: how many images do you have in mind to use. And is there a particular reason not to use an unbound image control and just set the path to the image as needed.

Using a few 14kb bound images is one thing, but 500 5mb images will bring your application to a catatonic state.

Also, have you looked at the Kodak image control that comes with the ActiveX controls. Its properties seem a bit more exposed.

Cheers,
Bill
 
Hi,

there will be about 100 coins (maybe more with time), a jpeg image that fits into the window is about 35k, pretty small, bitmap seems about 400k.

Not sure what the unbound image option is, I assume you have a link from the record to the image stored on the PC, similar to an html link?

Happy to do anything that will work, its a shame as the layout of the record is really nice a fully meets my needs, its just the image display problem that is spoiling it.

Thanks again folks, everyones been really helpful.
 
Beiber39 . . . . . New Development!

TheAceMan1 said:
[blue]If the [purple]Application Association[/purple] for a graphics file is missing or not working properly, the insertion of the graphic in Access [purple]defaults to the Object Packager![/purple][/blue]
To test the validity of this, open windows explorer and open a .bmp or .jpg. If an application opens up and loads the file (you can see the graphic), then you do not have this problem. If it does, you'll have to associate the file type with an graphics application.

Maybe! . . . . Just Maybe! . . . . .

cal.gif
See Ya! . . . . . .
 
Hi Aceman,

dont know if this means anything

The portable which is fine with images loads Paint to view the images through Explorer.

The desktop which does not load correctly loads MS Fax & Image viewer.

This mean anything?????
 
I face the same problem as you. So far I could not find any solution. The only way to get aroundit, is to save your images in .bmp format. Then you will be able to embed the picture into your OLE Object Field.
Not the best solution as the .bmp files are bigger in size but at least I could make it work.
 
Beiber39, yes I'd say (chiming in) that Access isn't "talking nicely" with Fax & Image Viewer -- and then I'd check it out to see if I'm right or wrong ;> . So here's the next step to take.

Read Microsoft Knowledgebase article - 307859 - "How to change file associations in Windows XP" at . Then change your file associations on the desktop machine, so that it, too, uses Paint for the files in question. (This does assume that Paint was installed on your desktop, along with the operating system. If Paint was not installed, then install it from the Windows XP CD, which I hope you have, even if your desktop PC was purchased with Windows pre-installed.)

Then try looking in your database again. Good Luck.

* * *
[I've done a middling bit of work in Access 97 with bound OLE fields, with both linked and embedded objects, over the past few years. And I have also found instances where certain files "work well" only on some PCs, or for some user's Windows accounts, or other varying circumstances. In fact, we stopped trying to use Windows Metafiles in our database [at a point very early on], because we couldn't figure out how to get them to work and display consistently across all machines here. In fact, for a while, we stored many picture files in Word and Excel files, and stored those in turn in the database -- because Access seemed to communicate better with Word and Excel, which were displaying metafiles and other pictures just fine. (Anyway, it worked.) With current accumulation of experience, I *might* be able to figure out the old problem if it were worth it nowadays, but the point is, I understand where you're coming from. Sharing The Pain Dept.: My latest mystery is trying to figure out why a Bound OLE object set so that files can only be embedded -- not linked -- is behaving as if embedded files were linked. I discovered -- eventually -- that if the original files are moved or a user does not have appropriate permissions for the windows directory in which the original file is stored, they can not open/activate the *embedded* file in the database. The files in question in this case are videos in different formats, and I thought it must be application and configuration issues for a good while. But it turns out that the problems arise when a user can't get access to the original source files for *embedded* OLE objects. I still don't know why; when very basic functionality behaves in precisely the opposite manner of that described, what can you conclude? ... But I'm searching for answers, and will eventually ask around in the forums if I don't find the answer.]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top