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

  • SEARCH
  • Home
  • 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 9223213
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T04:01:23+00:00 2026-06-18T04:01:23+00:00

I have a javascript variable – type: var. How do I pass this from

  • 0

I have a javascript variable – type: var.

How do I pass this from the client side to the server side…and then use the value stored in the variable to do SQL queries in C# (asp.net)

(So far I have only done SQL queries with variables on the server side.)

and then after executing query, error checking; how do I return the result to the client side (javascript) and extract the useful information and apply it to my client side functionalities ?

Algorithm:-
1) accept var in client side 2) send request to server 3) accept on server side 4) use the query values (say firstname) and execute SQL query 5) check for result 6) if error then post error message else return result 7) accept result on client side 8) parse result and extract useful informatiom 9) use this information for client side functionalities.

Any ideas? Links with sample code ? What is this process formally called ? (maybe something like REST Web Service or other formalized names? )

Please help.

Thanks.

Var mem_ID = document.getElementById('<%=TextBox3.ClientID%>').value;

Now How do I pass this onto the server side??

  • 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-18T04:01:24+00:00Added an answer on June 18, 2026 at 4:01 am

    What would work is an AJAX call to a server side aspx.net file. Have it return the text value you like and then on the client side the JavaScript can recieve it and do with it what you like.

    This can be a complicated process. But that would be where you would begin your research.

    Here’s a link to get started.

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

Sidebar

Related Questions

I have a javascript variable: var foo='<script type=text/javascript>alert(Hello World);<\/script>' The variable is inserted with
I have a javascript variable which hold the value taken from somewhere else(lets say
I have a JavaScript variable: var selectValUser = $('.select_user :selected').val(); I need to use
I have a Javascript variable whatToRefresh which is defined in this way: var whatToRefresh
I have a javascript variable that I want to pass back to the server
I have a client global variable in javascript. I need to access this global
I have a javascript variable named response . This is the response from an
I have javascript string variable with var sttr=We prefer questions that can be answered
I have a JavaScript variable that stores a websocket connection like so: var ws
I have a JavaScript variable I grabbed from a form field and I am

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.