473,394 Members | 1,813 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Going to a new ASP page depending on Variable in IF statement.

As a new ASP programmer, I am having problems going to a new page based on values in my ACCESS database table. Since my last post, I tried the following code below using eRedirect with only one paremeter, but it still did not work. Ultimately, I want to send more than one parameters to the new page. Could you help me resofve it? Your help would be much appreciated.

<form action="PPPCSurvey.asp">
<%
Dim V_ReadingLevel
Dim V_GradeLevel
Dim V_FName
Dim V_LName

V_ReadingLevel = PPPCRecordset("Part_ReadingLevel")
V_GradeLevel = PPPCRecordset("Part_GradeLevel")
V_FName = PPPCRecordset("Part_FName")
V_LName = PPPCRecordset("Part_LName")

if V_ReadingLevel = V_GradeLevel then
sRedirect = "PPPCSurvey.asp?RGLevel=" & V_ReadingLevel
Response.Redirect sRedirect
else
sRedirect = "PPPCSurvey.asp?RGLevel=" & V_GradeLevel
Response.Redirect sRedirect
end if

%>
<input type="submit" name="Submit" value="StartSurvey" >
</form></td></tr></table>

Could the "form action" clause what could be affecting the redirect? .
Oct 1 '06 #1
2 1238
sashi
1,754 Expert 1GB
Hi there,

Kindly refer to below code segment, hope it helps, take care my fren.. :)

Expand|Select|Wrap|Line Numbers
  1. <%
  2.   <Form action=somepage.asp?var1=value1&var2=value2>
  3. %>
  4.  
Oct 5 '06 #2
Thank you so so much for your help. It helps a lot.

Just another question if I may. What is the format of sending single and multiple variables to a ASP page with a Redirect? Is it a similar format? Could you demonstrate?

Thanks in advance.
Oct 6 '06 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

6
by: martin | last post by:
Hi, I am a web page and a web user control. My web user control is placed in my web page using the following directive <%@ Register TagPrefix="uc1" TagName="Header"...
10
by: darrel | last post by:
I have this structure: mypage.aspx (class = mypage) myusercontro.ascx On the mypage.aspx I can declare a variable: animal = "monkey" I can read this from the UC by simply doing this:...
2
by: simon | last post by:
hello, what i'm looking to do is store the path of the app on a the server for reuse in the site. my thoughts so far are... -make a key in the web.config file -retrieve the value in globals.asax...
13
by: Michael | last post by:
I have setup a public variable in the Master Page "code-behind-file". Now I would like to set that value from the UserControl, but I can't seem to find a way to do this. Does anyone have any ideas?...
0
by: Sonia Scott | last post by:
I need to do my Senior Project in ASP, and don't know it very well. I am trying to go to a new ASP page based on the value in my ACCESS database, which I already retrieved. The following code does...
4
by: Blasting Cap | last post by:
I have a page that has a number of radio buttons that will be displayed to different access levels of a user who logs in to my website. For instance, if there are a dozen buttons, user1 will see...
3
by: micky125 | last post by:
Hey guys I have been checking the forum for a way to populate a second select field depending on the choice made from the first one. Basically i am working on projects and the delays that occur. The...
2
by: JRough | last post by:
I have this code that switches templates depending on if the user fills in a form with a request. The request asks for the $mark & $number. If that request gets input then it displays a list...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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...

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.