Format:
Recent snippets for: mbbrennan
Dim rowIndex As Integer = InvoiceLineItemsDataGridView.Rows.Count - 1 Dim row As DataGridViewRow _ = InvoiceLineItemsDataGridView.Rows(rowIndex) Dim cell As DataGridViewCell cell = row.Cells(0) cell.Value = 1 invoiceSequence += 1 cell = row.Cells(1) cell.Value = invoiceSequence cell = row.Cells(2)
89 Views
no comments
Private Sub btnAdd_Click(ByVal sender As System.Object, _ ByVal e As System.EventArgs) Handles btnAdd.Click ' Check that the line item data is valid If IsValidLineItem() Then ' Add a new row to the InvoiceLineItems table InvoiceLineItemsBindingSource.AddNew() ' Set the values of the row in the data grid
152 Views
no comments
Imports System.Data.SqlClient Public Class PayablesDB Public Shared Function GetConnection() As SqlConnection Dim connectionString As String _ = "Data Source=localhost\SqlExpress;Initial Catalog=Payables;" _ & "Integrated Security=True" Return New SqlConnection(connectionString) End Function
151 Views
no comments
Imports System.Data.SqlClient Public Class VendorDB Public Shared Function GetVendors() As List(Of Vendor) Dim vendorList As New List(Of Vendor) Dim connection As SqlConnection = PayablesDB.GetConnection Dim selectStatement As String _ = "SELECT * FROM Vendors " Dim selectCommand As New SqlCommand(selectStatement, connection)
124 Views
no comments
Subscribe
Discuss
What's new
What is it
New Snippet
Recent Snippets
My Snippets
Web Code
Search
