473,473 Members | 1,965 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Help w/ coding tips. BLOB images being displayed

This is the error I get when I try to open my asp page. When I try to
open the HTML page that uses the ASP page as a source for my image I
get a box for an image but it has the icon for a broken image.

Technical Information (for support personnel)
· Error Type:
Server object, ASP 0177 (0x800401F3)
Invalid class string
/ben/bam3.asp, line 11
· Browser Type:
Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR
1.1.4322)
· Page:
GET /ben/bam3.asp
· Time:
Tuesday, December 19, 2006, 11:12:49 AM
· More information:
Microsoft Support

++++++++++++++++++++++++++++++++++++++++++++++++++ +++++++++++++
Below is my code. I modified some code I found at 4guysfromrolla.com
I am trying to use an ASP page to grab a binary image from a database.

My Table is called A_870211EE_7122_4AB3_B513_96B2AA58447A
The Column within the table where the images are stored is AF_Photo_1
The column where I define which employee gets their picture shown is
AF_Employee_Number
++++++++++++++++++++++++++++++++++++++++++++++++++ +++++++++++++
<html>
<head>
<title>Displaying Pic from DB</title>
</head>
<body bgcolor="white" text="black">
<%
Dim iAF_Employee_Number

iAF_Employee_Number = Request.QueryString("AF_Employee_Number")

Dim objConn, objRS, strSQL
strSQL = "SELECT AF_Photo_1 FROM
A_870211EE_7122_4AB3_B513_96B2AA58447A WHERE AF_Employee_Number = " &
iAF_Employee_Number

Set objConn = Server.CreateObject("ODBC.Connection")

objConn.Open "DSN=AsureIDc51Test", "xx", "xxxxx" ß username and
password removed for security

Set objRS = Server.CreateObject("ODBC.Recordset")

objRS.Open strSQL, objConn

Response.ContentType = "image/jpeg"

Response.BinaryWrite objRS("AF_Photo_1")
%>
</body>
</html>

++++++++++++++++++++++++++++++++++++++++++++++++++ ++++++++++++++++++++++++++
This is the code for my HTML page calling to get an employee's photo
based on their id.
++++++++++++++++++++++++++++++++++++++++++++++++++ ++++++++++++++++++++++++++
<html>

<head>
<meta http-equiv="Content-Type" content="text/html;
charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>New Page 1</title>
</head>

<body>
<img src="bam3.asp?AF_Employee_Number=301867">
</body>

</html>

Dec 20 '06 #1
0 964

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: John | last post by:
I have over 5000 thumbnail pictures of size 5kb each. I would like to able to load all 5000 pictures and view 50 per page using mysql_data_seek(). I would like to know what are the advantages and...
1
by: nzanella | last post by:
Hello, I am currently upgrading a database of products to include pictures to be displayed online. I would like to know whether it would be best to store the pictures themselves in a database as...
8
by: baustin75 | last post by:
Posted: Mon Oct 03, 2005 1:41 pm Post subject: cannot mail() in ie only when debugging in php designer 2005 -------------------------------------------------------------------------------- ...
0
by: Big George | last post by:
I'm developing with ASP.NET, VS.NET 2003. Using Crystal Report for VS.NET DataBase: Oracle 10g I store a BLOB field in a table. This field store images, like jpg files. The Stored Procedure...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.