Skip to main content

ASPxClientHiddenField Class

Represents a client-side equivalent of the ASPxHiddenField control.


declare class ASPxClientHiddenField extends ASPxClientControl


The ASPxClientHiddenField object serves as a client-side equivalent of the ASPxHiddenField control. In addition to the inherited common fucntionality, the ASPxClientHiddenField object provides the means to manipulate its values on the client side (such as the ASPxClientHiddenField.Add and ASPxClientHiddenField.Remove, ASPxClientHiddenField.Get and ASPxClientHiddenField.Set, ASPxClientHiddenField.Contains, ASPxClientHiddenField.Clear).


The following part of the ASPxHiddenField online demo illustrates how to manipulate the ASPxHiddenField items collection on the client and server side by using the ASPxClientHiddenField.Get, ASPxClientHiddenField.Set, ASPxHiddenField.Item property etc.

var viewsCount = 3;
function ShowPrevPage(){
function ShowNextPage(){
function ChangeActiveViewIndex(changeIndex){
    hfAnswers.Set("questionIndex", GetQuestionIndex() + changeIndex);
function GetQuestionIndex(){
    return hfAnswers.Get("questionIndex");
function IsPreviewPage(){
    return GetQuestionIndex() == (viewsCount - 1);
function OnSeasonChanged(s, e){
    hfAnswers.Set("month", 0);
    hfAnswers.Set("season", s.GetSelectedIndex());
function OnMonthChanged(s, e){
    hfAnswers.Set("month", s.GetSelectedIndex());
<script runat="server">
     private void LoadPreview() {
         int seasonIndex = (int)hfAnswers["season"];
         int monthIndex = (int)hfAnswers["month"];
         lblSelectedSeason.Text = seasons[seasonIndex];
         lblSelectedMonth.Text = months[seasonIndex][monthIndex];

 <dxhf:ASPxHiddenField runat="server" ClientInstanceName="hfAnswers" ID="hfAnswers">


See Also