Hey
How can i create a loop on the following piece of code
I want it to loop through the phone numbers and add them to a table if they dontalready exist. After this is moves on to something else.
Ive been looking into while loops but it only added the first missing value.
Is it possible to continually go through the .csv finding these missing values until no more are found?
Thanks
How can i create a loop on the following piece of code
VB.NET:
If GetDevice.ExecuteNonQuery() > 0 Then
'Already Exists
Else
get = New SqlCommand(InsertString, dataCon)
get = New SqlCommand("INSERT INTO User (No) VALUES ('" & _
No & "')", dataCon)
GetDevice.ExecuteNonQuery()
MsgBox("New Users Have Been Added")
End If
I want it to loop through the phone numbers and add them to a table if they dontalready exist. After this is moves on to something else.
Ive been looking into while loops but it only added the first missing value.
Is it possible to continually go through the .csv finding these missing values until no more are found?
Thanks
Last edited: