PDA

View Full Version : Solved: total by company



ndendrinos
10-07-2009, 06:03 AM
In this workbook example the codes filter the customers invoices by company and introduce a "separating " grey row in between them.

I would like to use if possible these blank rows to show
totals in column E
Thank you

stanleydgrom
10-07-2009, 07:50 AM
ndendrinos,

See the attached workbook "DO LOOP LR SR NR ER - total by company - ndendrinos - SDG10.xls" with new code added to your CommandButton1_Click Event.


Have a great day,
Stan

ndendrinos
10-07-2009, 08:18 AM
excellent Stan . will have to look at how you've introduced that coloured line at the bottom. I was working on a same idea but forgot to introduce a last coloured row and the thing been looping for the last hour.
Have a great day too.

stanleydgrom
10-08-2009, 06:39 AM
ndendrinos,


will have to look at how you've introduced that coloured line at the bottom.




LR = Cells(Rows.Count, 3).End(xlUp).Row
Range("A" & LR + 1 & ":E" & LR + 1).Interior.ColorIndex = 15





I just don't know how to write code ...

Training / Books / Sites

How to Learn to Write Macros http://articles.excelyogi.com/playin...ba/2008/10/27/ (http://articles.excelyogi.com/playin...ba/2008/10/27/)

How to use the macro recorder http://articles.excelyogi.com/ (http://articles.excelyogi.com/)

Click here and scroll down to Getting Started with VBA. http://www.datapigtechnologies.com/ExcelMain.htm (http://www.datapigtechnologies.com/ExcelMain.htm)

If you are serious about learning VBA try http://www.add-ins.com/vbhelp.htm (http://www.add-ins.com/vbhelp.htm)

Excel Tutorials and Tips - VBA - macros - training http://www.mrexcel.com/articles.shtml (http://www.mrexcel.com/articles.shtml)

See David McRitchie's site if you just started with VBAhttp://www.mvps.org/dmcritchie/excel/getstarted.htm (http://www.mvps.org/dmcritchie/excel/getstarted.htm)

Debra Dalgleish has some notes how to implement macros here:http://www.contextures.com/xlvba01.html (http://www.contextures.com/xlvba01.html)

David McRitchie has an intro to macros:http://www.mvps.org/dmcritchie/excel/getstarted.htm (http://www.mvps.org/dmcritchie/excel/getstarted.htm)

(livelessons video)Excel VBA and Macros with MrExcelISBN: 0-7897-3938-0http://www.amazon.com/Excel-Macros-M...7936479&sr=1-1 (http://www.amazon.com/Excel-Macros-M...7936479&sr=1-1)

http://www.xl-central.com/index.html (http://www.xl-central.com/index.html)

Excel 2003 Power Programming with VBA, by John Walkenbach
VBA and Macros for Microsoft Excel, by Bill Jelen "Mr.Excel" and Tracy Syrstad
Excel Hacks 100 Industrial-Strength Tips & Tools, by David & Traina Hawley
VBA and Macros for Microsoft Excel 2007, by Bill Jelen "Mr.Excel" and Tracy Syrstad

Excel 2007 Book: you can try this...there is a try before you buy ebook available at this link…http://www.mrexcel.com/learnexcel2.shtml (http://www.mrexcel.com/learnexcel2.shtml)



And, as your skills increase, try answering posts on sites like:
http://www.excelforum.com/ (http://www.excelforum.com/)
http://www.mrexcel.com/ (http://www.mrexcel.com/)
http://www.ozgrid.com/ (http://www.ozgrid.com/)
http://www.vbaexpress.com/portal.php (http://www.vbaexpress.com/portal.php)
http://p2p.wrox.com/excel-vba-79/ (http://p2p.wrox.com/excel-vba-79/)


Have a great day,
Stan

ndendrinos
10-08-2009, 08:00 AM
The macro recorder I know how to use :biglaugh: