Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
Hari
 
Posts: n/a
Default Date of the First day of the previous month

Hi,

If am given a date like let say, 24-Jan-2006, how would I get the date
1-Dec-2005?

Presently I have used some seemingly complicated formula to get the
first day of the previous month. I have used convoluted combination of
DATE and EODATE function to achieve the same.

I have 2 issues with this

a) Probably there is an easy way to do this without using EODATE
function

b) This worksheet wont work for those who doesnt have Analysis Toolpak
Add-in installed.

Is there an alternate way for this?

Please guide me.

Regards,
HP
India

  #2   Report Post  
Posted to microsoft.public.excel.misc
Leo Heuser
 
Posts: n/a
Default Date of the First day of the previous month

"Hari" skrev i en meddelelse
ups.com...
Hi,

If am given a date like let say, 24-Jan-2006, how would I get the date
1-Dec-2005?

Presently I have used some seemingly complicated formula to get the
first day of the previous month. I have used convoluted combination of
DATE and EODATE function to achieve the same.

I have 2 issues with this

a) Probably there is an easy way to do this without using EODATE
function

b) This worksheet wont work for those who doesnt have Analysis Toolpak
Add-in installed.

Is there an alternate way for this?

Please guide me.

Regards,
HP
India


Hi HP

One way, with known date in C2:

=DATE(YEAR(C2),MONTH(C2)-1,1)


--
Best regards
Leo Heuser

Followup to newsgroup only please.


  #3   Report Post  
Posted to microsoft.public.excel.misc
Hari
 
Posts: n/a
Default Date of the First day of the previous month

Leo,

Thanks a lot. I feel really stupid to not try this. I thought that
Month(C2) -1 would give "error" in case value of Month is 1. So, I
didnt even try it out.

Regards,
HP
India

  #4   Report Post  
Posted to microsoft.public.excel.misc
Leo Heuser
 
Posts: n/a
Default Date of the First day of the previous month

"Hari" skrev i en meddelelse
ups.com...
Leo,

Thanks a lot. I feel really stupid to not try this. I thought that
Month(C2) -1 would give "error" in case value of Month is 1. So, I
didnt even try it out.

Regards,
HP
India

You are welcome and thanks for the feedback.
I know the feeling ;-)

Regards
Leo


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
Changing a date back one month John Excel Discussion (Misc queries) 7 February 7th 06 12:11 PM
date of last friday of previous month tkaplan Excel Discussion (Misc queries) 7 November 14th 05 06:05 PM
How do I break a date range by month? HeatherDawn Excel Discussion (Misc queries) 2 September 1st 05 07:31 PM
Round date to first of month Dominic Excel Discussion (Misc queries) 3 July 14th 05 11:21 PM
Formula for Extracting Month out of a Date column PokerZan Excel Discussion (Misc queries) 3 June 10th 05 08:30 PM


All times are GMT +1. The time now is 04:28 AM.

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

About Us

"It's about Microsoft Excel"