Click here to Skip to main content
16,005,169 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Help with vbscript and Windows NT Pin
Dave Kreskowiak26-Mar-06 13:10
mveDave Kreskowiak26-Mar-06 13:10 
GeneralRe: Help with vbscript and Windows NT Pin
Its due when26-Mar-06 13:36
Its due when26-Mar-06 13:36 
QuestionTread problem Pin
blucas200525-Mar-06 17:35
blucas200525-Mar-06 17:35 
AnswerRe: Tread problem Pin
Dave Kreskowiak26-Mar-06 4:26
mveDave Kreskowiak26-Mar-06 4:26 
Questionget callerid Value by vb.net 2003 Pin
SVb.net25-Mar-06 11:23
SVb.net25-Mar-06 11:23 
AnswerRe: get callerid Value by vb.net 2003 Pin
Recep Tarakci25-Mar-06 19:57
Recep Tarakci25-Mar-06 19:57 
QuestionData Binding an Image to MS Access Pin
JMS7625-Mar-06 9:32
JMS7625-Mar-06 9:32 
AnswerRe: Data Binding an Image to MS Access Pin
Recep Tarakci25-Mar-06 9:46
Recep Tarakci25-Mar-06 9:46 
hi
i am using vb.net 2005 and sql server 2005. i am save image this code ; select picture openfiledialog ;

<br />
<br />
Imports System.Data.SqlClient<br />
Imports System.IO<br />
<br />
 Dim con As New SqlConnection("Data Source=.\sqlexpress;AttachDbFilename=|DataDirectory|\GlobalREST.mdf;Integrated Security=True;User Instance=True")<br />
    Dim da As New SqlDataAdapter("Select * from URUNLER", con)<br />
<br />
da.MissingSchemaAction = MissingSchemaAction.AddWithKey<br />
        Dim MyCB As SqlCommandBuilder = New SqlClient.SqlCommandBuilder(da)<br />
        Dim ds As New DataSet()<br />
<br />
        Dim fs As New FileStream(Me.ButtonEdit1.Text, FileMode.OpenOrCreate, FileAccess.Read)<br />
        Dim MyData(fs.Length) As Byte<br />
        fs.Read(MyData, 0, fs.Length)<br />
        fs.Close()<br />
        con.Open()<br />
        da.Fill(ds, "URUNLER")<br />
        Dim myRow As DataRow<br />
        myRow = ds.Tables("URUNLER").NewRow()<br />
<br />
        myRow("URUNKODU") = TextEdit2.EditValue<br />
        myRow("URUNADI") = TextEdit3.EditValue<br />
        myRow("URUNGRUBU") = "6"<br />
        myRow("FIYAT1") = TextEdit4.EditValue<br />
        myRow("FIYAT2") = TextEdit5.EditValue<br />
        myRow("FIYAT3") = TextEdit6.EditValue<br />
        myRow("FIYAT4") = TextEdit7.EditValue<br />
        myRow("ACIKLAMA") = Me.MemoEdit1.EditValue<br />
        myRow("RESIM") = MyData<br />
<br />
        ds.Tables("URUNLER").Rows.Add(myRow)<br />
        da.Update(ds, "URUNLER")<br />
<br />
        fs = Nothing<br />
        MyCB = Nothing<br />
        ds = Nothing<br />
        da = Nothing<br />
<br />
        con.Close()<br />
        con = Nothing<br />
<br />
<br />


but this code not work Access database. You are save picture file name and file location to access database. and select PictureBox component and expand DataBinding property click Advanced. Select PictureLocation value and select database picture location field.
QuestionGet CallerID value using Visual Basic.NET 2005 Pin
Recep Tarakci25-Mar-06 9:08
Recep Tarakci25-Mar-06 9:08 
QuestionSQL Statemnt problems Pin
LeRoiScorpion25-Mar-06 9:01
LeRoiScorpion25-Mar-06 9:01 
GeneralRe: SQL Statemnt problems Pin
Guffa25-Mar-06 10:22
Guffa25-Mar-06 10:22 
GeneralRe: SQL Statemnt problems Pin
LeRoiScorpion25-Mar-06 18:33
LeRoiScorpion25-Mar-06 18:33 
AnswerRe: SQL Statemnt problems Pin
Guffa25-Mar-06 18:42
Guffa25-Mar-06 18:42 
GeneralRe: SQL Statemnt problems Pin
LeRoiScorpion25-Mar-06 18:48
LeRoiScorpion25-Mar-06 18:48 
AnswerRe: SQL Statemnt problems Pin
Guffa26-Mar-06 3:59
Guffa26-Mar-06 3:59 
QuestionSend Files VIA IP Pin
ADY00725-Mar-06 5:54
ADY00725-Mar-06 5:54 
QuestionDirectSound & Speakers Pin
Superwill25-Mar-06 4:29
Superwill25-Mar-06 4:29 
QuestionAutomatic generation of numbers Pin
Arun Hegde25-Mar-06 2:58
Arun Hegde25-Mar-06 2:58 
AnswerRe: Automatic generation of numbers Pin
Murtuza Husain Miyan Patel25-Mar-06 6:18
professionalMurtuza Husain Miyan Patel25-Mar-06 6:18 
AnswerRe: Automatic generation of numbers Pin
rikky_22225-Mar-06 17:39
rikky_22225-Mar-06 17:39 
AnswerRe: Automatic generation of numbers Pin
Solid Snake26-Mar-06 7:19
Solid Snake26-Mar-06 7:19 
QuestionControl a video projector - which way is best? Pin
yomam25-Mar-06 1:29
yomam25-Mar-06 1:29 
AnswerRe: Control a video projector - which way is best? Pin
Guffa25-Mar-06 20:54
Guffa25-Mar-06 20:54 
GeneralRe: Control a video projector - which way is best? Pin
yomam26-Mar-06 3:28
yomam26-Mar-06 3:28 
Questionhow to give expiry date Pin
furher25-Mar-06 0:20
furher25-Mar-06 0:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.