User Profile
Collapse
-
Does not work...In VB .net Autoincrement is read only...that code works for VBA...But not VB .net -
The GDI(Get Dog Info) Sub
Public Sub GDI(ByVal DN As String)
If DN = "" Then
Exit Sub
End If
strSQL = " SELECT * FROM Dogs WHERE [Name] " & " Like '%" & DN & "%'"
'//
Try
Cmd = New OleDbCommand
If Conn.State = ConnectionState .Closed Then Conn.Open()
Cmd.Connection...Leave a comment:
-
Actually Int(Rnd() * 70 + 1) produces numbers 1 thru 70
Int(Rnd() * 71) produces numbers 0 thru 70
the first one is 70 numbers starting at 1
the second one is 71 numbers starting at 0
0 is counted as a number so you have 71 possibilities
I could have edited the first post but thought this added post would help explain how the rnd function works
also instead of cstr(num1)...Leave a comment:
-
Private Function Roll1() As Integer
Randomize()
Return Int(Rnd() * 11)
End FunctionLeave a comment:
-
Private Sub Button1_Click(s ender As Object, e As EventArgs) Handles Button1.Click
Randomize()
Dim num1 As Integer
Dim num2 As Integer
Dim num3 As Integer
Dim num4 As Integer
Dim num5 As Integer
num1 = Int(Rnd() * 70 + 1)
num2 = Int(Rnd() * 70 + 1)
num3 = Int(Rnd() * 70 + 1)
num4 = Int(Rnd() * 70 + 1)...Leave a comment:
No activity results to display
Show More
Leave a comment: