日期:2014-05-18 浏览次数:20394 次
conn=New OledbConnection(ConfigurationSettings.AppSettings("MM_CONNECTION_STRING_enconn")) sql="select pic,pdname from pd Where pdid=@pdid" cmd=New OledbCommand(sql,conn) conn.Open() cmd.parameters.Add("@pdid",OledbType.Integer).Value=intPdId rd=cmd.ExecuteReader() Dim s1 As String Dim s2 As String s1=rd("pdid").ToString s2=rd("pdname")
If rd.read() then s1=rd("pdid").ToString s2=rd("pdname") end if