开发者

Please help.How can I get the stored procedure I have created at SQL Server Management Studio using ASP.NET with VB.NET Code behind the files

How can I get the output开发者_JS百科 data of sql procedure from SQL Server to my asp.net[vb.net] page dropdown list?<asp:DropDownList ID="DdLocation"></asp:DropDownList>


Get the data from SQL to either a dataset or a datatable: http://www.google.com/search?q=vb.net+get+data+from+sql+server+to+dataset

Then on the DdLocation_Load, or Page_Load event, bind the data:

DdLocation.DataSource = location_data
DdLocation.DataTextField = "LocationDesc"
DdLocation.DataValueField = "LocationID"
DdLocation.DataBind()

Once you call DataBind, the data will be attached to the drop down list.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