mark molloy
New Member
Hello,
Apologies if my wording is not entitely correct I am new and still finding my way around.
The issue that I have is that I have an excel spreadsheet with a formula in cells J2:J25 and is populated when a user inputs data into cells A2:25. Rather than update each time data is added I would like the user to be able to click on a macro button once all data is added and then hey presto the results appear.
From looking around the site I beleive this is done via a Worksheet_Change section in the code but as I have just started coding I am struggling as to where it comes in - here is what I have so far.
PrivateSub CommandButton1_click()
Range("J2:J25").Formula = IF(ISBLANK($A2),"",VLOOKUP($G$1&$A2,'account mapping'! $E:$H,4,FALSE))
End Sub
Private Sub Worksheet_Change(ByVal Target As Range)
???? Not sure what needs to go here ????
Again apologies if this is way off the mark or very vague I hope to get better!
If anyone can point me in the right direction (video/article/previous post) or offer any advice I would be most grateful
Thanks
Mark.
Apologies if my wording is not entitely correct I am new and still finding my way around.
The issue that I have is that I have an excel spreadsheet with a formula in cells J2:J25 and is populated when a user inputs data into cells A2:25. Rather than update each time data is added I would like the user to be able to click on a macro button once all data is added and then hey presto the results appear.
From looking around the site I beleive this is done via a Worksheet_Change section in the code but as I have just started coding I am struggling as to where it comes in - here is what I have so far.
PrivateSub CommandButton1_click()
Range("J2:J25").Formula = IF(ISBLANK($A2),"",VLOOKUP($G$1&$A2,'account mapping'! $E:$H,4,FALSE))
End Sub
Private Sub Worksheet_Change(ByVal Target As Range)
???? Not sure what needs to go here ????
Again apologies if this is way off the mark or very vague I hope to get better!
If anyone can point me in the right direction (video/article/previous post) or offer any advice I would be most grateful
Thanks
Mark.