Peter Chan
asked on
Problem to Dropdownlist
Hi,
I have the codes like
ddlStore.SelectedValue
is having empty value inside. why?
I have the codes like
sql = LibUtil.GetSqlCodeVG(accessRight, dept);
dt = DBUtil.GetCodeTable(conn, sql);
ddlStore.DataSource = dt;
ddlStore.DataValueField = "code";
ddlStore.DataTextField = "dscr";
ddlStore.DataBind();
public static string GetSqlCodeVG(string accessRight, string dept)
{
string sql = @"select store_no code, sfzone, concat(ifnull(dscr,''),', ',ifnull(store_no,'')) as dscr
from c_store_vg c
where deleted = '0' and dscr is NOT NULL ";
sql += "order by dscr ";
return sql;
}
to fill the Dropdownlist. But after I've selected one value to the DDL, I check thatddlStore.SelectedValue
is having empty value inside. why?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER