PDA

View Full Version : Desperate for help on MS Access



Ossian
2008-07-21, 10:02 AM
HI fellow playgrounders,

1st thing off, missed you all. Good to be back online.

Now, to the point: I am trying to force MS Access to my will, but I just won't succeed. I searched every possible tutorial on the internet but they all assume I am a code genius and shower me with [kvlvjdögeorhgoek], #, < > and what have you. I don't know code. Not a string of it. What I need to do is quite simple, actually. It is even in the examples provided by the MS tutorial (when you hit F1). I just need to have a table which has (among other values and entries) a picture of 1 or more logos.

It is a bit like that. Every entry should look like:

NAME OF COMPANY - COUNTRY - CONTACT PERSON - email - LOGO (or LOGOS) of the SPONSOR

Example:
Doodler Inc. - Madagascar - John Smith - js@whathaveyou - LOGO of the United Nations, Logo of USAID.

WHY is that so complicated? I got all of it but not the picuters. I tried to enter the OLE thing in the Design table, and then when I go to compile the actual form, or the report, NOTHING shows. The toolbox with the "insert image" toolbar is always greyed out. I am completely lost and that is making my mouth foam with rage.

If I go to the datasheet view, the columns where all the picture should be (and mind you, I only managed to have 1 picture per row) say "package" (????????) and only if I double click on the word package the image appears (but in the "picture and fax viewer").
:smallfrown::smallfrown::smallfrown:

Please, could you explain it to me as if you were talking to a complete idiot?

THNX guys

Ossian

PS
Here is a page that looks a bit like what I want to appear when I generate a report.

Tormsskull
2008-07-21, 10:30 AM
Hey,

Ok, I think I know what you are trying to do. Here is an image first, then read explanation below:


http://i124.photobucket.com/albums/p15/Tormsskull/Pictures%20to%20Share/AccessLogos.jpg


Ok, first, I am not sure if you are using Access 2000, 2002, 2003, 2007, or what. I created the above in Access 2000. The principle should be the same in all, but the step by step would probably be different.

The first screenshot in the above spoiler is a same database in design view. Notice that the field name "Logo of sponsor" is Data type OLE Object.

The second is the same table in Datasheet view. In order to insert the logos, you click on the field where they will be put into, then you click Insert off of the file menu, select Object, and then insert the image you want as your logo.

Once you have done that, if you create a form based on the table, the images will show and you can move then around as you like and such. You could also make a report to list every person in the DB w/logos of sponsor.

Does this answer your question?

Ashtar
2008-07-21, 10:35 AM
Also, if you have more than one logo per entry, it would be best to store them in an external table and link them to the entry.

[TableEntry].PrimaryKey 1---N [TableLogo].ForeignKey

Otherwise, don't bother and add Logo1, Logo2, Logo3 fields in the Entry and simply "limit" people to 3 logos. Might be simpler for you...

Ossian
2008-07-21, 10:59 AM
Also, if you have more than one logo per entry, it would be best to store them in an external table and link them to the entry.

[TableEntry].PrimaryKey 1---N [TableLogo].ForeignKey

Otherwise, don't bother and add Logo1, Logo2, Logo3 fields in the Entry and simply "limit" people to 3 logos. Might be simpler for you...

Guy (both of you) you are great! Still, I am more challenged than you can imagine.

I am on Access 2003 and the only way to have the "bitmap image" thing appear in the datasheet is to creat a new one, which directs me to MS pain (I might paste in a image from somewhere, maybe). Tat image (imagine I scribble casually with the pencil) actually apopears in the report.

Ashtar, as soon as I read your post my nose exploded as well as 1d4 of my limbs. Could you break it down a little bit more? Like, step by step from "double click on the MS access icon on your desktop"?

Oh, heck, I have to go. I will check again in a couple of hours. Dude, this is really shattering my ego....

Tormsskull
2008-07-21, 11:20 AM
I am on Access 2003 and the only way to have the "bitmap image" thing appear in the datasheet is to creat a new one, which directs me to MS pain (I might paste in a image from somewhere, maybe). Tat image (imagine I scribble casually with the pencil) actually apopears in the report.


Really? When I click in the field, then click Insert, then Object, I get this pop-up


http://i124.photobucket.com/albums/p15/Tormsskull/Pictures%20to%20Share/AccessLogoPrompt.jpg


If you have such a pop-up prompt, you would simply click Create from File, then select the logo you are looking for.

Either way, good luck!

Dallas-Dakota
2008-07-21, 12:43 PM
It may be because his entire ´my pictures´ file is empty.(It may be phrased differently by your version of Windows, linux or what you´re using)
Trying moving the logo´s to that file.

I´m no expert, but maybe that could help.

We´re all noobs on some fields. We all have our expertises.

Except for me....I´m a jack of all trades or something. Except for me beinga expert on the cookie field.....*eats*

Ossian
2008-07-22, 04:17 AM
OK, the desperation sort of abated, but only slightly.
The "My pictures" pool is full of samples (all formats, from gifs to jpg through bmps). It looked like the trick was to submit a "BMP" image alone.
After having done that, the picture (in whatever report layout I choose) do appear.

The real goal is another though. We want the database to be accessible online, but only for consultation and by NON-experts. In fact, total noobs with slow connections.

So, the idea we came up with was to upload an "html" export from the report. It will have the same information, but appear to the guy who checks our website just like another page.

So, here we get stuck, horribly.

(http://img183.imageshack.us/my.php?image=testbp4.jpg)

As you can see, there is no such thing as an image, and where it says "logo" there is nothing but empty space

On the other hand, on my PC, when I issue a report, it looks like this:
[IMG]http://img165.imageshack.us/img165/7548/reportjm3.th.jpg (http://img165.imageshack.us/my.php?image=reportjm3.jpg)


So, any clues as to why the BMPs get lost when we transtition from report to html?

Cheers,

O.

Ashtar
2008-07-22, 06:41 AM
So two things:

First, on the generated web page, the image file is probably not written with the report to the correct location. Have a look at the source of the HTML code to see if there is a <IMG> tag, and if so, where is it pointing (that's the src="" part). You would have to copy all the images used in the DB to that location. -- Edit: access does not export Images with reports.

Secondly, for the multiple image logo files... I'll try to explain... *Fires up Access*

I'll do another post when I'm done.

--

Edit: Okay, so I did an export of my Report, visibly OLE links are not exported to HTML reports. I'll have to google it up, but at least in my example, Access didn't do it.

I've done an example of a DB with a input form and a report so you can see.
DISCLAIMER: This is not a completely correct (In the sense of the Fourth Normal form and multivalued dependencies - but it works) DB example, but it will function within specifications. Under the current implementation, a Logo used for two companies has to be entered twice.

I'll post a link as soon as I upload the DB somewhere for you to see.

Linkie to the DB: http://rapidshare.de/files/40054014/Ossian.zip.html
Hopefully you'll be able to D/L it there after clicking on the "FREE". This file was made with ACCESS 2003.

--

There is a Companies table which contains company information and a primary Key, there is a Log table which has a primary key (unused), an external Key pointing to the companies table and the OLE object.

You will find an input Form, that was made by the wizard in which you can enter (hopefully, I haven't even tested it) the data and a report form (again made with the wizard) where you will see company information associated with the logo(s) you added. As many logos as necessary will be shown.

I hope this will be enough for you. I'll just google up the report issue with exported images...

--

Edit: After checking, Access never exports OLE objects with exported reports, this has to be done either with a VBA routine or an external module. It would be possible to write the VBA for you if you really need it. I just need to get back to work now.
Keep us up to date if you need more help.