Hello
I am a beginner in VBA world. Well, you can tell this by looking at my code.
I highly appreciate any help regarding this. Thanks in advance for the help.
I am trying to run the code below and it gives an error (This is the error “Loop without Do”)
Sub FirstProgram()
Dim A As Date
Dim B As Integer
Dim i As Integer
Do While i = 5
A = Ai
B = Weekday(A)
If 1 < B < 7 Then
Ji = Fi
i = i + 1
Loop Until i = 428
End Sub
I wanted to check the Value of “A” column (A contains dates) and if it is a weekday I wanted to copy the contents of F column to J column. I also want one more check before copying the Value from F to J column. I think I will do this later. Can anyone tell me why the above code is not working? Please don’t write the code for me. Please let me know what I am missing. Also keep in mind that I am new to this and this is my first program. This might be simple using the Excel functions and commands, but I wanted do this by writing a code.
Thanks in Advance
Infuse
I am a beginner in VBA world. Well, you can tell this by looking at my code.
I highly appreciate any help regarding this. Thanks in advance for the help.
I am trying to run the code below and it gives an error (This is the error “Loop without Do”)
Sub FirstProgram()
Dim A As Date
Dim B As Integer
Dim i As Integer
Do While i = 5
A = Ai
B = Weekday(A)
If 1 < B < 7 Then
Ji = Fi
i = i + 1
Loop Until i = 428
End Sub
I wanted to check the Value of “A” column (A contains dates) and if it is a weekday I wanted to copy the contents of F column to J column. I also want one more check before copying the Value from F to J column. I think I will do this later. Can anyone tell me why the above code is not working? Please don’t write the code for me. Please let me know what I am missing. Also keep in mind that I am new to this and this is my first program. This might be simple using the Excel functions and commands, but I wanted do this by writing a code.
Thanks in Advance
Infuse