Determine If The Input Date (Yearx) In A Userform Is A Leap Year
Sep 18, 2009
I need to determine if the input date (Yearx) in a userform is a leap year. I tried doing this: Leap = Evaluate("MOD(Yearx, 4)") IF Leap = 0 then (show 29 days on my planner).
But no matter what date I put in, it generates "0" as the value for Leap, so indicates that February has 29 days. Obviously I'm not doing this right.
I need a formula that will calculate the number of days (ex from 10/1/08-1/1/12) and will differentiate between leap year and a regular year. I am trying to calculate interest between 2 dates and leap year is calculated on a different interest rate. Right now I have it set up so I have to manually type in the leap years in a separate field instead of being able to just you point a to point b.
My spreadsheet uses alternating columns for actual and budget inputs I would like to preload the budget for the whole year But the ytd formula should only show results to match the input of actuals
In otherwords, If I input actuals for period 1, the YTD formulas for actuals and budget should return YTD period 1 only and ignore the remainder of the budget inputs
After period 2 actual inputs, the formulas shlould update to reflect period 2 YTD and so on and so forth
How can I accomplich this? Sample of layout attached Totals at Cols AK-AM
=> and for my ms excel has its columns (year,month,date) in this if i input the date that is base in the database range from StartDate TO its EndDate will automatically put the month and year which base also in my database (year,MonthNum)
HERE:
A1 B1 C1 Year Month Date A2=2014 B2=January C2=01/01/2014
I have dates in my column “A”, for example (A1 cell =22-Mar-1971), (A2 cell=30-Dec-1965). Now my requirement is in B column date and month from A column and year should take current year. Output in B column (B1 cell =22-Mar-2009), (B2 cell=30-Dec-2009)
I'm trying to use Solver to determine an input parameter of the BINOMDIST() formula that provides the exact answer I want. It works for some inputs and outputs but not for all.
For example, I want 4 successes out of 7 trials to yield a 95% answer, meaning I need to itterate on the "P" input in the formula [=BINOMDIST(4,7,"P",TRUE) should result in .95]. Using solver it iterates successfully to .3413.
Now, change 4 to 6, and solver drives "P" to an answer that causes a #NUM result (P= 4.023), however I can manually input 0.6518 and I get the right answer.
I've tried adding constraints that won't let the input go outside the bounds of 0 and 1.0 but it does anyway.
I have a template with formulas calculating a default value, but still allowing the user to override the cells with direct input.
I want to use conditional formatting to highlight any cells that have been overwritten, but can't find a way for Excel to differentiate between a cell with a formula or an inputted constant.
I realize there is a VBA "isFormula" function, but I don't want to have to use VBA for this.
I have a sheet in my workbook with at least 180 small tables, there may be more. I woulds like to be able to change total formulas for all tables at once to show either year-to- date or total year.
For example: If we have only progressed through the second period of the year, I would like to choose something to indicate period 2. At other time I may want to know the total year whether the periods are completed or not.
I have created a useform in VB which will determine business days. I need help in the coding part.
In my user form I have text box, I have a calender and I have two command buttons, 1 Calculate 2 exit. What i would like to achieve is when i type a number in the txtbox and press cmd button calculate the code will shade the the date in the calender so for example if I type in 10, then the code should shade 13/02/09 on the calender since 13/02/09 is the 10th business day.
It looks like a pretty silly problem but it's driving me mad. The yearfrac function takes a two dates and a basis. Now assume basis = 1 ( Act / Act ) and two cases:
In case 1) 2008 is a leap year ( but the "leap" has yet to come! ). Can anyone explain me the logic behind? I suppose the extra day is divided by 3 but where is the "Actuality" of the divisor?
I have a forecast monthly trial balance sheet and an Income Statement Analysis sheet. I am analyzing the Year to Date performance for Dec-2013. I need a formula that will match the income statement line i.e revenues, accounting expenses etc. and then sum horizontally from Jan-2013 to Dec 2013 ( if YTD month' Dec-2013' is greater than or equal to date range then sum horizontally the corresponding income statement lines up to the reporting month).
I have a document that I downloaded some data from the Internet "Kronos" and within this data there is a column for date. This column is formatted as Date (01/08/13), but it only displays the date as Sun 1/01. It's missing the year, which it should be 01/01/12. I have tried to use TEXT function to convert it to month name and day name using TEXT(N4, "mmm") and Text(N4,"ddd"), but I still getting Sun 1/01. I have also tried to use Text to columns to split this date but, it does not work. Is there any other way I can convert this date into m/d/yy?
Is it possible to format cells to convert a date format of month/day/year to = year/week #/day of week? For example, 04/05/07 (April 5, 2007) would read as 7145, (7=last digit of year/ 14 = week number / 5 = day of week....Sunday being the first day of week)
I am an absolute beginner to Excel programming and new to this forum. After I have been reading some basics I think this is absolutely the right place to learn
What I am trying to do i to use a userform for input in list. Should be simple, but I can't figure it out
Attached there is a sheet that I set up. The sheet called "Source" contains some data that is used as a picklist in the input form. I created a user form called "Newflight" with comboboxes in which you can input plane type, pilot and passenger based on the data in the Source sheet. It also contains an input box for the take off time. (it would be very nice if I the actual time could be entered by a single click, but the user should still be able to enter it manually). After clicking "STORE" the data should be stored in the first empty row in the sheet called "List".
I have a pivot table for which I load data from a .csv file. Is it possible to include a timestamp on when the .csv file was last loaded. If I do it above the actual pivot table, it just shows when the pivot table was refreshed, but not when the .csv file was last loaded.
The code is ok until I hit a month with 4weeks in it and days left over. The code puts a week total in place of a Sunday, but as some months end before a Sunday appears the code just builds a Month end total sheet.
What I need in this case is a Week total even if there is no Sunday before it builds the Month end Total.
I hope i'm being clear
Sub NewSheets() Dim Dte As Date, Dy As Date Dim i As Long, j As Long, Dys As Long Dim CountWeek As Boolean Dim Shts As Long...
I have got a spreadsheet that needs filling in by 3pm everyday. The workbook has a worksheet for each day e.g. Mon to Fri. What I am looking to do is fill the worksheets in for whatever day it is e.g. if it is monday then select monday data from required file and paste into monday worksheet. I was going to create five macros for each day and then select the required one on the day, but rather than doing this is their a way that i could write one macro that runs by checking what day it is? e.g. if monday run monday code...