Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Formatting copied dates

I have written a Visual Basic program (using Office 2000) that:

1. Imports a space-delimited text file that contains 5 columns for dat
data (Year, Month, Day, Hour, Minute) into Sheet1

2. Concatenates the five fields in a string formula for the firs
record as 'Month/Day/Year Hour:Minute', placing it in another colum
on Sheet1

3. Copies this formula for all records into the same column

4. Copies the column range to Sheet2 by value

The IsDate function returns True for the dates on both Sheet1 an
Sheet2.

THE PROBLEM: The appearance of the dates is unexpected since they ar
at the left of the cell, in the form '1/1/2002 0:0', but jump to th
right, and to the form '1/1/1002 00:00', if the cell is edited.
think it will confuse my client as it does me.

Already attempted fixes: I have tried formatting the ranges that wil
contain the dates on Sheets 1&2 with .NumberFormat("m/d/yyyy h:mm").
Neither doing the formatting before the entry/copy nor after th
entry/copy works to give me a date
at the right of the cell.

Is it the string formula? How do I avoid using it? If that's not it
can ANYONE please give me a clue to a fix

--
Message posted from http://www.ExcelForum.com

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
The Dates change when sheet copied to a new workbook Robyns521 Excel Discussion (Misc queries) 4 January 7th 10 09:23 PM
dates vary in a copied sheet Jeannie Excel Discussion (Misc queries) 1 July 22nd 09 10:06 PM
Dates change when copied to new workbook or worksheet lori_tig Excel Discussion (Misc queries) 2 December 14th 07 03:29 PM
dates change when copied form 1 spreadsheet to another sheehanb Excel Discussion (Misc queries) 1 May 11th 06 02:59 PM
Copied dates automatically change to previous day Suz About this forum 0 February 3rd 06 08:58 PM


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

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

About Us

"It's about Microsoft Excel"