Public Sub Combo1_Click()
我們提供的服務(wù)有:成都網(wǎng)站建設(shè)、成都做網(wǎng)站、微信公眾號開發(fā)、網(wǎng)站優(yōu)化、網(wǎng)站認(rèn)證、興賓ssl等。為上千家企事業(yè)單位解決了網(wǎng)站和推廣的問題。提供周到的售前咨詢和貼心的售后服務(wù),是有科學(xué)管理、有技術(shù)的興賓網(wǎng)站制作公司
Dim adoCnn As ADODB.Connection
Dim rstOra As ADODB.Recordset
Dim intI As Integer
Set adoCnn = New ADODB.Connection
Set rstOra = New ADODB.Recordset
adoCnn.ConnectionString = "Provider=OraOLEDB.Oracle;User ID=dzjc;password=zlkj;Data Source=dzjc_2005;" '讀blob字段要用Provider=OraOLEDB.Oracle
adoCnn.CursorLocation = adUseClient
adoCnn.Open
rstOra.CursorLocation = adUseClient
rstOra.ActiveConnection = adoCnn
rstOra.Open "SELECT zp FROM dzjc.dzjc_wfzp WHERE xh = '5'"
'Set Image1.DataSource = rstOra
Set Image1.Picture = PictureFromByteStream(rstOra.Fields("zp").Value)
End Sub
Dim curSqlstr As String = "INSERT INTO Picture(picture_id, picture_area)" _
"VALUES('" (i + 1).ToString() "','@picture_area ')"
你看這句中的,'@picture_area ')",多個(gè)單引號了,被當(dāng)成VARCHAR處理了.去了單引號才是變量.
假如b窗體是form2,在a窗體中調(diào)用B窗體,直接dim frm as new form2,然后frm.show()就OK