Excel 2003 :: Search Cells Based On Month And Year

Aug 9, 2013

I have the following code, which I used to search Column A for a date and then copy the adjacent cell next to the date and paste it to sheet2.

However what I want to do now is be able to enter just the month or the year and the code will find the cells that contain the same year or month that I entered. I know to find a string value in a cell I can use InStr() however I don't know how to implement this into the code that I have, As depending on the month that I select I want the code to put the value in a certain cell.

Here is the code that I have so far

Code:

Sub SearchMacro()
DateSearch.Show

Dim LR As Long, i As Long
With Sheets("Sheet1")
LR = .Range("A" & Rows.Count).End(xlUp).Row

[Code] ......

How I can do this by edited the current code or any code for that matter.

View 9 Replies


ADVERTISEMENT

Automatic Entry Of Dates Based On Month & Year In Cells

May 30, 2007

I want to create a monthly timesheet which contains 9 columns for
(Date, Day, Project no., Activity, Time In, Time Out, Total Hours, OT Hours, Remarks)

I have used IF Function to calculate Total Hours & OT hours automatically. Time IN & Time OUT, Project No., will be entered manually on daily basis.

Weekday function is used in the Day column to return the corresponding day of the date in the Date column.

Name of the Month and Year will be manually entered in the designated cells I3 and I4 respectively.

Now the solution I am looking for is, the dates should be automatically entered in the Date column (in cells A8 to A38) based on the Month & Year entered in cells I3 & I4. Dates of the corresponding month of the year should only be filled in. (If a month is not having 29, 30 or 31st day, the corresponding cells should be left blank. i.e. nothing should be displayed in the corresponding cells). I am looking for some sort of formula to enter in the cells of Date column (A8 to A38) achieve this. I have searched the forum and could not find anything which could at least give me an idea about the kind of function or formula to be used.

Attached here is the time sheet I am trying to create.

View 8 Replies View Related

Change Year But Keep Month The Same Based On Current Year

Mar 8, 2014

I am working on a budget for myself and want it to have running dates so the first data column will have the current month. I was able to succeed with this using the EOMONTH function followed by EDATE functions in the following cells, I then have these columns filled using a nested VLOOKUP MATCH function pair.

The problem I run into is with the months that extend into the next year, in my data table I have month by month listed started on 01/01/2014 ending 12/01/2014 but as soon as the month is no longer January the last column in my budget cannot find the information needed due to it looking for 2015. so what I would like to know is if there is a way to make the data table change the year to the following year after today is beyond that month, so for example on March 1 2014 both January and February would be changed to 2015.

Attached is an example : Budget Example.xlsx‎

View 4 Replies View Related

Search Range For Current Month & Year Return Corresponding Values

Nov 21, 2007

I have a workbook with two spreadsheets in it. On the second sheet there is a large table, which column headings are months and years (e.g. Jun-07 Jul-07, Aug-07, Sep-07....). I was trying to write an excel vba code that would search the first row (column headings) to find the current month and year, and copy the corresponding column along with two previous columns (months) to the first sheet. I would like to have a code that will be able to do this in Jan-08, Feb-08, or Jan-09 as well.

View 2 Replies View Related

SUMIF Month & Year: Find Total Cost By Month Only For Year 2009

Dec 17, 2009

In attached sheet, I am trying to find total cost by month only for year 2009. Currently formula I have in Cell c24, is {=SUM(IF(MONTH(B2:B9)=1,D2:D9,0))} But this calculates for all years, not just 2009. How do I modify above formula, so for each month, it shows total cost but only for 2009?

View 2 Replies View Related

Return Month Based On Day Of The Year?

Mar 27, 2014

I have a sheet with the following values:

280315 085B 10:24 2R

The '085' is the 85th day of the year. I would like a formula that reads that part of the data, and return the month that day is in, in the "jan", "feb", "mar", etc. format.

View 14 Replies View Related

Sum Report Based On Month & Year

Sep 5, 2007

