Solved

Formatting

Posted on 2011-02-23
8
190 Views
Last Modified: 2012-05-11
Can anyone formatt Col G+H? I have tried but am failing

Just want them in date and time format

Thanks
Seamus
Example.xls
0
Comment
Question by:Seamus2626
  • 2
  • 2
  • 2
  • +2
8 Comments
 
LVL 4

Expert Comment

by:h3nnys
ID: 34960273
could you upload the sourse file so that I can format it and see where the issue lies
0
 

Author Comment

by:Seamus2626
ID: 34960287
here is the code that is creating the data in G+H

Thanks
Seamus
0
 
LVL 50

Accepted Solution

by:
barry houdini earned 167 total points
ID: 34960291
Hello Seamus,

To get the date in G2 use

=INT(C2)

and for the time in H2

=MOD(C2,1)

format in date and time format respectively

regards, barry
0
 
LVL 19

Assisted Solution

by:MINDSUPERB
MINDSUPERB earned 166 total points
ID: 34960297
Use this formula in G2 and H2
=VALUE(LEFT(C2,9))

Format Column G into Date and Column H into Time.

Sincerely,

Ed
0
Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

 
LVL 19

Expert Comment

by:MINDSUPERB
ID: 34960310
It must be only =VALUE(C2)

instead of =VALUE(LEFT(C2,9))


Ed
0
 
LVL 9

Assisted Solution

by:sah18
sah18 earned 167 total points
ID: 34960315
There are several ways to accomplish this.  I've attached one possible solution.
Example-with-corrected-date-time.xls
0
 
LVL 50

Expert Comment

by:barry houdini
ID: 34960358
Using LEFT(C2,9) is a mistake, I think. That would be fine if C2 was a text value.....but it's not so by extracting the first 9 characters you are actuallt taking the date serial number (5 digits) plus decimal point and then 3 decimal places. If you use VALUE function on that you can format as a date but the underlying value still contains the decimals (effectively a time) which might cause problems if you want to do other calculations with the value returned.

INT, as per my suggestion, just takes the integer portion of C2 (the date) and MOD(C2,1) takes the decimal part (the time)

regards, barry
0
 

Author Closing Comment

by:Seamus2626
ID: 34960414
Thanks guys!
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Sparklines have been introduced with Excel 2010 and are a useful tool for creating small in-cell charts, used for example in dashboards. Excel 2010 offers three different types of Sparklines: Line, Column and Win/Loss. What it does not offer is a…
This code takes an Excel list of URL’s and adds a header titled “URL List”. It then searches through all URL’s in column “A”, looking for duplicates. When a duplicate is found, it is moved to the top of the list. The duplicate URL’s are then highlig…
Viewers will learn the basics of slicers and timelines for both PivotTables and standard Excel tables in Excel 2013.
The view will learn how to download and install SIMTOOLS and FORMLIST into Excel, how to use SIMTOOLS to generate a Monte Carlo simulation of 30 sales calls, and how to calculate the conditional probability based on the results of the Monte Carlo …

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now