Dim dr As DataRow = Tables("职员信息管理_职员信息表").Current.DataRow
If dr IsNot Nothing
Dim dlg As New OpenFileDialog
dlg.Filter = "图形文件|*.bmp;*.jpg;*.gif;*.png"
If dlg.ShowDialog = DialogResult.OK Then
dr.SQLInsertFile("photo",dlg.FileName) '插入文件
Dim pic As WinForm.PictureBox = e.Form.Controls("PictureBox1")
pic.Image = GetImage(dlg.FileName)
Dim cmd As New SQLCommand
cmd.C
cmd.CommandText = "select * fr om {职员信息表} where sysid = '" & dr("SysId") & "'"
Dim ct As DataTable = cmd.ExecuteReader
Dim cr As DataRow = ct.Find("SysId= '" & dr("SysId") & "'")
cr.SQLInsertFile("photo",dlg.FileName)
End If
End If