I would like to calculate the sum of investments based on their expiry date and have the totals per month (and year). I have a table that looks like:

TermInterest rateMaturityBalance
24 Months7.12%11 November 200740,000.00
12 Months7.74%13 November 200750,000.00
24 Months7.05%10 January 200853,889.12
12 Months7.85%11 January 2008120,000.00
12 Months8.02%22 March 200817,000.00
36 Months6.68%30 June 200832,000.00

I'd like to have something like:

Nov 07 90,000.00
Dec 07 0.00
Jan 08 173889.12
and so on...

Admittedly I am an Excel novice, so excuse me if my question is dumb and has a simple answer (actually I hope it has :-) but I have tried to find a solution by searching forums, my books, online help, I tried my luck with sumif and SUMPRODUCT functions, even used the conditional sum wizard, but I can't get it right

View 4 Replies View Related

Excel 2003 :: Copying Cells Based On Alternate Cell Value?

Sep 26, 2011

I am wondering if it possible to automate the copying of data from particular cells, based on a value in a different cell, into a different format.

So to go from this simplified table:

AB1NameLevel2Arthur2a3Briony3c4Catherine3b5David3a6Edward2a7Felicity3c8George3c
to something like this:

FGHI12a3c3b3a2ArthurBrionyCatherineDavid3EdwardFelicity

4
George

At the moment I do it all manually, and it takes forever. I am sure there must be a simple way of doing it. I am using Excel 2003, but could work in a newer version if required.

View 9 Replies View Related

Excel 2003 :: Macro To Copy And Read Cells Based On Name

Feb 5, 2012

I have three workbooks that contain various types of information. I have an Overtime workbook that lists employees and calculates the straight time and overtime worked for the day. This is the main log that information will be pulled from.

I need writing a macro that will copy over information to an Absent Log workbook and a Production Model workbook.

The Absent Log workbook:

This workbook contains worksheets from each month. I need excel to do a lookup of the name in the Overtime workbook and copy the information from the "OT" column but if that column is empty I need it to pull the information from the "Personal DT" column.

The Production Model workbook:

I need this workbook to automatically pull the total straight hours and overtime hours to the production model for the correct day. This will also pull from multiple sheets.

I am going to be writing this in Excel 2010 but it will be primarily used in Excel 2003.

I uploaded the workbooks to filefactory.

OT Workbook: [URL] ......

Absent "Log" workbook: [URL] .....

Production Model: [URL] .....

View 1 Replies View Related

Excel 2003 :: Macro That Will Generate A List Based On Cells Value

Mar 6, 2012

I have a workbook that has 30 tabs in it. Each tab is a report card for students. What I'd like to do is create another tab with a button on it that when I hit the button it will search through each tabs range of D12:D40, D48:D76, D84:D112, D120:D136, J12:J40, J48:J76, J84:J112, and J120:J136. And if any of these cells has an MS in them then this new sheet I have created will list each students name which is in cell E5 and list what they recieved the MS for. This will be in the same row number but in column B. So if cell D12 has an MS in it then this report will list the students name and what's in cell B12.

Windows XP
Excel 2003

View 3 Replies View Related

Calculate Year To Date Based On Known Month

Dec 6, 2009

I want to calculate Year To Data in B1 based on some data in C1 to N1. The monthnumber is located in cell A1.

There is of course several ways to do this, but is there a simple and easy formula one can use.

View 3 Replies View Related

Return A Date Based On Year / Month

Jan 21, 2009

formula off here i use all the time relating to finding and sumproducts for specific months and years i.e.

Jan 2008, Dec 2007.. depending on these dates excel searched through a specified range and returned me any values i wanted like No. of occurences, totals, sums etc etc it was a sumproduct formula...

is there any way i could specifiy a date i.e. Jan 2009, which would search column a and return the date /and/or an account number in column b, only if the date was during jan 2009?

The reason i want this is to use a lookup on the account numbers to return specific items of info, but i only need the account numbers if they occurred in specific months which i want to choose.

View 9 Replies View Related

Finding Average Based On Month And Year

