Move Cursor to Specific Cell in Other Worksheet

I put a value in "Sheet1" cell "J2". On running the macro I want cursor to move to "Sheet2" Column "B" and row number as per value put in "Sheet1" cell "J2". Please suggest vba code for the same. Thanx

0

1 Answer

Sub moveToCell()
    Dim intRow As Integer

    intRow = Sheet1.Range("J2").Value

    Sheet2.Activate
    Sheet2.Range("B" & intRow).Select
End Sub
4

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Sarah Jenkins

Sarah Jenkins

Senior Technology Editor & AI Specialist

Sarah Jenkins is a veteran tech journalist with over 12 years of experience covering artificial intelligence, mobile innovations, and digital ethics. Her insights have appeared in leading technology publications worldwide.

Share this article
Twitter Facebook Pinterest