Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VBA Code to return a summary sheet of due actions Excel 2003 ? 1

Status
Not open for further replies.

ambquinn

IS-IT--Management
Jun 12, 2011
2
GB
I'd really appreciate some help on this one as I'm totally confused. I am using Microsot Excel 2003. The idea is fairly simple I have a large workbook, one spreadsheet of which (called review dates) is of client names with corresponding review dates (2 weekly, 3/6/12/18 monthly etc, etc). The columns are conditionally formatted to highlight any dates that fall within a week of the present date but its very time consuming and errror prone to scroll through hundreds of rows of client names plus across a number of columns looking for any due reviews. The idea is then to have a single summary worksheet report, to return all due actions detailing clients name, the date that a review is due and the type of review due, (eg 3 month). As stated any help at all would be good, I'm very new to VBA. Many thanks
A
 



hi,

Please post a clear description of the structure of your sheet, describing all columns and the data therein. Please explain how this data is related. It seems that your data is not normalized and needs to be.

Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Sounds like you'd need to make a macro like the following to do everything:

date1=range("cell") 'starting date
date2=range("cell") 'ending date
y = 3 'starting row for data on Output Sheet
for x = 3 to 5000 ' 3 and 5000 are your starting and ending rows
if range("A"+trim(str(x))) >= date1 and range("A"+trim(str(x)))< date2 then
row(x).copy
Sheets("OutputSheet").Select ' Goes the Output Sheet
range("A"+trim(str(y))).paste
y = y+1
Sheets("InputSheet").Select 'Goes back to the Input Sheet
end if
next x

 
Many thanks to both for your help - very much appreciated
A
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top