Aug 4, 2009

I have 5 years of data in 2 columns:

Col A. Col B.
8/2/2004 Value 1
to
7/31/2009 Value n

I have a table set up as follows

1 2 3 4 5 6 7 8 9 10 11 12
2004
2005
2006
2007
2008
2009


I was wondering how I could construct a conditional statement to pull the associated values with the given month and year in the table...

I tried the following to no avail... I'm just getting a zero value:

=AVERAGE(IF(MONTH(J6:J1255)=AC$35,IF(YEAR(J6:J1255)=$AB37,K6:K1255)))

View 9 Replies View Related

Sum Column Based On Other Columns Year & Month

Feb 21, 2008

I have the following variables in these columns

Column 1: Ship (1064, 1065, 1066 as the field contents)
Column 12: Date (21-Feb-08 as format)
Column 13: Weld Length (1000 as format)
Column 15: Defect Length (1000 as format)

What I need doing is the following is in a single cell per month add up what the total weld length is as well as the defect length as I have Jan 08, Feb 08 etc on another sheet where these values will be returned.

There is a seperate sheet for each Ship so would like a formula that I could ammend 1064 to 1065 etc

View 9 Replies View Related

Typing Month And Day - Excel Assumes Day Is The Year

Apr 17, 2014

I used to type a date into excel as "apr 17" and it displayed the date as 17-Apr-14, which is exactly how I wanted it to.

Now, with my new computer, I type "apr 17" and get the date 01-Apr-17.

I have changed the format of the cell to date, with the type set to 14-Mar-01. I have even tried changing the format to date, custom dd-mmm-yy and still get the same issue.

I want excel to recognize I am only entering the month and day and to automatically input the current year. I do not want to type the year every time I make a data entry.

View 2 Replies View Related

Excel 2007 :: Grouping By Day And Month But Not Year

Nov 4, 2013

I want to count the number of adults and juveniles by 5 day intervals (Augest 1st-5th, 6th-10th, ect). I am currently using =COUNTIFS($A:$A,1,$F:$F,$A27) and manualy labeling the intervals (Aug 1-5 = g, 6-10 = h). I would like to know if there is a easier or faster way to do this. Some of my sheets are 10,000+ entries.

I am also a basic user of Excel so I am not famillar with a lot of the functions.

I'm using Excel 2007

This is a small portion of my data. Age code: 1= Adult, 2= Juvenile, the letters in F are my lables.

Excel 2007ABCDEF1AGE_CODEBANDING_DATEBANDING_DAYBANDING_MONTHBANDING_YEAR2110/31/196331101963y3110/31/196131101961y4111/1/19611111961y5111/1/19651111965y6111/3/19603111960y7111/5/19645111964z8111/5/19645111964z9111/5/19655111965z10111/5/19655111965z11111/6/19626111962z12111/8/19608111960z13111/8/19608111960z14111/11/196011111960aa15211/15/198115111981ab16111/18/201218112012ab17111/19/196419111964ac18111/21/196221111962ac19111/21/196521111965ac20211/24/200224112002ad21111/28/196128111961ad22112/2/19622121962ae23112/3/19613121961aeSheet1

View 8 Replies View Related

How To Get Only Month Year If There Is DATE - MONTH - YEAR In A Cell

Aug 20, 2013

How to get only MONTH' YEAR if there is a DATE-MONTH-YEAR in a cell?

A1: 27-July-2012

Answer D1:JULY' 2012

Pl note "' " is suffixed after JULY (the month).

View 4 Replies View Related

Change The Cell Focus Based On Month And Year

Jan 22, 2010

I have a worksheet called "zz_Exchange" that contains the exchange rate for my company for each month of the financial year. I am using this info in a summary page that uses the data for multiple calculations in the workbook.As we pass each month I would like to move the focus of a cell in the summary sheet to the relevant month in "zz_Exchange"

The column names are "currency_code" (USA Euro etc),
"currency_year" (09, 10)
"period" (1-12)
"exchange_rate" (this is where the data is held)

