So i need a way to have values in N column not change if i have an "L" in column L. values in N come from values in G + G*J% so if i change value in G from 2 to 22 it then changes value in corresponding cell in column N. i was thinking if i had some vba code to always copy the value from N to some other column like Q for example (a hidden column) and i could put a if then in column N so if L10="L" then N10=Q10 else SUM(G10+G10*J10%)
what is a simple vba script to copy N values from N10-N125 to Q10-Q125 but then not copy them if L10-L125 = "L" ? i think that would do the trick
Values in N have this going down =SUM(G10+G10*J10%)
[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD="width: 64, align: center"]G[/TD]
[TD="width: 64, align: center"]H[/TD]
[TD="width: 64, align: center"]I[/TD]
[TD="width: 64, align: center"]J[/TD]
[TD="width: 64, align: center"]K[/TD]
[TD="width: 13, align: center"]L[/TD]
[TD="width: 16, align: center"]M[/TD]
[TD="width: 64, align: center"]N[/TD]
[/TR]
[TR]
[TD="align: right"]2[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]11[/TD]
[TD][/TD]
[TD]L[/TD]
[TD][/TD]
[TD="align: right"]2.22[/TD]
[/TR]
[TR]
[TD="align: right"]4[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]12[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]4.48[/TD]
[/TR]
[TR]
[TD="align: right"]5[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]13[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]5.65[/TD]
[/TR]
[TR]
[TD="align: right"]7[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]11[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]7.77[/TD]
[/TR]
[TR]
[TD="align: right"]8[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]12[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]8.96[/TD]
[/TR]
[TR]
[TD="align: right"]9[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]12[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]10.08[/TD]
[/TR]
</tbody>[/TABLE]
what is a simple vba script to copy N values from N10-N125 to Q10-Q125 but then not copy them if L10-L125 = "L" ? i think that would do the trick
Values in N have this going down =SUM(G10+G10*J10%)
[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD="width: 64, align: center"]G[/TD]
[TD="width: 64, align: center"]H[/TD]
[TD="width: 64, align: center"]I[/TD]
[TD="width: 64, align: center"]J[/TD]
[TD="width: 64, align: center"]K[/TD]
[TD="width: 13, align: center"]L[/TD]
[TD="width: 16, align: center"]M[/TD]
[TD="width: 64, align: center"]N[/TD]
[/TR]
[TR]
[TD="align: right"]2[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]11[/TD]
[TD][/TD]
[TD]L[/TD]
[TD][/TD]
[TD="align: right"]2.22[/TD]
[/TR]
[TR]
[TD="align: right"]4[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]12[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]4.48[/TD]
[/TR]
[TR]
[TD="align: right"]5[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]13[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]5.65[/TD]
[/TR]
[TR]
[TD="align: right"]7[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]11[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]7.77[/TD]
[/TR]
[TR]
[TD="align: right"]8[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]12[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]8.96[/TD]
[/TR]
[TR]
[TD="align: right"]9[/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]12[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD="align: right"]10.08[/TD]
[/TR]
</tbody>[/TABLE]