Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: ASP.NET
Hi,
 
I have a hidden field
<asp:HiddenField runat="server" ID="hdnRow" />
in my aspx page. adding values into this hidden field in
a button click at client side using javascript. i want to get the values
of hidden field in server side without postback. how to get the hidden field value?
 
is it possible using ajax?
 
thanks..
Posted 24-Jan-13 1:36am
hasbina1.2K
Edited 24-Jan-13 2:29am
v3
Comments
Azziet at 24-Jan-13 6:41am
   
question is not clear...please give more details
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Yes It's possible with Ajax Async Postback.
You can simply place the Button inside Ajax Update panel & postback it Asynchronously without posting back the whole page.
 
Secondly you can use jQuery to call Server side method Asynchronously & just pass the Hidden filed value while calling the Server side method & catch this value in your Server side method.
 
So if you know how to implement these 2 techniques then I'm sure you can get your Solution.
  Permalink  
v2
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Put the hidden field in in Update Panel to get the value at server side.
  Permalink  
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 277
1 Maciej Los 210
2 BillWoodruff 205
3 Jochen Arndt 180
4 Sergey Alexandrovich Kryukov 165
0 OriginalGriff 5,130
1 DamithSL 4,157
2 Maciej Los 3,650
3 Kornfeld Eliyahu Peter 3,460
4 Sergey Alexandrovich Kryukov 2,811


Advertise | Privacy | Mobile
Web01 | 2.8.141216.1 | Last Updated 24 Jan 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100