View 4 Replies View Related

Subtract 1 Year From Date Based On Month (January)

Jan 4, 2014

How I can subtract a year when I formulate based on if the current month is January.

Such as Current month = January 2014, I would require the cell to populate December 2013, any other month would return the current year value.

I have currently tried { =DATE(YEAR(A3)-1,MONTH(A3),DAY(A3)) } whereas cell A3 uses NOW() function formatted to MMMM, but it changes for every month.

View 9 Replies View Related

Changing Formula To Count Based On Year And Not Month?

Apr 15, 2014

I'm using this formula to count how many times the date in column C and the text "WON" appears in column I and it falls within the month & year that is in Z65.

=COUNTIFS(INDEX(C:C,$AL$15):INDEX(C:C,$AL$17),">="&DATE(YEAR(Z65),MONTH(Z65),1),INDEX(C:C,$AL$15):INDEX(C:C,$AL$17),"

View 2 Replies View Related

Excel 2003 :: Cell Result Based On Range Of Filled / Empty Cells

Apr 3, 2014

I'm stuck using Excel 2003 to auto-populate a cell.

I have a range of dates in five consecutive columns called:

Phase 1, Phase 2, Phase 3, Phase 4 and Phase 5

I enter the date that 'Phase 1' starts under the first header. Once Phase 2 starts I enter a date under 'Phase 2', and so on to Phase 5.

Each phase is consecutive to the next so will always be filled in from 1 to 5.

I want to create an additional column called 'Status' that shows the Column Title of the last phase with a date in it. For example, if Phase 1 to 3 had dates but 4 & 5 were blank, "Phase 3" would be displayed in the 'Status' column.

I've tried nesting some ISBLANK functions without any luck.

View 4 Replies View Related

Formula To Sum Sales Over 12 Month Period Not Based On Calendar Year

Mar 27, 2014

I am writing a formula that will sum data for a 12 month period that is not based on a calendar year. For example may have data starting in June 2011 running to date, but not every month. If I set a start date for Year 1, say April 2012, I need to see Year 0 numbers (anything prior to April 2012), Year 1 numbers (April 2012 to March 2013), Year 2 numbers (April 2013 to March 2014), and so on. Date format is currently mmm-yy.

If this could be performed via a macro which references the database (spreadsheet), then even better. The database will contain multiple columns, of which two will contain the date and corresponding number respectively.

View 12 Replies View Related

Formula To Count Weekday Occurrence Based On Month And Year

May 3, 2007

I know there's a pretty compley formula out there that counts the occurence of say Fridays in 2009 - does anyone have this? I had it before in a file but ranged valued the results showing the count of each day of the week for each month in a given year.

View 9 Replies View Related

Excel 2003 :: Show First Day In A Month

Feb 8, 2013

Excel 2003.

Trying to show the first day in a month.

B4 shows 8-Jan-13
A2 has formula =MONTH($B$4) which returns 1-Jan-00

Both cells are formatted as dd-mmm-yy. So why is A2 showing the year as 00?

View 4 Replies View Related

Merging Values From 2 Cells To Get Month And Year

Feb 26, 2012

I have 1 cell where i am entering month like 2 (for FEB) and in other cell i am putting value 2012 (year)

I have 1 more cell where i have to manually add 1st date of the month like: 01-02-2012

Can I merge first two values and let excel automatically return 01-02-2012 in my desired cell.

Also if i need to convert 02 to FEB or 03 to MAR then what is the formula for this.

View 6 Replies View Related

IF Statement To Display Quarter Of A Year Based On A Three-letter Month Abbreviation

Nov 16, 2009

I'm trying to wrtie an IF statement to display one of Q1, Q2, Q3 or Q4 based on the three letter month abbrev. All i have so far is the following, which isn't leading anywhere - and i have a feeling theres an easier way to write it.

=IF(((OR(G2="Jan","Feb","Mar"),)),"Q1",""),IF(OR(G2="Apr","May","Jun"),"Q2","")

View 9 Replies View Related

Copy Data Based Off Of Fill Color (month) And Year From Another Workbook

Aug 3, 2006

I have a detailed note inside biweekly.xls, it explains everything in context.

Two excel sheets, one is updated manually (Vikki's Yearly Averages.xls), while the other is for reporting (biweekly.xls)

The coding will all be in biweekly.xls.

First, it needs to take a date to the right of a name from biweekly.xls and use the month and year from that date for the search.

Then it needs to look in VYK.xls under the name and copy every entry starting in the year specified and month specified and ending at the current date.

View 6 Replies View Related

Excel 2003 :: How To Combine Text If In Month

Sep 5, 2013

I need an Excel 2003 compatible solution for this. Formulae only, no Macros or VBA in this case. The limitation set by the organisation we report to.

On sheet LGFC I have clients with their attendance hours, notes and the relevant dates.

01/07/2013
01/07/2013
08/07/2013
08/07/2013
15/07/2013
15/07/2013
Ref No
Name Carer
Name Client
Active

[code]....

To really test if this works you need to extend this over more than one month. My sheet goes on for a full financial year and of course with rows of clients. I now need to report per month. However, next financial year the month column locations may vary.

We need to report per month.I am able to sum up the month's total hours for all clients (E3 to J26) with the following formula (which ignores text). Data!$G3 gives the relevant month in date format (1/7/2013).

=SUM(IF(ISNUMBER(LGFC!1:1),IF(LGFC!1:1-DAY(LGFC!1:1)+1=Data!$G3,LGFC!3:26)))
array formula: Ctrl Shift Enter

This results (example data) in 10 hours. (if I had a client 2 with zero hours, and a client 3 with another 10 hours it would result in 20 hours)

Now my next step would be to report any notes. So I want to find all the text in that month and concatenate it into one cell. I started with this formula, but that doesn't work and gives a FALSE.

Doesn't work!

=CONCATENATE(IF(ISNUMBER(LGFC!1:1),IF(LGFC!1:1-DAY(LGFC!1:1)+1=Data!G3,LGFC!3:26)))
array formula: Ctrl Shift Enter

Doesn't work!

Ideally I would not just want everything jumbled into one concatenation, but even that would be acceptable. (It is unlikely that there would be more than 255 cells with notes.)

Based on the above example the ideal result would look like:

1 Mrs Test, unwell, left early, Sick

But I would accept just the notes unwell, left early, Sick

It needs to ignore blank cells. With multiple clients it would ideally look like:

1 Mrs Test, unwell, left early, Sick

2 Mr Best, in hospital, visiting family, Sick

or

1 Mrs Test, unwell, left early, Sick / 2 Mr Best, in hospital, visiting family, Sick If we want to include the Ref No and Client Name it probably needs another if statement. "If there is text to concatenate that month/row than include Ref No and Client Name."

View 1 Replies View Related

Auto Populate Calendar Days Based On Month / Year And Auto Insert Work Based On Dates / Name

Jul 31, 2013

I am trying to auto generate a calendar based on two drop down menus - Month and Year.

Once the month and year is selected I want to import all work orders onto the calendar based first on the "Labor Name" found in the list of work tab, then assign each work order for that labor name to the respective date on the calendar for the month.

August PM Schedule Demo.xlsx

View 2 Replies View Related

Input Date In A Cell Will Show Month And Year Based In Database From MS Access

Jun 1, 2014

I have my ms access and ms excel which is connected each other .

=> now in my ms access have a table name (tblMonth) has columns (year,MonthNum,StartDate,EndDate)
HERE: sample in january(1) and feb(2)

YearMonthNum StartDate EndDate
2014 130/12/201305/01/2014
2014 106/01/201412/01/2014
2014 1 13/01/201419/01/2014
2014 120/01/201426/01/2014
2014 127/01/201402/02/2014
2014 203/02/201409/02/2014
2014 2 10/02/2014 16/02/2014
2014 217/02/201423/02/2014
2014 224/02/201402/03/2014

=> 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

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved