Notices
Computer & Technology Related Post here for help and discussion of computing and related technology. Internet, TVs, phones, consoles, computers, tablets and any other gadgets.

Pictures into MsAccess

Thread Tools
 
Search this Thread
 
Old 11 February 2003, 10:03 AM
  #1  
bing-bonger
Scooby Regular
Thread Starter
 
bing-bonger's Avatar
 
Join Date: Nov 2001
Posts: 171
Likes: 0
Received 0 Likes on 0 Posts
Post

Guys,Gals!!!

I am creating a website using ASP and Ms Access for an on-line portfolio (over 200 images divided into 10 sub sections), what I would like to know is how do I populate a database table in Access with jpegs, and how do I get them to display within the HTML, is it the same process and displaying text from a database????

Any help would be very very much appreciated....


thanks
Old 11 February 2003, 12:44 PM
  #2  
ids
Scooby Regular
 
ids's Avatar
 
Join Date: May 1999
Posts: 424
Likes: 0
Received 0 Likes on 0 Posts
Post

Heheheheh..... been there too.

2 options - either convert/encode the image and then store in a MEMO feild - however there is some limitations on this in Access or better still store the image within the file system and store the link/url for display.

I do have some more info on Option 1 but not to hand....

Ids
Old 11 February 2003, 12:59 PM
  #3  
chiark
Scooby Regular
 
chiark's Avatar
 
Join Date: Jun 2000
Posts: 13,735
Likes: 0
Received 0 Likes on 0 Posts
Post

Store 'em in a memo field, then retrieve using ASP.

Your img src will look strange, as you'll call an asp page to retrieve them (such as <IMG SRC=image.asp?name=test.jpg> ) but on the other hand it'll work.

Your asp wants to set its response type:
Response.Buffer = TRUE
Response.ContentType = "image/jpeg"

You then want to find your image in your recordset that you've opened (assume you know how to do this).

Write your image out using
response.binaryWrite myRS("Image").GetChunk(myRS("Image").ActualSize

Where myRS is your Recordset object, "image" is the field name containing the image.

Finally, end the response with
response.end

Doing this means that you can also control access to your graphics, such as to ensure people are logged on before seeing the graphics, and also that no other site is leeching graphics off your server.

Cheers,

Nick.
Old 11 February 2003, 03:55 PM
  #4  
bing-bonger
Scooby Regular
Thread Starter
 
bing-bonger's Avatar
 
Join Date: Nov 2001
Posts: 171
Likes: 0
Received 0 Likes on 0 Posts
Post

Or maybe i should just you sql-server as that has an option for image???


What do you guys think??
Related Topics
Thread
Thread Starter
Forum
Replies
Last Post
Mattybr5@MB Developments
Full Cars Breaking For Spares
12
18 November 2015 07:03 AM
Wish
Computer & Technology Related
3
30 September 2015 10:39 PM
Phil3822
General Technical
0
30 September 2015 06:29 PM
IanG1983
Subaru Parts
1
30 September 2015 04:52 PM
floydy634
General Technical
3
27 September 2015 07:25 PM



Quick Reply: Pictures into MsAccess



All times are GMT +1. The time now is 09:59 AM.