From: Michael Lanier on 28 Apr 2010 10:39 I need a macro that will convert a cell's formula to reflect its formula result only based on the following: Range is A10:C200 Only when formula's result > 0 Execute upon closing the file Thanks for any help you can provide. Michael
From: Bob Phillips on 28 Apr 2010 10:55 For Each cell In Range("A10:C200") If cell.Value2 > 0 Then cell.Value2 = cell.Value2 End If Next cell -- HTH Bob "Michael Lanier" <michaelrlanier(a)gmail.com> wrote in message news:4e59c63e-158f-4f39-9310-52511fec6ae2(a)k33g2000yqc.googlegroups.com... >I need a macro that will convert a cell's formula to reflect its > formula result only based on the following: > > Range is A10:C200 > Only when formula's result > 0 > Execute upon closing the file > > Thanks for any help you can provide. > > Michael
From: Don Guillett on 28 Apr 2010 11:11 Sub convertformulas() Dim c As Range For Each c In Range("p3:p8").SpecialCells(xlCellTypeFormulas) If c > 0 Then c.Value = c.Value Next c End Sub -- Don Guillett Microsoft MVP Excel SalesAid Software dguillett(a)gmail.com "Michael Lanier" <michaelrlanier(a)gmail.com> wrote in message news:4e59c63e-158f-4f39-9310-52511fec6ae2(a)k33g2000yqc.googlegroups.com... >I need a macro that will convert a cell's formula to reflect its > formula result only based on the following: > > Range is A10:C200 > Only when formula's result > 0 > Execute upon closing the file > > Thanks for any help you can provide. > > Michael
From: Michael Lanier on 28 Apr 2010 13:07 Bob and Don, I did something wrong with Bob's so I failed to get it to work but Don's worked fine. Thank you both for your time. Michael
|
Pages: 1 Prev: Macro to save a workbook Next: VBA to open a PDF, print, then close - Stumped |