|
| |
|
|
rhonda S
Posts: 17 Joined: 9/16/2004 Status: offline
|
RE: Input Form to Database - 9/21/2004 7:50:56
Good Morning Duane, I'm afraid that isn't doing it........After modifying the code, a runtime error message appears after selecting the file to upload from my hard drive, then close out of error messge and submit I get the following after submitting on process1.asp Database Results Error Description: [Microsoft][ODBC Microsoft Access Driver] Field 'Results.File' cannot be a zero-length string. Number: -2147467259 (0x80004005) Source: Microsoft OLE DB Provider for ODBC Drivers One or more form fields were empty. You should provide default values for all form fields that are used in the query.
|
|
|
|
BeTheBall
Posts: 6362 Joined: 6/21/2002 From: West Point Utah USA Status: offline
|
RE: Input Form to Database - 9/21/2004 9:58:31
Guess this one is going to test our persistence. Would be easier if I could test the upload part, but such is life. Next recommendation: Create Form.htm again, from scratch. However, when you do, instead of naming the upload field, "File", name it "Path". That should generate a line of HTML that looks like this: <p><input type="file" name="Path" size="20"></p> add the javascript to it so it looks like this: <p><input type="file" name="Path" size="20" onChange="this.form.File.value=this.value;"></p> Then, below that line, add: <input type="hidden" name="File"> By not doing it from scratch, we probably messed up the webbot that handles the upload. EDIT - If you want, create a new page in FP, switch to HTML view and delete all the code. Then, take the code below, paste it into Notepad and then from notepad to HTML view of the page you just created. Save it as Form2.htm, then open it in your browser and test the process again. This code worked on my PC, including the upload portion. Eventhough I don't have FP 2002, I do have the 2002 extensions which are what recognize the Upload webbot. Here is the code: <html>
<head>
<meta http-equiv="Content-Language" content="en-us">
<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 2</title>
</head>
<body>
<form method="POST" enctype="multipart/form-data" action="_vti_bin/shtml.dll/Form.htm">
<!--webbot bot="FileUpload" startspan
u-file="_private/Form_results2.txt"
s-format="TEXT/CSV" s-label-fields="False" b-reverse-chronology="FALSE"
s-destination="fpdb/" s-category s-assignedto
s-reviewstatus b-process-metainfo="FALSE" s-builtin-fields
s-form-fields="Name Email Comments File "
u-confirmation-url="confirmation.htm" --><!--webbot
bot="FileUpload" endspan -->
<p><input type="text" name="Name" size="20"></p>
<p><input type="text" name="Email" size="20"></p>
<p><input type="text" name="Comments" size="20"></p>
<p><input type="file" name="File" size="20"></p>
<p><input type="submit" value="Submit" name="B1"><input type="reset" value="Reset" name="B2"></p>
</form>
</body>
</html>
< Message edited by BeTheBall -- 9/21/2004 10:16:14 >
_____________________________
Duane Some people are like Slinkies . . . Not really good for anything . . . . . But they still bring a smile to your face when you push them down a flight of stairs.
|
|
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
|
|
|