473,386 Members | 1,630 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,386 software developers and data experts.

Control page flow in ASP.Net 1.0 and 2.0

Hi All :-)



I have a general question about controlling page follow and if there is a better way to do it than I am currently using in ASP.Net 1.0 - we are getting ready to move to 2.0, so if there's a better/easier way in 2.0 that's great.



What I'm doing is creating a Session variable for each page to identify that page when it is requested from a directory, I set the Session("page_name") for the page called and pass that to the next page until I need to call a different page and then change the page_name as needed.



I know that there has to be a better way to do this, and this leads to problems if the user wants to use the drop-down JavaScript menu instead of click on the Next buttons. I need a way to uniquely identify which page is called from where, and pass that ID depending on which page is called.



Any suggestions would be greatly appreciated, or if you can point me to where I can find good documentation on how to do this without using session variables, I would appreciate it. TIA,



Coleen



Aug 31 '06 #1
2 1058
I'm not sure what is the exact problem. If this to have a convenient way to
get the current page, try Request.Path

--
Patrice

"Coleen" <co**********@yahoo.coma écrit dans le message de news:
%2****************@TK2MSFTNGP03.phx.gbl...
Hi All :-)

I have a general question about controlling page follow and if there is a
better way to do it than I am currently using in ASP.Net 1.0 - we are
getting ready to move to 2.0, so if there's a better/easier way in 2.0
that's great.

What I'm doing is creating a Session variable for each page to identify that
page when it is requested from a directory, I set the Session("page_name")
for the page called and pass that to the next page until I need to call a
different page and then change the page_name as needed.

I know that there has to be a better way to do this, and this leads to
problems if the user wants to use the drop-down JavaScript menu instead of
click on the Next buttons. I need a way to uniquely identify which page is
called from where, and pass that ID depending on which page is called.

Any suggestions would be greatly appreciated, or if you can point me to
where I can find good documentation on how to do this without using session
variables, I would appreciate it. TIA,

Coleen


Aug 31 '06 #2
The problem is 1) using Session variables is resource consuming when you have to use lots of the (there are about 40 pages in this application) and every page has to have a page_name (ID); and 2) If the user tries to use the JavaScript dropdown menus instead of the Next button to navigate from page to page, the Session variable is not passed correctly causing a runtime error!



I need a way to pass the ID of a page (does a page automatically get some sort of ID in ASP.Net? I can't find any info on this in my reference books) and if it does, how can I pass that ID instead of using the session variable page_name that I have created?



What is Request.Path? Does it pass a page ID? Please let me know where I can find more info on this, and if it will do what I need...

Thanks!



Coleen


"Patrice" <sc****@chez.comwrote in message news:%2****************@TK2MSFTNGP03.phx.gbl...
I'm not sure what is the exact problem. If this to have a convenient way to
get the current page, try Request.Path

--
Patrice

"Coleen" <co**********@yahoo.coma écrit dans le message de news:
%2****************@TK2MSFTNGP03.phx.gbl...
Hi All :-)

I have a general question about controlling page follow and if there is a
better way to do it than I am currently using in ASP.Net 1.0 - we are
getting ready to move to 2.0, so if there's a better/easier way in 2.0
that's great.

What I'm doing is creating a Session variable for each page to identify that
page when it is requested from a directory, I set the Session("page_name")
for the page called and pass that to the next page until I need to call a
different page and then change the page_name as needed.

I know that there has to be a better way to do this, and this leads to
problems if the user wants to use the drop-down JavaScript menu instead of
click on the Next buttons. I need a way to uniquely identify which page is
called from where, and pass that ID depending on which page is called.

Any suggestions would be greatly appreciated, or if you can point me to
where I can find good documentation on how to do this without using session
variables, I would appreciate it. TIA,

Coleen

Aug 31 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: Robert Bowen | last post by:
Hello all. I have been given mock-ups (in static HTML) of some pages for a site I am working on. The client would like these pages to look exactly as they do now. The problem is that the content is...
0
by: Nathan | last post by:
Hi, I seem to having a peculiar problem with the display of odd and even pages in XSL-FO. Here is a small background of the problem. My xsl stylesheet mentions my fo:layout-master-set as ...
1
by: Michel | last post by:
Hi all, This is my first post, so I am very new at this. I am trying to use page-number-citation twice in my code, but the second time it just shows '0'. The output is in pdf format and I am...
5
by: Miyra | last post by:
Hi. I'm working with an app that uses exceptions for control flow. These are code blocks where exceptions are thrown/caught regularly. A couple hundred exceptions occur per hour and they're caught...
9
by: Alvin Bruney [MVP] | last post by:
Exceptions must not be used to control program flow. I intend to show that this statement is flawed. In some instances, exceptions may be used to control program flow in ways that can lead to...
2
by: John Francisco Williams | last post by:
Hi all, how can I set the absolute position of a control on a webpage? The control would be a server control and I need to be able to do this using the code behind. Thanks in advance, Frank
4
by: Shimon Sim | last post by:
Is it possible to find top left corner of a control using JavaScript? As far as I know it is very easy to do if you use Grid layout while designing a page. But if you are using flow layout I didn't...
10
by: sqlboy2000 | last post by:
Hello all, I have something very simple going on here and I'm scratching my head as to what the problem is. There are 4 items in my project, 2 webforms, a user control, and a module: ...
0
by: Pavan | last post by:
My name is Pavan and I am a software engineer working on ASP .Net web development. Currently I am using .Net 2.0 Professional Edition to develop my web pages. I have a problem
2
by: brianlum | last post by:
Hi, I have been looking for a good way to convert python code into a control flow graph. I know of Python functions that will convert an expression into an abstract syntax tree (i.e. ast =...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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,...

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.