Hi,
I am very new to programming in VBA for excel. I have created a working piece of code that looks up a value in a different sheet using Vlookup and then places that value into a comment box, and lastly resizes the comment box to fit the text.
This allows the comment to be shown while the mouse is hovering over the cell for quick reference.
The code also erases the comment when the information in the cell is erased or a piece of text is used in place of a number in the cell, and places a pop-up when a number value is not on the lookup list. This is because the column that I am searching in is all numbers, and if someone is placing a letter in the cell, then the user has not defined the project number yet, so it is okay as a place holder till a project number is assigned, but I want to warn the user if they place a number that is not on the list.
The code also tries to capture as much error checking as possible.
Since I am new to VBA, I would appreciate some feedback on how to optimize this code (ie. run faster, smoother, eliminate other possible errors, etc...).
Thanks for the feedback in advance.
Code:
Please Login or Register to view this content.
Bookmarks