Hi experts,
I am creating a macro to display a list of document numbers based on the transaction code selected from a combo box. The list is displayed on the same sheet (Sheet1).
For each list displayed, there is a button for user to click to view more details. When this button is clicked, the macro should direct user to a new sheet (Sheet2), pointing to the corresponding row that contains the document number. (The new sheet contains all document numbers and their details)
Currently, I am able to direct user to the new sheet (using Sheet2.Activate) but I do not know the way to point to the correct location based on the document number from Sheet1. My guess is to use VLOOKUP.. i tried vlookup(strTrans,Sheet2!A1
:Sheet2!A4
3,1) but it has compile error saying "Expected: list separator or )"
I am using Visual Basic Editor to code. I am a beginner in developing macro. Please help..
Start Free Trial