I have an Excel formula I'm having trouble converting into a VBA code.
Thanks for your assistance.Please Login or Register to view this content.
I have an Excel formula I'm having trouble converting into a VBA code.
Thanks for your assistance.Please Login or Register to view this content.
Grumpy9215,
You can use the formula directly with the Evaluate method:
Please Login or Register to view this content.
However, if you want code to repeat the steps the formula is taking, it would look something like this:
Please Login or Register to view this content.
Hope that helps,
~tigeravatar
Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble
Hello Grumpy9215,
This code is untested but should work. However, there is no error handling added to this. Try it out and let me know the results.
Please Login or Register to view this content.
Sincerely,
Leith Ross
Remember To Do the Following....
1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.2. Thank those who have helped you by clicking the Star below the post.3. Please mark your post [SOLVED] if it has been answered satisfactorily.
Old Scottish Proverb...
Luathaid gu deanamh maille! (Rushing causes delays!)
Thank you for your assisatnce.
sorry, thank you
Last edited by palioli; 08-20-2017 at 05:11 AM.
Unfortunately your post does not comply with Rule 2 of our Forum RULES. Do not post a question in the thread of another member -- start your own thread.
If you feel an existing thread is particularly relevant to your need, provide a link to the other thread in your new thread.
Old threads are often only monitored by the original participants. New threads not only open you up to all possible participants again, they typically get faster response, too.
Ali
Enthusiastic self-taught user of MS Excel who's always learning!
Don't forget to say "thank you" in your thread to anyone who has offered you help.
You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.
Forum Rules (updated August 2023): please read them here.
Deleted bcause posted at same moment as Ali.
@ Ali
Can I (or you) remove this post ?
Last edited by bakerman2; 08-20-2017 at 04:42 AM.
Avoid using Select, Selection and Activate in your code. Use With ... End With instead.
You can show your appreciation for those that have helped you by clicking the * at the bottom left of any of their posts.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks