|
-
Apr 22nd, 2005, 04:18 AM
#1
Re: Excel - Change cell formula from nested IFs to ??
 Originally Posted by RobDog888
I need more info on what type of event you need to call this from.
It would need to be a replacement for a formula in a range of cells. Basically, each cell in column K has that formula in it, but new values will be getting added regularly, and I don't want to have to maintain that big IF statement.
The only event I found was Sheet_Calculate, but I don't know how to figure out which cell has changed in order to update it.
As for the teeth, please transfer $458 for s/h to my Paypal and they are as good as yours.
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
-
Apr 22nd, 2005, 07:26 AM
#2
Re: Excel - Change cell formula from nested IFs to ??
Resolved by me. I figured out how to link a function in a module to the formula.
So I'll keep the teeth.
:evil:
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
-
Apr 22nd, 2005, 07:40 AM
#3
Addicted Member
Re: Excel - Change cell formula from nested IFs to ??
hi,
can you post how you achieved the resolution?
I would be interested to know.
Thnx
if you fail to plan, you plan to fail
-
Apr 22nd, 2005, 07:01 PM
#4
Re: Excel - Change cell formula from nested IFs to ??
 Originally Posted by Br1an_g
hi,
can you post how you achieved the resolution?
I would be interested to know.
Thnx 
It actually turned out to be pretty easy. Add a module, and make a public function.
Code:
Public Function ReturnSomeValue(CellValue) As Double
ReturnSomeValue = Val(CellValue) * 2.24
End Function
Then make the formula in the cell "=ReturnSomeValue(H4)" and it should work fine. I guess it gets a little hinky passing ranges of cells in, I only needed to worry about one cell at a time.
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
-
Apr 22nd, 2005, 10:19 AM
#5
Re: Excel - Change cell formula from nested IFs to ??
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|