Нужен совет о том, как очистить этот код, чтобы его было легче читать, и он стал более адаптируемым, если мне нужно увеличить количество строк.В частности, как сообщить коду, какие ячейки выбрать и какие значения найти в каждой ячейке.
qWordCount = WorksheetFunction.Sum(Worksheets("Words").Range("B:B"))
Cells(2, 5) = "Hyphens"
Cells(2, 6) = tHyphenCount
Cells(2, 7) = Round(qWordCount / tHyphenCount, 2)
Cells(3, 5) = "Brackets"
Cells(3, 6) = rBracketCount / 2
Cells(3, 7) = Round(qWordCount / (rBracketCount / 2), 2)
Cells(4, 5) = "Quotation Marks"
Cells(4, 6) = vQuotationMarkCount
Cells(4, 7) = Round(qWordCount / vQuotationMarkCount, 2)
Cells(5, 5) = "Full Stops"
Cells(5, 6) = zFullStopCount
Cells(5, 7) = Round(qWordCount / zFullStopCount, 2)
Cells(6, 5) = "Question Marks"
Cells(6, 6) = yQuestionMarkCount
Cells(6, 7) = Round(qWordCount / yQuestionMarkCount, 2)
Cells(7, 5) = "Colons"
Cells(7, 6) = xColonCount
Cells(7, 7) = Round(qWordCount / xColonCount, 2)
Cells(8, 5) = "Commas"
Cells(8, 6) = wCommaCount
Cells(8, 7) = Round(qWordCount / wCommaCount, 2)
Cells(9, 5) = "Semicolons"
Cells(9, 6) = uSemiColonCount
Cells(9, 7) = Round(qWordCount / uSemiColonCount, 2)
Cells(10, 5) = "Exclamation Marks"
Cells(10, 6) = sExclamationMarkCount
Cells(10, 7) = Round(qWordCount / sExclamationMarkCount, 2)
Cells(11, 5) = "Word Count"
Cells(11, 6) = qWordCount