I need a macro that will take the numbers in column D and remove the first 2 zeros and the last 3 characters and return value in cell C.
Office 365.
I need a macro that will take the numbers in column D and remove the first 2 zeros and the last 3 characters and return value in cell C.
Office 365.
Last edited by myerays; 08-01-2021 at 10:00 AM. Reason: Office Version
Could be done with a formula:
=TEXT(MID(D7,3,10),"0000000000")
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. It's a universal courtesy.
You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.
NB: as a Moderator, I never accept friendship requests.
Forum Rules (updated August 2023): please read them here.
OrFormula:Please Login or Register to view this content.
Last edited by Pepe Le Mokko; 08-01-2021 at 10:19 AM.
Please update your forum profile from 2016.Office 365.
Thank you for your input
I want a macro not a formula I know this will work but I would like a macro that would loop through d column and return the result into column C
No worries, but please update your profile as requested.
What is the difference between a macro returning results in column C and a formula returning the same results? You do know that you can drag copy the formula down, don't you?
Yes I do, But my friend that uses the same sheet is not excel savy so I need to smart it up so it will be dumbed down so to speak.
Fair enough.
Thank you so much.
Last edited by AliGW; 08-01-2021 at 10:49 AM. Reason: PLEASE don't quote unnecessarily!
You should not PM members pestering for help - don't do that again.
Post your code here for one of our VBA experts to look at.
Thank you so much I appreciate that so I will not do it again.
Post the code you sent to me here.
This is the macro that I have, it removes the last 3 characters and I would like it to remove the first 2 characters as well and return the value in column C and leave the original value in column D. Any help would be appreciated.
Please Login or Register to view this content.
Did I do it right.
Yes.
Administrative Note:
It is the weekend. Please remember that those who help here do so voluntarily and of their own goodwill. They live in many different time zones and many will be out at work right now if they are not asleep on the other side of the globe. Please do not try to put pressure of time on anyone here: if you get the help you need today, that's fine, but you really should not count on it. Thanks for your understanding and patience.
Thank you for your direction and help. I work a lot as well and this is the only day I have off. I love using excel, I have always said if you think it, it can be done. My problem is I a beginner when it comes to VBA I had some macros that worked in MS 16 but when it changed to MS 365 new VBA they stopped working.
So I really do appreciate any help anyone gives me. Thank you so much.
Last edited by AliGW; 08-01-2021 at 11:24 AM. Reason: PLEASE don't quote unnecessarily!
Maybe :
Please Login or Register to view this content.
1. I care dog
2. I am a loop maniac
3. Forum rules link : Click here
3.33. Don't forget to mark the thread as solved, this is important
Thank you as it works and replaces the cell value, How can I make it put the value in the cell before it and leave the original value in the original cell?
Thank you so much
Last edited by AliGW; 08-01-2021 at 11:51 AM. Reason: PLEASE stop quoting unnecessarily!
You are welcome.
Add the .offset(, -1) part to the code :
Please Login or Register to view this content.
Works great Thank you
Last edited by AliGW; 08-01-2021 at 12:02 PM. Reason: PLEASE stop quoting unnecessarily!
If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.
Also, you may not be aware that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of those who helped.
Administrative Note:
Please don't quote whole posts, especially when you are responding to the one immediately preceding your own - it's just clutter. It's OK to quote if you are responding to a post out of sequence, but limit quoted content to a few relevant lines that makes clear to whom and what you are responding. Thanks!
For normal conversational replies, try using the QUICK REPLY box below or the REPLY button instead of REPLY WITH QUOTE.
You are welcome, glad to help.
Regards
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks