struggling with If's that are inside a Do Until loop, can you have many IF's inside a do until loop?
I'm having problems with the If ouc = "JF......... ifs
Not sure how to write
I have
smiler44
I'm having problems with the If ouc = "JF......... ifs
Not sure how to write
Code:
[/FONT]
[FONT=Arial]if ouc = "JFB" then [/FONT]
[FONT=Arial]Sheets("VP_Data").Select [/FONT]
[FONT=Arial]Sheets("VP_Data").Range("B13").Select[/FONT]
I have
Code:
[FONT=Arial]Do Until IsEmpty(ActiveCell.Value) = True[/FONT]
[FONT=Arial] If ActiveCell.Text = " " Then[/FONT]
[FONT=Arial] MsgBox ("blank")[/FONT]
[FONT=Arial] Exit Sub[/FONT]
[FONT=Arial] Else[/FONT]
[FONT=Arial] If ActiveCell.Text <> " " Then[/FONT]
[FONT=Arial] Dim ouc As String[/FONT]
[FONT=Arial] Dim nunb As String[/FONT]
[FONT=Arial] Dim actsel As String 'activecell[/FONT]
[FONT=Arial] [/FONT]
[FONT=Arial] ouc = ActiveCell.Text[/FONT]
[FONT=Arial] actsell = ActiveCell.Address[/FONT]
[FONT=Arial] [/FONT]
[FONT=Arial] MsgBox (ouc)[/FONT]
[FONT=Arial] ActiveCell.Offset(0, 5).Activate[/FONT]
[FONT=Arial] [/FONT][FONT=Arial] nunb = ActiveCell.Text[/FONT]
[FONT=Arial] MsgBox (nunb)[/FONT]
[FONT=Arial] If ouc = "JFB" Then Sheets("VP_Data").Select ' Sheets("VP_Data").Range("B13").Select[/FONT]
[FONT=Arial] [/FONT][FONT=Arial] [/FONT]
[FONT=Arial] If ouc = "JFC" Then Sheets("VP_Data").Select[/FONT]
[FONT=Arial] Sheets("VP_Data").Range("C13").Select [/FONT][FONT=Arial] [/FONT]
[FONT=Arial] If ouc = "jfd" Then Sheets("VP_Data").Select[/FONT]
[FONT=Arial] [/FONT][FONT=Arial] Sheets("promotions").Select[/FONT]
[FONT=Arial] Sheets("promotions").Range(actsell).Select[/FONT]
[FONT=Arial] ActiveCell.Offset(1, 0).Activate[/FONT]
[FONT=Arial] MsgBox ("there")[/FONT]
[FONT=Arial] End If[/FONT]
[FONT=Arial] End If[/FONT]
[FONT=Arial] Loop[/FONT]
[FONT=Arial] End Sub[/FONT]
smiler44