+ Reply to Thread
Results 1 to 6 of 6

Calculate times in cne cell with empty line break at the end

  1. #1
    Registered User
    Join Date
    02-17-2021
    Location
    Indonesia
    MS-Off Ver
    2016
    Posts
    3

    Calculate times in cne cell with empty line break at the end

    Hello,

    I'm new here and have some problem with empty line break at the end of a cell.

    Calculate.png


    I can't used this formula " =RIGHT(A3;5)-LEFT(A3;5) " that I've used in B3 to calculate hours between two times that separate with line break in one cell A3. My problem is the huge data in excel that I've got every month has empty line break at the end of cells, and it was time wasting to delete one by one just to run that formula.

    I did tried using FIND & REPLACE to replace line break (CTRl+J) with nothing, its not working and breaking the cells data.

    Any idea ?
    Attached Files Attached Files
    Last edited by rayculz; 02-17-2021 at 08:12 AM.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,792

    Re: Calculate times in cne cell with empty line break at the end

    Welcome to the forum.

    There are instructions at the top of the page explaining how to attach your sample workbook.
    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.

  3. #3
    Registered User
    Join Date
    02-17-2021
    Location
    Indonesia
    MS-Off Ver
    2016
    Posts
    3

    Re: Calculate times in cne cell with empty line break at the end

    I was misread that announcement before, thanks for reminding me.
    Already edit original post with workbook file attachment.
    Last edited by AliGW; 02-17-2021 at 08:18 AM. Reason: PLEASE don't quote unnecessarily!

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,792

    Re: Calculate times in cne cell with empty line break at the end

    Try this:

    =RIGHT(CLEAN(A5),5)-LEFT(CLEAN(A5),5)

  5. #5
    Registered User
    Join Date
    02-17-2021
    Location
    Indonesia
    MS-Off Ver
    2016
    Posts
    3

    Re: Calculate times in cne cell with empty line break at the end

    The code is not working until I realize to change , to ;
    And it was working now.

    Thank you very much.

  6. #6
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,792

    Re: Calculate times in cne cell with empty line break at the end

    Then you must be running a European locale, which you didn't mention.

    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.

+ 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. If cell is empty copy line x times and fill the blanks with predetermined text
    By Moonster in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-02-2020, 12:46 PM
  2. Replies: 4
    Last Post: 05-30-2018, 01:03 PM
  3. macro to set page break before empty cell
    By jdvdh001 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-12-2013, 07:43 AM
  4. [SOLVED] If one cell in line turn empty then entire line turns empty
    By Cristy0505 in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 07-19-2013, 06:02 AM
  5. Replies: 0
    Last Post: 11-14-2011, 05:40 PM
  6. [SOLVED] Break cell into multiple lines by line break
    By Chia in forum Excel General
    Replies: 1
    Last Post: 08-20-2006, 01:40 AM
  7. [SOLVED] line break in a cell-Is there a way to get the line break instead of a symbol?
    By luvgreen in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-14-2005, 02:05 PM

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