Solved Data copied to the DB via a list box (1 Viewer)

Martyh

Registered User.
Local time
Today, 10:49
Joined
May 2, 2000
Messages
192
Hi Guys,

When the data is copied to the DB via a list box from an "external source" by using ctrl-C/V, how would I count the number of pieces of data that were imported to the db?

In the example, there are only 3 pieces of data, but in reality 300-400 are sometimes transferred. The amount would be used as a double check, because we know the amount in the external source, we just want to verify the amount going in.

Thanks,

Capture.JPG


Marty
 

theDBguy

I’m here to help
Staff member
Local time
Today, 07:49
Joined
Oct 29, 2018
Messages
21,358
Hi. How exactly are you using Ctrl-c/v?
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 22:49
Joined
May 7, 2009
Messages
19,169
is that a Listbox or a Textbox?
if textbox you can use it's Change Event to get the number

Code:
Private Sub txtNSN_Change()
    Dim var As Variant
    var = Split(Me.txtNSN.Text, vbNewLine)
    MsgBox UBound(var) + 1
End Sub
 

Users who are viewing this thread

Top Bottom