viewstate problem

Results 1 to 2 of 2

Thread: viewstate problem

  1. #1
    Join Date
    Dec 1969

    Default viewstate problem

    I am having a problem with my dropdown list keeping its values after a postback. I have viewstate set to true on the control and on the initial page load I supply the initial values.<BR><BR>when I view the page source I do not see much data in the hidden viewstate control.<BR><BR>Any suggestions, <BR><BR>If Page.IsPostBack = False Then<BR> Dim country As project.DB = New project.DB()<BR> Me.cboCountry.DataSource = country.GetCountries<BR> Me.cboCountry.DataBind()<BR> cboCountry.Items.Insert(0, New ListItem("-SELECT A COUNTRY-", 0))<BR> cboCountry.SelectedIndex = 0<BR><BR> End If

  2. #2
    Join Date
    Dec 1969

    Default RE: viewstate problem

    1. What does your EnableViewState property at the page level says?<BR>2. Run the application in debug mode and after binding data to your dropdown check for the item count etc. in the immediate window.<BR><BR>HTH

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts