J
Joe K.
I have several if statements listed below, that correspond to the string
values in the "B" column. If the .Cells(iRow, "B").Text= "BASE" then
prodcode = "0003408909". Please help me add the prodcode string to the
myStr string listed below.
Please help me modify the code listed below to add the prodcode to the myStr
string listed below.
Thanks so much for the help.
Dim prodcode As String
Dim myStr As String
Dim wks As Worksheet
With wks
FirstRow = 1
FirstCol = 3
For iRow = FirstRow + 1 To 6
If .Cells(iRow, "B").Text = "BASE" Then
prodcode = "0003408909"
ElseIf .Cells(iRow, "B").Text = "TEAM" Then
prodcode = "0003498909"
ElseIf .Cells(iRow, "B").Text = "COURSE" Then
prodcode = "0003407909"
End If
For iCol = FirstCol + 1 To 64
myStr = .Cells(1, iCol).Text & "," _
& prodcode & "," _
& .Cells(iRow, iCol).Text
Print #1, myStr
Next iCol
Next iRow
End With
values in the "B" column. If the .Cells(iRow, "B").Text= "BASE" then
prodcode = "0003408909". Please help me add the prodcode string to the
myStr string listed below.
Please help me modify the code listed below to add the prodcode to the myStr
string listed below.
Thanks so much for the help.
Dim prodcode As String
Dim myStr As String
Dim wks As Worksheet
With wks
FirstRow = 1
FirstCol = 3
For iRow = FirstRow + 1 To 6
If .Cells(iRow, "B").Text = "BASE" Then
prodcode = "0003408909"
ElseIf .Cells(iRow, "B").Text = "TEAM" Then
prodcode = "0003498909"
ElseIf .Cells(iRow, "B").Text = "COURSE" Then
prodcode = "0003407909"
End If
For iCol = FirstCol + 1 To 64
myStr = .Cells(1, iCol).Text & "," _
& prodcode & "," _
& .Cells(iRow, iCol).Text
Print #1, myStr
Next iCol
Next iRow
End With