Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 2.0 > ASP.NET 2.0 Basics
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
ASP.NET 2.0 Basics If you are new to ASP or ASP.NET programming with version 2.0, this is the forum to begin asking questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Basics section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old December 25th, 2005, 11:03 AM
Registered User
 
Join Date: Dec 2005
Location: , , .
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default Passing Javascript Variables to Asp.Net?

I can't seem to figure out how to pass a variable like an array from javascript variable to asp.net. Does anyone know how to do it?

Reply With Quote
  #2 (permalink)  
Old December 27th, 2005, 05:46 PM
Imar's Avatar
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Are you talking about AJAX, or plain and simple posting back?

In the latter case, you could store the array's elements as a, say, comma separate list of values in a hidden form field that you can at the server to reconstruct a server-side array.

HtH,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
Reply With Quote
  #3 (permalink)  
Old September 2nd, 2006, 05:06 AM
Registered User
 
Join Date: Sep 2006
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

hello,

      Im also having trouble in passing object values from javascript to asp.net page with out posting back this will reduce some d/w u/p time in handling large size objects as I studied.
      Try search as serialization in javascript this may result some useful info.
      Please try to share with the forum any possible solutions if you got.
thanks,
......thiru



Reply With Quote
  #4 (permalink)  
Old September 8th, 2006, 11:37 PM
Authorized User
Points: 333, Level: 6
Points: 333, Level: 6 Points: 333, Level: 6 Points: 333, Level: 6
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Apr 2005
Location: Fresno, California, USA.
Posts: 94
Thanks: 0
Thanked 0 Times in 0 Posts
Default

There isn't anyway to send info from Java to server without postback. Java is client side and asp.net C# or vb code is server side. Like someone posted real quick, if you want to eliminate postback you will have to do AJAX. I have wrote a few pages that would take variables from java and store them in my ASP.NET 2.0 session through using the xmlHttp object.
You can find sources out there to help you. If this interests you, Wrox has written a good AJAX beginning book I have read through.

Reply With Quote
  #5 (permalink)  
Old September 8th, 2006, 11:52 PM
Registered User
 
Join Date: Aug 2006
Location: Ahmedabad, Gujarat, India.
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default


I completely agree with Quick209 (I can't see his name).

Hitul J. Patel
Software Engineer
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Passing Variables from Javascript/AJAX to VBScrip mperry Classic ASP Basics 3 November 12th, 2007 03:29 AM
Passing a ASP varible to a javascript tdaustin Classic ASP Basics 1 May 17th, 2005 01:44 AM
Passing PHP variables to javascript wfrisch Pro PHP 10 April 5th, 2005 05:13 AM
Passing Session Variables(ASP.NEt) to Jscript ank2go JSP Basics 1 February 26th, 2004 09:53 PM
equating javascript and ASP variables GregH Classic ASP Basics 3 July 3rd, 2003 02:42 AM



All times are GMT -4. The time now is 12:28 PM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.