Start New Discussion within our Software Development Community

Thanks for the help. I have a workbook with VB code in it to add a new line. When I add a new line, the new cells automatically have their respective formulas in it. I also have it set so another worksheet with the same table adds a line. In the second worsheet, I want text from the first worksheet inserted into the cells of the second worksheet. Here is the line that is giving me problems in my code. Everything is defined correctly. I think it is just a syntax error.

[roomM = "=IF(ISBLANK('Air Balance (e)'!$A" & newrow & "),"" "",'Air Balance (e)'!A" & newrow & " "
Cells(newrow, 1).Formula = roomM]

"newrow" is an integer. It defines the row number of where you inserted the new row. "Air Balance (e)" is the first worksheet. So, if cell (A,newrow) in Air Balance (e) is blank, then display nothing. Otherwise, display cell (A, newrow) from worksheet Air Balance (e).

Never mind. I was missing a ) in the first line at the end. I've been staring at this too long.

This question has already been answered. Start a new discussion instead.