私の参照ボタンには次のようなコードがあります。
'Dim dlg As New Microsoft.Win32.OpenFileDialog()
...................................
薄暗い結果?ブール値として = dlg.ShowDialog()
結果 = True の場合
文字列としての薄暗いファイル名 = dlg.FileName
brand_img.Source = New BitmapImage(New Uri(ファイル名))
tpath.Text = ファイル名
終了条件
次に、その画像をデータベースに保存したいと思います。それはどのように可能ですか?彼の助けに感謝します。私はこのような保存ボタンを持っています...
cn.ConnectionString = "Provider=Microsoft.Ace.Oledb.12.0; データ ソース=" & My.Application.Info.DirectoryPath.ToString() & "\mvdata.accdb;"
cn.Open()
rs.State = True の場合、rs.Close()
rs.Open("Select * from company", cn, ADODB.CursorTypeEnum.adOpenDynamic, ADODB.LockTypeEnum.adLockOptimistic)
textbrname.Text = "" または textbrdesc.Text = "" の場合
terr.Foreground = Brushes.Red
terr.Text = "フィールドが空でないことを確認してください。"
そうしないと
rs.AddNew()
rs("comp_imp").Value = ???????
rs("comp").Value = textbrname.Text
rs("comp_desc").Value = textbrdesc.Text
rs.Update()
終了条件
rs.Close()
cn.Close()
助けてくれてありがとう...