ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   How to replace a constant from a cell containing date and time (https://www.excelbanter.com/excel-discussion-misc-queries/447282-how-replace-constant-cell-containing-date-time.html)

BACITH

How to replace a constant from a cell containing date and time
 
In the below example the number in the bracket is the no of days elapsed from the date given in the cell till today. this is a software generated report which shows the aging. i want to take only the no of days. i want to replace date and time. please help me to do so. Below it shows the date and time the data was entered to the software and the no of days elapsed.

2012-05-21 08:11:42( 135)


Thankyou

Claus Busch

How to replace a constant from a cell containing date and time
 
Hi,

Am Wed, 3 Oct 2012 10:28:53 +0000 schrieb BACITH:

In the below example the number in the bracket is the no of days elapsed
from the date given in the cell till today. this is a software generated
report which shows the aging. i want to take only the no of days. i want
to replace date and time. please help me to do so. Below it shows the
date and time the data was entered to the software and the no of days
elapsed.

2012-05-21 08:11:42( 135)


select your column = Data = Text to Columns = Fixed Width = Next =
put 1 delimiter behind the opening bracket and one in front of the
closing bracket = Next = first and third column = Do not import the
column = Finish
Or do it with formula:
=--TRIM(SUBSTITUTE(MID(A1,FIND("(",A1)+1,99),")",))


Regards
Claus Busch
--
Win XP PRof SP2 / Vista Ultimate SP2
Office 2003 SP2 /2007 Ultimate SP2


All times are GMT +1. The time now is 09:35 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com