LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 23
Default EOMONTH compatibility issue (workaround?)

Hi, it’s me again needing an advice. Excel 2003: I am using the
EOMONTH (ATP) formula in a file. My Excel is in English, but my users
have different languages. I need to replace the EOMONTH formula. Now,
as far as I understand, I have at least three options:

1) Workbook_Open event to find and replace EOMONTH (Ron’s code
http://www.rondebruin.nl/atp.htm) = I Can not use this one, since my
users may or may not have ATP installed and I can not force them to
manually install it (corporate policy, not under my control). In my
English version I had the code to automatically install it, as
follows:

Private Sub Workbook_Open()
Calculate
If AddIns("Analysis ToolPak").Installed = False Or AddIns("Analysis
ToolPak - VBA").Installed = False Then
Calculate
AddIns("Analysis ToolPak").Installed = True
AddIns("Analysis ToolPak - VBA").Installed = True
End If
Calculate
End Sub

Works in XL English, but it won’t work if other language. Any
workaround????

2) Replace EOMONTH with =DATE(YEAR(start_date),MONTH(start_date)+months
+1,0)

3) Use this UDF (www.adamslim.com):
Function AdsEndOfMonth(ByVal InStartdate As Double, ByVal InMonths As
Integer)
'replaces the EOMONTH function
'by Adam Slim

AdsEndOfMonth = DateSerial(Year(InStartdate), Month(InStartdate) +
InMonths + 1, 0)
End Function

If I have to use option 2 or option 3, which one should do a better
job in terms of performance??? I have 10.000+ cells using EOMONTH, and
performance is important in this file.

I will really appreciate your advises, comments, pros/cons.

Thanks,
Cecilia
 
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
Compatibility Issue WLMPilot Excel Discussion (Misc queries) 2 May 1st 10 10:23 PM
Compatibility Issue WLMPilot Excel Discussion (Misc queries) 2 March 8th 10 01:43 PM
Compatibility issue? Tom Excel Programming 11 November 30th 07 03:14 PM
could the #NAME? error be a compatibility issue? sweetsourpork New Users to Excel 2 November 23rd 07 07:35 PM
Code compatibility issue iamrajy[_4_] Excel Programming 1 October 17th 05 07:32 PM


All times are GMT +1. The time now is 07:14 PM.

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"