+ Reply to Thread
Results 1 to 11 of 11

If Decimal Found then move the data from after decimal to before decimal

  1. #1
    Forum Contributor
    Join Date
    07-16-2009
    Location
    NA
    MS-Off Ver
    MS Excel 2010
    Posts
    237

    If Decimal Found then move the data from after decimal to before decimal

    Hi Experts,

    I am looking for a macro that will do the the things mentioned below
    Macro will be placed in a macro.xlsm
    macro.xlsm & 1.xls both are located in different path so the path should be hardcoded in the macro, so i can change it as per my needs


    In column K, If after decimal if the second digit is 0 then Move all the data from after decimals to before decimals
    K2 has data that has the second number after decimal is 0, so the output would be in K2 10030.00


    Thnx For the Help
    https://excelfox.com/forum/showthrea...4821#post14821
    Attached Files Attached Files
    Last edited by Zaeguzah; 08-26-2020 at 10:30 AM.

  2. #2
    Banned User!
    Join Date
    02-06-2020
    Location
    Iowa City, IA, USA
    MS-Off Ver
    2016 - 365 / 2007
    Posts
    2,014

    Re: If Decimal Found then move the data from after decimal to before decimal

    more than likely, no one will do it for you. although many people here do post code. what is the other link? verbatim to this? are you both users? hmmm....

  3. #3
    Forum Contributor
    Join Date
    07-16-2009
    Location
    NA
    MS-Off Ver
    MS Excel 2010
    Posts
    237

    Re: If Decimal Found then move the data from after decimal to before decimal

    I posted this question, in another forum also so i shared the link

  4. #4
    Banned User!
    Join Date
    02-06-2020
    Location
    Iowa City, IA, USA
    MS-Off Ver
    2016 - 365 / 2007
    Posts
    2,014

    Re: If Decimal Found then move the data from after decimal to before decimal

    using 2 usernames is probably not going to go over well.

  5. #5
    Spammer
    Join Date
    06-09-2014
    Location
    https://t.me/pump_upp
    MS-Off Ver
    Microst Office 365 Plus
    Posts
    149

    Re: If Decimal Found then move the data from after decimal to before decimal

    sorry for reply

  6. #6
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP and 2007
    Posts
    15,819

    Re: If Decimal Found then move the data from after decimal to before decimal

    I don't fully understand what you are trying to do. Based on the two examples and the brief description given, it looks to me like you want to multiply column K by 100.

    If that is correct, without using VBA, you could enter 100 into a cell -> copy that cell to clipboard -> select column K -> paste special -> multiply. An equivalent process should be fairly straightforward in VBA -- if VBA is required.

    That's just a guess. If that's not correct, then I think we need a better explanation of what you need to do.
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  7. #7
    Forum Contributor
    Join Date
    07-16-2009
    Location
    NA
    MS-Off Ver
    MS Excel 2010
    Posts
    237

    Re: If Decimal Found then move the data from after decimal to before decimal

    Bro U r Awesome MrShorty Sir
    What A Idea &a Great Suggestion to solve this Problem with so much Ease
    Yes Sir i am looking for the same
    May i get the macro For the same Sir

  8. #8
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP and 2007
    Posts
    15,819

    Re: If Decimal Found then move the data from after decimal to before decimal

    This is what the macro recorder gave me for that process:
    Please Login or Register  to view this content.

  9. #9
    Forum Contributor
    Join Date
    07-16-2009
    Location
    NA
    MS-Off Ver
    MS Excel 2010
    Posts
    237

    Re: If Decimal Found then move the data from after decimal to before decimal

    Please Login or Register  to view this content.
    I made this Working Fine & Awesome & If any changes are required as per u Sir then plz let me know Sir

  10. #10
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP and 2007
    Posts
    15,819

    Re: If Decimal Found then move the data from after decimal to before decimal

    If it is working correctly, I see no need to change it. If you are interested in learning how to "tidy up" recorded macro/VBA code, you might review these two essays:
    http://www.tushar-mehta.com/excel/vb...rder/index.htm
    https://peltiertech.com/how-to-fix-a-recorded-macro/

  11. #11
    Forum Contributor
    Join Date
    07-16-2009
    Location
    NA
    MS-Off Ver
    MS Excel 2010
    Posts
    237

    Re: If Decimal Found then move the data from after decimal to before decimal

    No Problem Sir, I am seeing the details
    Problem Solved
    Thnx Alot Sir
    Have a Awesome Day

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Calculating decimal places in a non decimal format (ie sixes not tens)
    By Mike Brewer in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 05-07-2013, 08:58 AM
  2. Replies: 4
    Last Post: 09-06-2012, 07:51 AM
  3. Conversions of Decimal Feet to Decimal Inches - Formula??
    By shubhamdev in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 04-15-2012, 01:27 PM
  4. Conversions of Decimal Feet to Decimal Inches - Formula??
    By shubhamdev in forum Excel General
    Replies: 2
    Last Post: 04-15-2012, 03:57 AM
  5. Paste two decimal number in excel without extra decimal places appearing
    By jeffery_frick in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-13-2009, 07:49 PM
  6. Replies: 3
    Last Post: 07-05-2006, 01:57 PM
  7. Replies: 3
    Last Post: 03-18-2006, 02:25 PM
  8. Replies: 3
    Last Post: 07-06-2005, 09:05 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1