Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 13
Default How to suppress Time ?

In the FileDateTime(filename) command, how to suppress the Time ? Even if
column width is shortened, does not help.

Milind


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.514 / Virus Database: 312 - Release Date: 8/28/2003


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default How to suppress Time ?

' remove the time portion
Range("A1").Value = clng(FileDateTime(filename))
Range("A1").NumberFormat = "dd/mm/yyyy"

or

' or just format it not to show
Range("A1").Value = FiledateTime(filename)
Range("A1").NumberFormat = "dd/mm/yyyy"

--
Regards,
Tom Ogilvy


Milind wrote in message
...
In the FileDateTime(filename) command, how to suppress the Time ? Even if
column width is shortened, does not help.

Milind


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.514 / Virus Database: 312 - Release Date: 8/28/2003




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default How to suppress Time ?

Or FIX - negative numbers shouldn't be an issue - good thought. Thanks for
the Alert.

--
Regards,
Tom Ogilvy

Rob Bovey wrote in message
...
"Tom Ogilvy" wrote in message
...
' remove the time portion
Range("A1").Value = clng(FileDateTime(filename))
Range("A1").NumberFormat = "dd/mm/yyyy"


I'd be careful with CLng(), since it rounds. Int() would probably be
better.

--
Rob Bovey, MCSE, MCSD, Excel MVP
Application Professionals
http://www.appspro.com/

* Please post all replies to this newsgroup *
* I delete all unsolicited e-mail responses *




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
Suppress PopUp Shell Excel Discussion (Misc queries) 4 December 18th 09 07:10 PM
Suppress @VALUE! on a template. Sol Excel Discussion (Misc queries) 4 December 2nd 08 10:48 PM
How do I suppress the time in m/d/yy date column? hbrad Excel Discussion (Misc queries) 1 September 8th 08 08:55 PM
Suppress a row DCN Excel Worksheet Functions 2 January 22nd 07 07:16 PM
#DIV/0! ...how to suppress when using this formula.... Randy Lefferts Excel Discussion (Misc queries) 7 December 2nd 04 09:56 PM


All times are GMT +1. The time now is 03:33 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"