Home
Forums
New posts
Search forums
Articles
Latest reviews
Search resources
Members
Current visitors
Newsgroups
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Home
Forums
Newsgroups
Microsoft Excel
Microsoft Excel Programming
For Each Cell in Sheet1 Range, do some Vlookup calc. from Sheet3
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
[QUOTE="u473, post: 12115492"] I need help in switching back & forth from sheet to sheet and using VlookUp & Match to retrieve values at the intersect of current Row & Column. .. For Each Cell in Sheet1 Range, do some Vlookup calculations from Sheet3 and write results in Sheet2 same relative range. Assume Range in Sheet1 is B2:D3 as follows : Row / Col A B C D 1 Position RateA RateB RateC .... 2 Manager 10 8 12 3 Cost Engr. 6 16 6 4 .............. .. .. .. Assume RateTable in Sheet3 is B2:D.. as follows : Row / Col A B C D 1 Position RateA RateB RateC .... 2 Manager 50 55 60 3 Cost Engr. 35 40 45 4 .............. .. .. .. For each Cell in Sheet1 range which contains Hours at specific Rate Code, Vlookup/Match RateTable in Sheet3 for pertaining Position, and write Hours multiplied by Rate in Sheet2 in same relative position as in Sheet1 as follows : Row / Col A B C D 1 Position RateA RateB RateC .... 2 Manager 500 440 720 3 Cost Engr. 210 640 270 ------ Pseudo Code ------------------------ Sub Test() Dim rng As Range Dim RateCat As String ' Rate Category, RateA, RateB, RateC etc... Dim Rate As Integer : Dim LastRow as Integer Dim Position as String LastRow = Cells(Rows.Count,"A").End(xlUp).Row Set rng = Range("B2:D" & LastRow): Range("B2").Select For Each Cell In rng 'Vlookup/Match Position and RateCat from Sheet3 and store value in Rate ' Multiply Sheet1.ActiveCell.Value with Rate and store result in Sheet3, 'same relative Row/Column ActiveCell.Offset(0, 1).Select Next Cell End Sub Help appreciated, Celeste [/QUOTE]
Verification
Post reply
Home
Forums
Newsgroups
Microsoft Excel
Microsoft Excel Programming
For Each Cell in Sheet1 Range, do some Vlookup calc. from Sheet3
Top