Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
ColoradoKid
 
Posts: n/a
Default How do I format column containing date and time to only show the .

I'm trying to sort a worksheet by a column that has both date and time in it,
and I would like to get rid of the date portion and sort strictly by time of
day.
  #2   Report Post  
Peo Sjoblom
 
Posts: n/a
Default

use a help column and a formula like

=MOD(A2;1)

copy down and sort by the help column


Regards,

Peo Sjoblom



"ColoradoKid" wrote:

I'm trying to sort a worksheet by a column that has both date and time in it,
and I would like to get rid of the date portion and sort strictly by time of
day.

  #3   Report Post  
ColoradoKid
 
Posts: n/a
Default



"ColoradoKid" wrote:

I'm trying to sort a worksheet by a column that has both date and time in it,
and I would like to get rid of the date portion and sort strictly by time of
day.


well I'm not sure if that is the solution. Let me elaborate a little. The
cells contain the following data for example "01/01/2004 7:32 ". Now what I
want to do is remove the date and have only the time remaining.

Maybe the mod function would do it but I'm not sure.

I was trying to figure it out with the trunc function possibly.

Any response is appreciated.

CoKid
  #4   Report Post  
Gord Dibben
 
Posts: n/a
Default

CoKid

Did you try Peo's suggestion?

Gord Dibben Excel MVP



On Fri, 17 Dec 2004 16:25:03 -0800, "ColoradoKid"
wrote:



"ColoradoKid" wrote:

I'm trying to sort a worksheet by a column that has both date and time in it,
and I would like to get rid of the date portion and sort strictly by time of
day.


well I'm not sure if that is the solution. Let me elaborate a little. The
cells contain the following data for example "01/01/2004 7:32 ". Now what I
want to do is remove the date and have only the time remaining.

Maybe the mod function would do it but I'm not sure.

I was trying to figure it out with the trunc function possibly.

Any response is appreciated.

CoKid


  #5   Report Post  
Frank Kabel
 
Posts: n/a
Default

Hi
Peo's formula works. Just try it. But maybe you're more comfortable with
=INT(A1)

though it will return the same value as Peo's formula

--
Regards
Frank Kabel
Frankfurt, Germany

ColoradoKid wrote:
"ColoradoKid" wrote:

I'm trying to sort a worksheet by a column that has both date and
time in it, and I would like to get rid of the date portion and sort
strictly by time of day.


well I'm not sure if that is the solution. Let me elaborate a
little. The cells contain the following data for example "01/01/2004
7:32 ". Now what I want to do is remove the date and have only the
time remaining.

Maybe the mod function would do it but I'm not sure.

I was trying to figure it out with the trunc function possibly.

Any response is appreciated.

CoKid





  #6   Report Post  
ColoradoKid
 
Posts: n/a
Default


The mod function did the job.

I also got the trunc function to work but took 2 steps instead of the
single step by using mod.

Thanks alot
CoKid

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
USING THE DATE FORMAT IN EXCEL teach Excel Discussion (Misc queries) 3 December 15th 04 12:55 AM
Combined date time cell to separate date & time components Mark Ada Excel Discussion (Misc queries) 1 December 2nd 04 03:48 AM
Combined date time cell to separate date & time components Mark Ada Excel Discussion (Misc queries) 1 December 2nd 04 01:07 AM
Combined date time cell to separate date & time components Mark Ada Excel Discussion (Misc queries) 1 December 2nd 04 01:07 AM
Date and Time Macro m.j.anderson Excel Discussion (Misc queries) 1 December 1st 04 01:35 AM


All times are GMT +1. The time now is 01:29 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"