Page.EnableViewState = true;
Parameters param = new Parameters(); DataSet datasetddlInternetwght = new DataSet(); datasetddlInternetwght = param.GetDDLListInternetWght(); ddlIntrntweight.DataTextField = datasetddlInternetwght.Tables[0].Columns["paramname"].ToString(); ddlIntrntweight.DataValueField = datasetddlInternetwght.Tables[0].Columns["paramvalue"].ToString(); ddlIntrntweight.DataSource = datasetddlInternetwght; ddlIntrntweight.DataBind();
if (!Page.IsPostBack) { ddlIntrntweight.DataSource = SqlDataSource1; ddlIntrntweight.DataBind(); }
AutoPostBack="True"
EnableViewState="True";
if(! isPostBack) { //Page load code here }
if(! isPostBack) { //I think you put your code here and set the EnableViewState property false; //set the EnableViewState property true or dont put your code here. }
<%@ Page Title="" ViewStateMode="Enabled" Language="C#" MasterPageFile="~/Default.Master" AutoEventWireup="true"
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)