ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Simple Macro Help (https://www.excelbanter.com/excel-programming/314281-simple-macro-help.html)

Adam :: Oregon, USA

Simple Macro Help
 
Hi all,

I am importing some data into Excel from on old Wang system. I need to
create a date field, but the date field as imported shows up as 1/11/2001
00:00:00. I would really appreciate some help in creating a macro that
eliminates the 00:00:00 so I can just set the field up as a date field and
have it sort correctly.

Thank you,

Adam

Tom Ogilvy

Simple Macro Help
 
Selection.NumberFormat = "mm/dd/yyyy"

--
Regards,
Tom Ogilvy


"Adam :: Oregon, USA" <Adam :: Oregon, wrote
in message ...
Hi all,

I am importing some data into Excel from on old Wang system. I need to
create a date field, but the date field as imported shows up as 1/11/2001
00:00:00. I would really appreciate some help in creating a macro that
eliminates the 00:00:00 so I can just set the field up as a date field and
have it sort correctly.

Thank you,

Adam




Paul Lautman

Simple Macro Help
 
All date fields are really date time fields.
It is just formatting that make's them show one part or the other.

Press Ctrl-1 and change the number format to one that you prefer.

"Adam :: Oregon, USA" <Adam :: Oregon, wrote
in message ...
Hi all,

I am importing some data into Excel from on old Wang system. I need to
create a date field, but the date field as imported shows up as 1/11/2001
00:00:00. I would really appreciate some help in creating a macro that
eliminates the 00:00:00 so I can just set the field up as a date field and
have it sort correctly.

Thank you,

Adam




Adam :: Oregon, USA[_2_]

Simple Macro Help
 
Thank you, but Excel doesn't seem to recognize the cell entry as a date and
time field. I tried the other answer as well as changing the formatting to
eliminate the time, but it doesn't seem to help. I can't change the format
becuase Excel is not viewing the contents as a date with time appended.

Thanks,

Adam

"Paul Lautman" wrote:

All date fields are really date time fields.
It is just formatting that make's them show one part or the other.

Press Ctrl-1 and change the number format to one that you prefer.

"Adam :: Oregon, USA" <Adam :: Oregon, wrote
in message ...
Hi all,

I am importing some data into Excel from on old Wang system. I need to
create a date field, but the date field as imported shows up as 1/11/2001
00:00:00. I would really appreciate some help in creating a macro that
eliminates the 00:00:00 so I can just set the field up as a date field and
have it sort correctly.

Thank you,

Adam





Tom Ogilvy

Simple Macro Help
 
select the column

format as the date format you want to see

Edit=Replace

What: \

With: \

This should cause your data to be reevaluated and seen as dates.

--
Regards,
Tom Ogilvy

"Adam :: Oregon, USA" wrote in
message ...
Thank you, but Excel doesn't seem to recognize the cell entry as a date

and
time field. I tried the other answer as well as changing the formatting

to
eliminate the time, but it doesn't seem to help. I can't change the

format
becuase Excel is not viewing the contents as a date with time appended.

Thanks,

Adam

"Paul Lautman" wrote:

All date fields are really date time fields.
It is just formatting that make's them show one part or the other.

Press Ctrl-1 and change the number format to one that you prefer.

"Adam :: Oregon, USA" <Adam :: Oregon,

wrote
in message ...
Hi all,

I am importing some data into Excel from on old Wang system. I need

to
create a date field, but the date field as imported shows up as

1/11/2001
00:00:00. I would really appreciate some help in creating a macro

that
eliminates the 00:00:00 so I can just set the field up as a date field

and
have it sort correctly.

Thank you,

Adam







Myrna Larson

Simple Macro Help
 
I know you meant a forward slash (/) rather than backslash (\), no?


On Thu, 21 Oct 2004 15:07:40 -0400, "Tom Ogilvy" wrote:

select the column

format as the date format you want to see

Edit=Replace

What: \

With: \

This should cause your data to be reevaluated and seen as dates.




All times are GMT +1. The time now is 06:48 PM.

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