I am trying to get user input from an input box and add that value to an existing formula. So far, I have been able to get the user input to work but am not sure how to add it to the formula.
So far the existing formula looks like:
What I would like to do is after the last statement of RC[-7]=""1234567890"" I'd like to add the following:
,RC[-7]strnewassembly
Any thoughts/help/ideas would be greatly appreciated, thanks for looking.
-Cody
Code:
Dim strnewassembly As String
strnewassembly = InputBox("Please enter the Assembly Number you would like to add to the " & _
"stryker list.", "Add New Assembly?")
So far the existing formula looks like:
Code:
ActiveCell.FormulaR1C1 = _
"=IF(OR(RC[-7]=""16102088-041"",RC[-7]=""16101752-051"",RC[-7]=""16102030-081"",RC[-7]=""16102200-021"",RC[-7]=""16103880-021"",RC[-7]=""16101860-051"",RC[-7]=""7566394-011"",RC[-7]=""16104847-011"",RC[-7]=""7566394-011SP"",RC[-7]=""16101157-021"",RC[-7]=""7566139-121"",RC[-7]=""7579575-011"",RC[-7]=""16103822-011"",RC[-7]=""16104813-011"",RC[-7]=""16102218-061"",RC[-7]=""7566131-121"",RC[-7]=""16103867-011"",RC[-7]=""16102218-061SP"",RC[-7]=""16102347-011"",RC[-7]=""16102325-011"",RC[-7]=""16102328-011"",RC[-7]=""16103534-021"",RC[-7]=""7566398-011"",RC[-7]=""16101860-051SP"",RC[-7]=""16102360-011"",RC[-7]=""16103344-011"",RC[-7]=""16102372-011"",RC[-7]=""16101087-031"",RC[-7]=""1234567890"")=TRUE,""Stryker"","""")"
What I would like to do is after the last statement of RC[-7]=""1234567890"" I'd like to add the following:
,RC[-7]strnewassembly
Any thoughts/help/ideas would be greatly appreciated, thanks for looking.
-Cody