Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
still stuck on days value to year value code
In the below code i get a date result in sheet(Print & Shading Page)from,
a value(date) in sheet(Induction Frequency Page) being added to a value(number) in sheet(Induction Frequency Page) At present i am using DAYS as a number in the sheet(Induction Frequency Page). eg. 365.25 to represent 1 year; 730.50 to represent 2 years etc But i want to ADAPT the below code to work the same by adding the date in 1 sheet to the number in another sheet annd placing that date in a 3rd sheet, BUT WITH ENTERING VALUES SUCH AS 1(year) or 5(years) INSTEAD OF THE CURRENT 365(days) method the code is doing now. I think i have to place a date formula step in the below code indicated by the arrow, but am not sure what formula to add, to change the sheet(Induction Frequency Page) VALUE from DAYS to YEARS. Sub Dates() Dim cell As Range Dim PSP As Worksheet Dim ifp As Worksheet Set PSP = worksheets("Print & Shading Page") Set ifp = worksheets("Induction Frequency Page") For Each cell In worksheets("Inductions Update Page").Range("C8:R30") With cell If .Value < "" Then PSP.Range(.Address).Value = ifp.Range(.Address).Value + ..Value End If End With Next End Sub Easy?? Corey.... |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Calc days between two dates and exclude leap year days | Excel Worksheet Functions | |||
i have two days and i want the difference in days, months, year | Excel Worksheet Functions | |||
Help! I am stuck calculating Days, Hours, Mins please help | Excel Worksheet Functions | |||
Help! I am stuck calculating Days, Hours, Mins please help | Excel Worksheet Functions | |||
Help! I am stuck calculating Days, Hours, Mins please help | Excel Worksheet Functions |