I have an Excel table connected to an SAP program, and all the data comes from there. I need to add 3 new rows to the table without changing much in the VBA code. For example, I don’t want to manually update every line like Cells(13,1).Value = StrMat
to Cells(16,1).Value = StrMat
just because of the new rows.
Is there an easier way to do this? I have over 10 modules and 2000 lines of code, and manually updating every row after 13 and add 2 to it would be a lot of work.
I added manually 2 rows to check but when i run the code, data from the old rows go to the new empty rows and i don't want that.
So let me rephrase it, i added 2 Rows 18 and 19.Behind the rows from 20 to 30 i got some modules and Functions, the Functions are changed automatically from what i have read. but the code in Modules for example
Worksheet.Cells(1, 18).value = 170
i have to change it to
Worksheet.Cells(1,20).value = 170
because the 18th row now is the new empty row.
Is there any other way to automate all the Worksheet.Cells changes for all the rows below 18?