adityavostro
New Member
- Joined
- Feb 21, 2018
- Messages
- 3
Option Explicit
Private Sub CommandButton1_Click()
Dim mynumber1 As Double
mynumber1 = mynumber1textbox.Text
Dim myrange As Range
Set myrange = ActiveCell 'currently does not support user input for a particular cell
myrange = "Table of " & mynumber1
Dim mymoverate As Single
mymoverate = mymoverate1textbox.Text
Dim mynumber2 As Double
mynumber2 = mynumber2textbox.Text
Dim myvariable1 As Single
myvariable1 = 1
Dim myloopvariable As Integer
myloopvariable = 1
Dim mytestvariable1 As Single
Do While myvariable1 <= mynumber2 'currently does not support anylysation of errorfree mynumber2
myrange.Offset(myloopvariable, 0).Value = mynumber1 & " X " & myvariable1 & " = " & mynumber1 * myvariable1
myrange.Offset(myloopvariable, 0).Columns.AutoFit
myvariable1 = (myvariable1 + 0.1) 'mymoverate
mytestvariable1 = myvariable1
'If mytestvariable1 = 2.1 Then GoTo jmp
'If mytestvariable1 = 2.2 Then GoTo jmp
myloopvariable = myloopvariable + 1
Loop
Unload Me
jmp:
End Sub
Private Sub CommandButton1_Click()
Dim mynumber1 As Double
mynumber1 = mynumber1textbox.Text
Dim myrange As Range
Set myrange = ActiveCell 'currently does not support user input for a particular cell
myrange = "Table of " & mynumber1
Dim mymoverate As Single
mymoverate = mymoverate1textbox.Text
Dim mynumber2 As Double
mynumber2 = mynumber2textbox.Text
Dim myvariable1 As Single
myvariable1 = 1
Dim myloopvariable As Integer
myloopvariable = 1
Dim mytestvariable1 As Single
Do While myvariable1 <= mynumber2 'currently does not support anylysation of errorfree mynumber2
myrange.Offset(myloopvariable, 0).Value = mynumber1 & " X " & myvariable1 & " = " & mynumber1 * myvariable1
myrange.Offset(myloopvariable, 0).Columns.AutoFit
myvariable1 = (myvariable1 + 0.1) 'mymoverate
mytestvariable1 = myvariable1
'If mytestvariable1 = 2.1 Then GoTo jmp
'If mytestvariable1 = 2.2 Then GoTo jmp
myloopvariable = myloopvariable + 1
Loop
Unload Me
jmp:
End Sub