Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8462495
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T14:10:39+00:00 2026-06-10T14:10:39+00:00

I have 5 web pages. I have 5 separate submit buttons on these pages.

  • 0

I have 5 web pages. I have 5 separate submit buttons on these pages. Happens such that when the user clicks submit on the respective page the information is get from the text box and stored in the variables like:

Suppose:

   static public String DOB;
   static public String CNIC;
   static public String Domicile;
   static public String Dependents;

    Gender = DropDownList8.SelectedItem.Text;
    Nationality = DropDownList8.SelectedItem.Text;
    Maritial_Status = DropDownList2.SelectedItem.Text;
    DOB = TextBox9.Text;

Like this i have different variables on first 4 pages and i want to access all of them on the last page.
I have to use all of these variables to commit insertion command through query so it means i need all of my variables to be provided for the insert command!

Kindly tell me an easy way how can i accomplish this!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T14:10:40+00:00Added an answer on June 10, 2026 at 2:10 pm

    You can accomplish this by below steps
    – create a class called which handles all your variables which needs to be put in the session
    and create properties like below

    public class SessionController
        {
            public static string DOB
            {
                get
                {
                    if (HttpContext.Current.Session["DOB"] != null)
                    {
                        return HttpContext.Current.Session["DOB"].ToString();
                    }
                    else
                    {
                        return null;
                    }
                }
                set
                {
                    HttpContext.Current.Session["DOB"] = value;
    
                }
            }
        }
    

    -After this access the properties from your aspx pages , before doing that reference this class by ‘using’ statement in the respective codebehind of aspx pages like below

    // The below code can be written in the aspx code behind

     SessionController.DOB = txtDob.Text;
     SessionController.Gender = Dropdownlist8.SelectedItem.Text;
    

    -and when you are accessing this in the last page you can pass the parameters to your insert method for example

    //calling the method

    SomeDALC.InsertMethod(SessionController.DOB,SessionController.Gender,etc... ) 
    

    like above

    Hope you understood how to use it.

    Regards
    Srividhya

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In my web application I have a user profile page. That page has these
I have web pages that are endless pages -- i.e. if the user goes
I have a lot of web pages that use the same exact html structure.
I have a problem of web pages being cached even though I specify that
I have 2 separate pages, each opens a web socket to the server, one
Basically what i have is a vb.net form that when a user clicks the
I have created web pages where am using pixel to position various html elements.
I visited Avis.com, and I notice the web pages have *.ac extension. Not familiar
I have a couple of web-pages where I write out some code c# ,
I have to download many many web pages and I am going to use

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.