ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   unwanted number to date conversion while pasting data from web (https://www.excelbanter.com/excel-worksheet-functions/14815-unwanted-number-date-conversion-while-pasting-data-web.html)

Jacek

unwanted number to date conversion while pasting data from web
 
I am trying to get correct date from information copied from html file from
WEB excel spreadsheet.
The text is:
MANDURAH (CD) Race 1, NEW YEAR SALE (GRADE P5) Friday 11.02.2005.
The correct date is 11 February 2005.
When use command Datatext to columns and later replace . with / I am
getting date 2/11/2005 (2 November 2005) with value 37196. I tried format
whole spreadsheet as text or particular cells before and after operation.
What is more strange sometimes I am getting correct date in other worksheets
but I never know which date I will get.
I have also problem with pasting other data from web pages when numbers are
converted to dates against my wish. How I can stop it?
For example
A table in browser looks like this
Pool Result Div
Quinella 3-6 20.50
Exacta 6-3 33.30
Trifecta 6-3-8 154.50
Quartet 6-3-8-4 955.40



And in Excel:

Pool Result Div
Quinella 3-Jun 20.5
Exacta 6-Mar 33.3
Trifecta 6/03/2008 154.5
Quartet 6-3-8-4 955.4
Thanks
Jacek


Peo Sjoblom

Save as text file and later import as text under column data format
11.02.2005 where the dots will be replaced with slashes depends on your
regional settings
with US regional settings it will be converted to 11/02/2005 (Nov 11 2005)
with UK I assume it should be
Feb 11 2005, the 37196 is the equivalent of Nov 1 2001 (37196 days after Jan
0 1900 when Excel dates start)
using excel windows default but it is Nov 2 2005 using Macintosh 1904 date
system

--

Regards,

Peo Sjoblom

"Jacek" wrote in message
...
I am trying to get correct date from information copied from html file

from
WEB excel spreadsheet.
The text is:
MANDURAH (CD) Race 1, NEW YEAR SALE (GRADE P5) Friday 11.02.2005.
The correct date is 11 February 2005.
When use command Datatext to columns and later replace "." with "/" I am
getting date 2/11/2005 (2 November 2005) - with value 37196. I tried

format
whole spreadsheet as text or particular cells before and after operation.
What is more strange sometimes I am getting correct date in other

worksheets
but I never know which date I will get.
I have also problem with pasting other data from web pages when numbers

are
converted to dates against my wish. How I can stop it?
For example
A table in browser looks like this
Pool Result Div
Quinella 3-6 20.50
Exacta 6-3 33.30
Trifecta 6-3-8 154.50
Quartet 6-3-8-4 955.40



And in Excel:

Pool Result Div
Quinella 3-Jun 20.5
Exacta 6-Mar 33.3
Trifecta 6/03/2008 154.5
Quartet 6-3-8-4 955.4
Thanks
Jacek





All times are GMT +1. The time now is 02:57 PM.

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