MS SQL Veri tabanlı Kargo Takip Programı — VB.NET
Not : Mssql (2012) veri tabanı backup dosyası projenin içinde mevcuttur.
Ms sql veri tabanının nasıl geri yüklendiğini (Restore) videolu olarak izlemek için Tıklayınız.
Ms sql veri tabanının nasıl yedeklendiğini (Backup) videolu olarak izlemek için Tıklayınız.
FORM1 İçerisine Yazılacak Kodlar…
[code language=”vb”]
Imports System.Data.SqlClient
Public Class Form1
Public bag As New SqlConnection("Data Source=.\SQLEXPRESS;Initial Catalog=Data;Integrated Security=True")
Public kmt As New SqlCommand
Public adtr As New SqlDataAdapter ‘www.gorselprogramlama.com
Public dtst As New DataSet()
Public Sub listelesene()
bag.Open()
Dim adtr As New SqlDataAdapter("Select * From Musbil", bag)
adtr.Fill(dtst, "Musbil")
Form2.dataView1.Table = dtst.Tables(0)
Form2.dataGrid1.DataSource = Form2.dataView1
adtr.Dispose()
bag.Close()
End Sub
Public Sub listelesene2()
bag.Open()
Dim adtr As New SqlDataAdapter("Select * From yetkili", bag)
adtr.Fill(dtst, "yetkili")
Form3.dataView1.Table = dtst.Tables(1)
Form3.dataGrid1.DataSource = Form3.dataView1
adtr.Dispose()
bag.Close()
End Sub ‘www.gorselprogramlama.com
Public Sub listelesene3()
bag.Open()
Dim adtr As New SqlDataAdapter("Select * From Fiyat", bag)
adtr.Fill(dtst, "Fiyat")
Form4.dataView1.Table = dtst.Tables(2)
Form4.dataGrid1.DataSource = Form4.dataView1
adtr.Dispose()
bag.Close()
End Sub
Private Sub button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button1.Click
Form2.ShowDialog()
End Sub
Private Sub button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button2.Click
Form5.ShowDialog()
End Sub ‘www.gorselprogramlama.com
Private Sub button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button3.Click
Close()
End Sub
End Class
[/code]
FORM2 İçerisine Yazılacak Kodlar…
[code language=”vb”]
Public Class Form2
Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Form1.listelesene()
‘www.gorselprogramlama.com
End Sub
Private Sub button11_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button11.Click
Close()
End Sub
Private Sub button10_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button10.Click
If textBox1.Text <> "" AndAlso textBox4.Text <> "" AndAlso textBox5.Text <> "" Then
Form1.bag.Open()
Form1.kmt.Connection = Form1.bag
Form1.kmt.CommandText = (((((((("INSERT INTO musbil(MüsteriNo,Ad,Soyad,TcKimlik,SeriNo,Ceptel,Evtel,Email,Adres) VALUES (‘" + textBox1.Text & "’,’") + textBox2.Text & "’,’") + textBox3.Text & "’,’") + textBox4.Text & "’,’") + textBox5.Text & "’,’") + textBox6.Text & "’,’") + textBox7.Text & "’,’") + textBox8.Text & "’,’") + textBox9.Text & "’) "
Form1.kmt.ExecuteNonQuery()
Form1.kmt.Dispose()
Form1.bag.Close()
Form1.dtst.Clear()
textBox1.Clear()
textBox2.Clear()
textBox3.Clear()
textBox4.Clear()
textBox5.Clear()
textBox6.Clear()
textBox7.Clear() ‘www.gorselprogramlama.com
textBox8.Clear()
textBox9.Clear()
Form1.listelesene()
MessageBox.Show("Kayıt işlemi tamamlandı ! ")
Else
MessageBox.Show("Boş alanları doldurunuz !!!")
End If
End Sub
Private Sub button12_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button12.Click
Form3.Show()
Me.Hide()
End Sub
Private Sub button13_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button13.Click
If textBox1.Text <> "" Then
Dim cevap As DialogResult
cevap = MessageBox.Show("Kaydı silmek istediğinizden eminmisiniz", "Uyarı", MessageBoxButtons.YesNo, MessageBoxIcon.Question)
If cevap = DialogResult.Yes Then
Form1.bag.Open()
Form1.kmt.Connection = Form1.bag
Form1.kmt.CommandText = "DELETE from Musbil WHERE MüsteriNo=’" + textBox1.Text & "’"
Form1.kmt.ExecuteNonQuery()
Form1.kmt.Dispose()
Form1.bag.Close() ‘www.gorselprogramlama.com
Form1.dtst.Clear()
Form1.listelesene()
End If
Else
MessageBox.Show("Müşteri No’yu giriniz")
End If
End Sub
End Class
[/code]
Bu ve benzeri takip programlar veya bu programa artı özellikler ekletmek istiyorsanız gorselprogram@gmail.com adresine mail atın.
FORM3 İçerisine Yazılacak Kodlar…
[code language=”vb”]
Public Class Form3
Private Sub Form3_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Form1.dtst.Clear()
Form1.listelesene2()
End Sub
Private Sub button8_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button8.Click
Form4.Show()
Me.Hide()
End Sub
Private Sub button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button7.Click
Close()
End Sub
Private Sub button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button6.Click
If textBox1.Text <> "" Then
Form1.bag.Open()
Form1.kmt.Connection = Form1.bag
Form1.kmt.CommandText = (((("INSERT INTO yetkili(YetkiliKisi,ArizaTespiti,ArizaHakkindaBilgi,OnarilmasiicinKullanilanMalzeme,Yapilanislemler) VALUES (‘" + textBox1.Text & "’,’") + textBox2.Text & "’,’") + textBox3.Text & "’,’") + textBox4.Text & "’,’") + textBox5.Text & "’) "
Form1.kmt.ExecuteNonQuery()
Form1.kmt.Dispose()
Form1.bag.Close() ‘www.gorselprogramlama.com
Form1.dtst.Clear()
textBox1.Clear()
textBox2.Clear()
textBox3.Clear()
textBox4.Clear()
textBox5.Clear()
Form1.listelesene2()
MessageBox.Show("Kayıt işlemi tamamlandı ! ")
Else
MessageBox.Show("Boş alanları doldurunuz !!!")
End If
End Sub
End Class
[/code]
Bu ve benzeri takip programlar veya bu programa artı özellikler ekletmek istiyorsanız gorselprogram@gmail.com adresine mail atın.
FORM4 İçerisine Yazılacak Kodlar…
[code language=”vb”]
Public Class Form4
Private Sub Form4_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Form1.listelesene3()
End Sub
Private Sub button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button7.Click
Close() ‘www.gorselprogramlama.com
End Sub
Private Sub button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button6.Click
Dim bfiyat As Double, kdv As Double, indirim As Double, tutar As Double
bfiyat = Double.Parse(textBox2.Text)
kdv = Double.Parse(textBox3.Text)
indirim = Double.Parse(textBox4.Text)
tutar = bfiyat + (bfiyat * (kdv / 100)) – (bfiyat * (indirim / 100))
textBox5.Text = tutar.ToString()
Form1.bag.Open()
Form1.kmt.Connection = Form1.bag
Form1.kmt.CommandText = (((("INSERT INTO Fiyat(KullanilanMalzemeler,BirimFiyat,Kdv,indirim,Tutar) VALUES (‘" + textBox1.Text & "’,’") + textBox2.Text & "’,’") + textBox3.Text & "’,’") + textBox4.Text & "’,’") + textBox5.Text & "’) "
Form1.kmt.ExecuteNonQuery()
Form1.kmt.Dispose()
Form1.bag.Close()
textBox2.Text = "0"
textBox3.Text = "0" ‘www.gorselprogramlama.com
textBox4.Text = "0"
Form1.dtst.Clear()
Form1.listelesene3()
MessageBox.Show("Kayıt işlemi tamamlandı ! ")
End Sub
End Class
[/code]
Bu ve benzeri takip programlar veya bu programa artı özellikler ekletmek istiyorsanız gorselprogram@gmail.com adresine mail atın.
FORM5 İçerisine Yazılacak Kodlar…
[code language=”vb”]
Public Class Form5
Private Sub button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button2.Click
Form2.Show()
Me.Hide()
End Sub
Private Sub Form5_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
End Sub
Private Sub button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button1.Click
Form3.Show()
Me.Hide()
End Sub
End Class
[/code]
Bu ve benzeri takip programlar veya bu programa artı özellikler ekletmek istiyorsanız gorselprogram@gmail.com adresine mail atın.





merhaba hocam bi sorum olacakti mysql 2012de yapilmişya ? bunu mysql 2008’e backup yapabilirmiyiz.
hakan ünel :
malesef olmaz.Veri tabanını sıfırdan yapmalısınız.
proje ve veritabanin indirme linkini bulamadım hocam?
hocam buldum sorry 🙂 🙂