Sub ParseSpecList() Dim myTable As New cbot_dbDataSetTableAdapters.SpecsTableAdapter Dim strSpec As String Dim myText As String() myText = Clipboard.GetText.Split(Environment.NewLine) For Each item As String In myText strSpec = item.Trim If strSpec <> "" Then Try myTable.InsertQuerySpec(strSpec, False) Catch ex As System.Data.SqlServerCe.SqlCeException 'skip add Catch ex As Exception ' Show the exception's message. MessageBox.Show(ex.Message) Debug.Print(ex.Message) ' Show the stack trace, which is a list of methods ' that are currently executing. MessageBox.Show("Stack Trace: " & vbCrLf & ex.StackTrace) End Try End If Next item End Sub
InsertQuerySpec
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)