0

How to update value from xt to xtt in 6th column, first row.

1    2    3   4    5  6

x    xx  xy   xz   x1 xt

y    yx  tt   cc  z3  xcc

Based on above data, I am getting range from worksheet. After getting the Row object, how do I update the Cell value in particular column?

1 Answer 1

1

As asked, you can update a specific column using the method:

'Sheet.Cells(row, column) = value
' i.e.
ActiveSheet.Cells(1, 6) = "xtt"

If you only want to perform the update if it has a value of "xt", then obviously you'd need to check the contents before performing the update... For example:

If (ActiveSheet.Cells(1, 6) = "xt") Then
    ActiveSheet.Cells(1, 6) = "xtt"
End If
Sign up to request clarification or add additional context in comments.

1 Comment

:I updated my question,After getting row object.I want to update cell value

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.