|
 |
access_asp thread: Memo Fields
Message #1 by bayou_ranch@m... on Fri, 11 Oct 2002 16:17:05
|
|
I have an asp page that updates the database using input from a web form.
The programming generates no errors, yet in cases where the database field
is a "memo" field, the text from the web form does not get entered into
the database field. I have already checked the obvious: field names,
form names, and so on.
Is there a reason this is only happening with memo fields??
Thanks in advance
Message #2 by "Chetan Kelkar" <chetan@c...> on Sat, 12 Oct 2002 11:18:40 +0530
|
|
Can you post the code in here for us to see ?
----- Original Message -----
From: <bayou_ranch@m...>
To: Access ASP <access_asp@p...>
Sent: Friday, October 11, 2002 4:17 PM
Subject: [access_asp] Memo Fields
> I have an asp page that updates the database using input from a web form.
>
> The programming generates no errors, yet in cases where the database field
> is a "memo" field, the text from the web form does not get entered into
> the database field. I have already checked the obvious: field names,
> form names, and so on.
>
> Is there a reason this is only happening with memo fields??
>
> Thanks in advance
>
Message #3 by "Charles Mabbott" <aa8vs@m...> on Sat, 12 Oct 2002 11:59:04 -0400
|
|
Here is input page [htm]
=======================================
<snip>
<p><h2>If you wish to leave a message, tell me something about yourself,
have any comments and wish to share, please enter comments.</h2>
<h3>Blank first and or last name not allowed and you will be returned
to main page. Blank call or any of remaining fields will be noted
in the record.</h3>
<form action="SQLlog.asp" METHOD=GET >
<table border="2" width="548">
<tr> <td align=center width="205">
<i><b>First name<br>
<input type="TEXT" Name="sFn" size=25>
</td>
<td align=center width="325"><i><b>Last name<br>
<input type="TEXT" Name="sLn" size=25></td>
</tr>
<tr>
<td align=center width="205"><i><b>Call sign or "SWL"<br>
<input type="TEXT" Name="sCl" size=7></td>
<td align=center width="325"><i><b>E-mail address Optional<br>
<input type="TEXT" Name="sEl" size=45></td>
</tr>
<tr>
<td colspan=2 align=center width="516">
<i><b>Any comments, questions, messages etc.<br>
<TEXTAREA NAME="scm" ROWS=13 COLS=62></TEXTAREA><br>
</b></i>
</td>
</table>
<p><input type="SUBMIT" name="send" Value="Enter log">
<input type="RESET" Value="Clear Log"><br>
</form>
</body>
========= next is asp page ============
<%
Option Explicit
Dim strConnect, datarr(3)
%>
<!-- #include file="Datapointer.asp" -->
<!-- METADATA TYPE="typelib"
FILE="C:\Program Files\Common Files\System\ado\msado15.dll"
-->
<HTML>
<HEAD>
<TITLE>Writing to Log</TITLE>
</HEAD>
<BODY>
<center>
<h1>Writing to AA8VS' Log</h1>
</center>
<%
' name proper case function
function namecase(vname)
namecase= ucase(left(vname,1)) + lcase(right(vname,len(vname)-1 ))
end function
Dim objRS, objComm, intNoOfRecords
Dim strfname, strlname, strcall, strmail, strcomment, strhttp
strfname = ltrim(Request.QueryString("sfn") ) ' first name
if(len(strfname) < 1) then
response.redirect "default.asp"
end if
strfname = namecase(strfname) ' correct for case
strlname = ltrim(request.QueryString("sln") ) ' last name
if(len(strlname) < 1) then
response.redirect "default.asp"
end if
strlname = namecase(strlname) ' correct for case
strhttp = request.servervariables("REMOTE_ADDR")
strcall = Ltrim(UCase(request.QueryString("scl") ) ) ' FCC call sign
if (len(strcall) < 1) then
strcall = "SWL"
end if
strmail = request.QueryString("sel") ' Member e-mail
if (len(strmail) < 1) then
strmail = "No e-mail given"
end if
strcomment = request.QueryString("scm") ' message left
if (len(strcomment) < 1) then
strcomment = "No Comment left"
end if
' Check to verify data came in from page properly
response.write "Name: " & strfname & " " & strlname & " <br> " & _
"Call Sign " & strcall & "<br>" & _
"E-mail " & strmail & "<br>" & _
"Comment: " & strcomment
' setup table to insert the data
Set objComm = Server.CreateObject("ADODB.Command")
objComm.ActiveConnection = strConnect
objComm.ActiveConnection = strConnect
objComm.CommandText = "INSERT INTO chucklog(Fname, lname, callid, email,
comment, pcip)" & _
" VALUES('" & strfname & "', '" & strlname & "' , '" & strcall & "', ' " &
strmail & "', '" & strcomment & "', '" & strhttp & "')"
objComm.CommandType = adCmdText
objComm.Execute intNoOfRecords
Response.Write "<p>The entry has been executed and ; " & _
" " & intNoOfRecords & " record has been added <HR>"
Set objComm = Nothing
%>
<center>
<a href="logAA8VS.htm#top">Another entry</a> page<br>
<a href="default.asp#top">Home</a> page
</center>
<h3>Last update: 5/22/02</h3>
</BODY>
</HTML>
=========== end of asp page ==============
Nothing tricky and I hope it helps.
Regards,
Chuck
>From: "Chetan Kelkar" <chetan@c...>
>Reply-To: "Access ASP" <access_asp@p...>
>To: "Access ASP" <access_asp@p...>
>Subject: [access_asp] Re: Memo Fields
>Date: Sat, 12 Oct 2002 11:18:40 +0530
>
>Can you post the code in here for us to see ?
>----- Original Message -----
>From: <bayou_ranch@m...>
>To: Access ASP <access_asp@p...>
>Sent: Friday, October 11, 2002 4:17 PM
>Subject: [access_asp] Memo Fields
>
>
> > I have an asp page that updates the database using input from a web
>form.
> >
> > The programming generates no errors, yet in cases where the database
>field
> > is a "memo" field, the text from the web form does not get entered into
> > the database field. I have already checked the obvious: field names,
> > form names, and so on.
> >
> > Is there a reason this is only happening with memo fields??
> >
> > Thanks in advance
> >
>
>
"If your not part of the solution,
there is good money to be made
prolonging the problem."
http://68.43.100.7:81/aa8vs
_________________________________________________________________
MSN Photos is the easiest way to share and print your photos:
http://photos.msn.com/support/worldwide.aspx
Message #4 by "Charles Mabbott" <aa8vs@m...> on Sat, 12 Oct 2002 12:08:24 -0400
|
|
I hate it when it does that, let me try the ASP page
again.
=================================================
the '%>' and '<%' have been removed for clarity
Option Explicit
Dim strConnect, datarr(3)
<HTML>
<HEAD>
<TITLE>Writing to Log</TITLE>
</HEAD>
<BODY>
<center>
<h1>Writing to AA8VS' Log</h1>
</center>
==========
' name proper case function
function namecase(vname)
namecase= ucase(left(vname,1)) + lcase(right(vname,len(vname)-1 ))
end function
Dim objRS, objComm, intNoOfRecords
Dim strfname, strlname, strcall, strmail, strcomment, strhttp
strfname = ltrim(Request.QueryString("sfn") ) ' first name
if(len(strfname) < 1) then
response.redirect "default.asp"
end if
strfname = namecase(strfname) ' correct for case
strlname = ltrim(request.QueryString("sln") ) ' last name
if(len(strlname) < 1) then
response.redirect "default.asp"
end if
strlname = namecase(strlname) ' correct for case
strhttp = request.servervariables("REMOTE_ADDR")
strcall = Ltrim(UCase(request.QueryString("scl") ) ) ' FCC call sign
if (len(strcall) < 1) then
strcall = "SWL"
end if
strmail = request.QueryString("sel") ' Member e-mail
if (len(strmail) < 1) then
strmail = "No e-mail given"
end if
strcomment = request.QueryString("scm") ' message left
if (len(strcomment) < 1) then
strcomment = "No Comment left"
end if
' Check to verify data came in from page properly
response.write "Name: " & strfname & " " & strlname & " <br> " & _
"Call Sign " & strcall & "<br>" & _
"E-mail " & strmail & "<br>" & _
"Comment: " & strcomment
' setup table to insert the data
Set objComm = Server.CreateObject("ADODB.Command")
objComm.ActiveConnection = strConnect
objComm.ActiveConnection = strConnect
objComm.CommandText = "INSERT INTO chucklog(Fname, lname, callid, email,
comment, pcip)" & _
" VALUES('" & strfname & "', '" & strlname & "' , '" & strcall & "', ' " &
strmail & "', '" & strcomment & "', '" & strhttp & "')"
objComm.CommandType = adCmdText
objComm.Execute intNoOfRecords
Response.Write "<p>The entry has been executed and ; " & _
" " & intNoOfRecords & " record has been added <HR>"
Set objComm = Nothing
===========
<center>
>From: "Charles Mabbott" <aa8vs@m...>
>Reply-To: "Access ASP" <access_asp@p...>
>To: "Access ASP" <access_asp@p...>
>Subject: [access_asp] Re: Memo Fields
>Date: Sat, 12 Oct 2002 11:59:04 -0400
>
>Here is input page [htm]
>
>=======================================
>
><snip>
>
><p><h2>If you wish to leave a message, tell me something about yourself,
>have any comments and wish to share, please enter comments.</h2>
><h3>Blank first and or last name not allowed and you will be returned
>to main page. Blank call or any of remaining fields will be noted
>in the record.</h3>
>
><form action="SQLlog.asp" METHOD=GET >
><table border="2" width="548">
><tr> <td align=center width="205">
><i><b>First name<br>
><input type="TEXT" Name="sFn" size=25>
></td>
>
><td align=center width="325"><i><b>Last name<br>
><input type="TEXT" Name="sLn" size=25></td>
></tr>
>
><tr>
><td align=center width="205"><i><b>Call sign or "SWL"<br>
><input type="TEXT" Name="sCl" size=7></td>
>
><td align=center width="325"><i><b>E-mail address Optional<br>
><input type="TEXT" Name="sEl" size=45></td>
></tr>
>
><tr>
><td colspan=2 align=center width="516">
><i><b>Any comments, questions, messages etc.<br>
><TEXTAREA NAME="scm" ROWS=13 COLS=62></TEXTAREA><br>
></b></i>
></td>
></table>
><p><input type="SUBMIT" name="send" Value="Enter log">
><input type="RESET" Value="Clear Log"><br>
></form>
>
></body>
>========= next is asp page ============
><%
> Option Explicit
> Dim strConnect, datarr(3)
>%>
><!-- #include file="Datapointer.asp" -->
><!-- METADATA TYPE="typelib"
> FILE="C:\Program Files\Common Files\System\ado\msado15.dll"
>-->
>
><HTML>
><HEAD>
><TITLE>Writing to Log</TITLE>
></HEAD>
><BODY>
><center>
><h1>Writing to AA8VS' Log</h1>
></center>
><%
>' name proper case function
> function namecase(vname)
> namecase= ucase(left(vname,1)) + lcase(right(vname,len(vname)-1 ))
> end function
>
>
> Dim objRS, objComm, intNoOfRecords
> Dim strfname, strlname, strcall, strmail, strcomment, strhttp
>
> strfname = ltrim(Request.QueryString("sfn") ) ' first name
> if(len(strfname) < 1) then
> response.redirect "default.asp"
> end if
> strfname = namecase(strfname) ' correct for case
>
> strlname = ltrim(request.QueryString("sln") ) ' last name
> if(len(strlname) < 1) then
> response.redirect "default.asp"
> end if
> strlname = namecase(strlname) ' correct for case
>
> strhttp = request.servervariables("REMOTE_ADDR")
>
>
> strcall = Ltrim(UCase(request.QueryString("scl") ) ) ' FCC call sign
> if (len(strcall) < 1) then
> strcall = "SWL"
> end if
>
> strmail = request.QueryString("sel") ' Member e-mail
> if (len(strmail) < 1) then
> strmail = "No e-mail given"
> end if
>
> strcomment = request.QueryString("scm") ' message left
> if (len(strcomment) < 1) then
> strcomment = "No Comment left"
> end if
>
>' Check to verify data came in from page properly
>
> response.write "Name: " & strfname & " " & strlname & " <br> " & _
> "Call Sign " & strcall & "<br>" & _
> "E-mail " & strmail & "<br>" & _
> "Comment: " & strcomment
>
>
>' setup table to insert the data
>
> Set objComm = Server.CreateObject("ADODB.Command")
>
> objComm.ActiveConnection = strConnect
>
>
> objComm.ActiveConnection = strConnect
> objComm.CommandText = "INSERT INTO chucklog(Fname, lname, callid, email,
>comment, pcip)" & _
>" VALUES('" & strfname & "', '" & strlname & "' , '" & strcall & "', ' " &
>strmail & "', '" & strcomment & "', '" & strhttp & "')"
> objComm.CommandType = adCmdText
> objComm.Execute intNoOfRecords
>
> Response.Write "<p>The entry has been executed and ; " & _
> " " & intNoOfRecords & " record has been added <HR>"
>
> Set objComm = Nothing
>%>
><center>
><a href="logAA8VS.htm#top">Another entry</a> page<br>
>
><a href="default.asp#top">Home</a> page
></center>
><h3>Last update: 5/22/02</h3>
></BODY>
></HTML>
>
>=========== end of asp page ==============
>Nothing tricky and I hope it helps.
>
>Regards,
>Chuck
>
>
>>From: "Chetan Kelkar" <chetan@c...>
>>Reply-To: "Access ASP" <access_asp@p...>
>>To: "Access ASP" <access_asp@p...>
>>Subject: [access_asp] Re: Memo Fields
>>Date: Sat, 12 Oct 2002 11:18:40 +0530
>>
>>Can you post the code in here for us to see ?
>>----- Original Message -----
>>From: <bayou_ranch@m...>
>>To: Access ASP <access_asp@p...>
>>Sent: Friday, October 11, 2002 4:17 PM
>>Subject: [access_asp] Memo Fields
>>
>>
>> > I have an asp page that updates the database using input from a web
>>form.
>> >
>> > The programming generates no errors, yet in cases where the database
>>field
>> > is a "memo" field, the text from the web form does not get entered into
>> > the database field. I have already checked the obvious: field names,
>> > form names, and so on.
>> >
>> > Is there a reason this is only happening with memo fields??
>> >
>> > Thanks in advance
>> >
>>
>>
>
>
>
>
>"If your not part of the solution,
>there is good money to be made
>prolonging the problem."
>http://68.43.100.7:81/aa8vs
>
>
>_________________________________________________________________
>MSN Photos is the easiest way to share and print your photos:
>http://photos.msn.com/support/worldwide.aspx
>
>
>---
>Change your mail options at http://p2p.wrox.com/manager.asp or to
>unsubscribe send a blank email to
"If your not part of the solution,
there is good money to be made
prolonging the problem."
http://68.43.100.7:81/aa8vs
_________________________________________________________________
Join the world?s largest e-mail service with MSN Hotmail.
http://www.hotmail.com
|
|
 |