Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17


How do you use values from web forms accross multiple pages

Posted on 2004-08-18
Medium Priority
Last Modified: 2010-04-17

I have a web form and I want to be able to use the values from the controls accross multiple web pages.

For example when users log into a site, how can I show details from the user even when selecting different pages.

If someone could even tell me where I should be reading to get this information I would be very thankful

Question by:pgilfeather
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
  • +1
LVL 35

Accepted Solution

YZlat earned 500 total points
ID: 11833675
Declare your controls as Public.

LVL 11

Assisted Solution

Jase-Coder earned 500 total points
ID: 11833841

Assisted Solution

SirK earned 500 total points
ID: 11836214
Just include a module, and inside that module, declare the variables that you wish to store your data inside as global.

Inside Module1:

Global myVarName as Integer, myStringName as String


Then when you access them later, they will still be there with the same values.
Build and deliver software with DevOps

A digital transformation requires faster time to market, shorter software development lifecycles, and the ability to adapt rapidly to changing customer demands. DevOps provides the solution.


Assisted Solution

bigjim2000 earned 500 total points
ID: 11836251
I'd make a struct with all the values in it.  Then just store this struct as an object in the servers session state.  Each time you load a page, grab this struct from the session, populate it with some values (the ones you need for that particular page) and you are set.  TO make this even faster, store the object in the cache.

Also, when the user changes a value that you want to remember, just grab the object again, make the change, and put it back in the session/cache.

LVL 11

Expert Comment

ID: 12046542
I thought that my solution, rather links were, helpful enough to be classed as an answer to the problem.
LVL 35

Expert Comment

ID: 12067040
declaring controls and variables as Public allows to access them from different pages

Expert Comment

ID: 12078061
I think that all of our suggestions are useful, so I suggest that we divide the points up among everyone who added advice.

LVL 11

Expert Comment

ID: 12083055
I'll agree to that.

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
What do responsible coders do? They don't take detrimental shortcuts. They do take reasonable security precautions, create important automation, implement sufficient logging, fix things they break, and care about users.
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …
Introduction to Processes

660 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question