navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

Microsoft MVP

 

THis cant be happening.....

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> ASP and Database >> THis cant be happening.....
Page: [1]
 
51

 

Posts: 49
Joined: 5/30/2002
From:
Status: offline

 
THis cant be happening..... - 10/9/2003 16:06:59   
Anyone please help, this has got to something minor to repair, I keep getting this error (error '80020009' ) when I run this small .asp code.

<HTML>
<BODY>

<%
Set Upload = Server.CreateObject("Persits.Upload")

' Capture files
Upload.Save "c:\upload"

' Obtain file object
Set File = Upload.Files("THEFILE")

If Not File Is Nothing Then
' Build ODBC connection string
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.Open "aspupload", , ""
Set rs = Server.CreateObject("ADODB.Recordset")
' rs.Open sql, conn, 3, 3

' Connect = "Driver={Microsoft Access Driver (*.mdb)};DBQ=" & Server.MapPath(".\aspupload.mdb")

' If you use SQL Server, the connecton string must look something like this:
' Connect = "Driver=SQL Server;Server=MYSRV;Database=master;UID=sa;PWD=xxx"

' Build SQL INSERT statement
SQL = "INSERT INTO MYIMAGES(image_blob, filename, description, filesize) VALUES(?, '"
SQL = SQL & File.Filename & "', '"
SQL = SQL & Replace(Upload.Form("DESCR"), "'", "''") & "', "
SQL = SQL & File.Size & ")"

' Save to database
File.ToDatabase Connect, SQL
Response.Write "File saved."
Else
Response.Write "File not selected."
End If
%>

</BODY>
</HTML>

the blue bold line is where explorer tells me the error is.
Thanks for you time.
BeTheBall

 

Posts: 6354
Joined: 6/21/2002
From: West Point Utah USA
Status: offline

 
RE: THis cant be happening..... - 10/9/2003 16:33:29   
Does this help: Microsoft Article

(in reply to 51)
51

 

Posts: 49
Joined: 5/30/2002
From:
Status: offline

 
RE: THis cant be happening..... - 10/10/2003 8:26:06   
Not really, I know its something minor with the save methodology

(in reply to BeTheBall)
BeTheBall

 

Posts: 6354
Joined: 6/21/2002
From: West Point Utah USA
Status: offline

 
RE: THis cant be happening..... - 10/10/2003 12:07:18   
If I understand the article correctly, I think you need to move the blob info to the end of your SQL. In other words, image_blob would be the last item in the INSERT statement.

(in reply to 51)
Page:   [1]

All Forums >> Web Development >> ASP and Database >> THis cant be happening.....
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts