Form submission problems...
Messages   Related Types
This message was discovered on ASPFriends.com 'aspngfreeforall' list.


Hedrick, James
I am having a time trying to figure this one out.... I have two aspx files,
done using CodeBehind. The first one is a standard HTML form with several
<input type=text> boxes and a submit button. The second is the action of the
first page. The first textbox on the form I am submitting looks like this:
<input class="textbox" style="WIDTH: 182px" tabIndex="1" type="text"
maxLength="10" name="txtClientNumber">

The page it submits to has a page_load()...

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
TextBox1.Text = Request.Form("txtClientNumber") 'THIS LINE WORKS...IT KNOWS
WHAT txtClientNumber holds.
sbQuery.Append("SELECT clientNumber,Address1,Address2,City,State,Zip,")
sbQuery.Append("OriginatingAtty,BusinessType,Narrative FROM Clients")
If Session("Group") = 0 Then
    sbQuery.Append(" WHERE CurrentGraphingSelection = " &
Session("CurrentGraphingSelection"))
Else
    sbQuery.Append(" WHERE ParentGroup = " & Session("Group"))
End If
If Request.Form("txtClientNumber") <> "" Then 'HERE IT DOESNT KNOW WHAT
txtClientNumber is...
    sbQuery.Append(" AND clientNumber = '" &
Request.Form("txtClientNumber") & "'")
Else
    sbQuery.Append(" FAILED ")
End If
end sub

The page_load knows what Request.Form("txtClientNumber") is on the first
line, the output....but a couple of lines later the if test fails and the
output shows it doesnt know what Request.Form("txtClientNumber") is
then...WHAT HAS CHANGED? HELP!

Thanks in advance,
James

***********************************************************************
NOTICE: This e-mail message and all attachments transmitted with it may contain legally privileged and confidential information intended solely for the use of the addressee. If the reader of this message is not the intended recipient, you are hereby notified that any reading, dissemination, distribution, copying, or other use of this message or its attachments is strictly prohibited. If you have received this message in error, please notify the sender immediately by telephone (404-881-7000) or by electronic mail (Click here to reveal e-mail address), and delete this message and all copies and backups thereof. Thank you.
=======================================================

Reply to this message...
 
    
Chris Jackson
try stuffing Request.Form("txtClientNumber") into a dimed variable

dim intVar as integer
intVar = Request.Form("txtClientNumber")

and see if this helps

----- Original Message -----
From: "Hedrick, James" <Click here to reveal e-mail address>
To: "aspngfreeforall" <Click here to reveal e-mail address>
Sent: Thursday, August 15, 2002 11:56 AM
Subject: [aspngfreeforall] Form submission problems...

> I am having a time trying to figure this one out.... I have two aspx
files,
[Original message clipped]

the use of the addressee. If the reader of this message is not the intended
recipient, you are hereby notified that any reading, dissemination,
distribution, copying, or other use of this message or its attachments is
strictly prohibited. If you have received this message in error, please
notify the sender immediately by telephone (404-881-7000) or by electronic
mail (Click here to reveal e-mail address), and delete this message and all copies and
backups thereof. Thank you.
[Original message clipped]

Reply to this message...
 
 
System.EventArgs
System.Object




Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
 
 Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us - Terms of Use - Privacy Policy - www.dotnet247.com