Solved

How do I paste these complicated formulas into excel VBA

Posted on 2014-04-10
4
219 Views
Last Modified: 2014-04-12
How do I paste these formulas into VBA with excel?

= IIf(Evaluate(Worksheets("Tickets").Cells(r1, "A").Value * Worksheets("Tickets").Cells(r1, "B").Value) < Evaluate(Worksheets("OtherSheets").Cells(r1, "D")), 1, 0)

and

a = IIf(Evaluate(Worksheets("Tickers").Cells(r1, "A").Value * Worksheets("OtherSheet").Range("$d$1").Value) < Evaluate(Worksheets("thisSheet").Range("$e$1")), 1, 0)

and get them "paste ready" in this form?:

"= If(quotes!V" & i & ">Constants!AK" & i & ", 1, 0)"


thanks for your help!
0
Comment
Question by:BostonBob
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 22

Expert Comment

by:plusone3055
ID: 39992493
how about you watch a nice video on this topic  

Convert MS Excel Formula to VBA code
https://www.youtube.com/watch?v=OADbmMboIRo

a nice conversion table that goes along with it
http://www.techonthenet.com/excel/formulas/convert.php
0
 

Author Comment

by:BostonBob
ID: 39992996
I have seen that video. I am pretty handy now doing the smaller formulas but I can't seem to make this work.

Any mercy you can bestow on me my lord would be much appreciated!

thanks!
0
 
LVL 27

Accepted Solution

by:
MacroShadow earned 500 total points
ID: 39996545
"= IIf(Evaluate(Worksheets(""Tickets"").Cells(r1, ""A"").Value * Worksheets(""Tickets"").Cells(r1, ""B"").Value) < Evaluate(Worksheets(""OtherSheets"").Cells(r1, ""D"")), 1, 0)"

Open in new window

"a = IIf(Evaluate(Worksheets(""Tickers"").Cells(r1, ""A"").Value * Worksheets(""OtherSheet"").Range(""$d$1"").Value) < Evaluate(Worksheets(""thisSheet"").Range(""$e$1"")), 1, 0)"

Open in new window

0
 

Author Comment

by:BostonBob
ID: 39996748
Thanks for that.  I will check them now.  

I just posted another question.  Easy pickings for you....

thanks!
0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For a while now I'v been searching for a circular progress control, much like the one you get when first starting your Silverlight application. I found a couple that were written in WPF and there were a few written in Silverlight, but all appeared o…
With User Account Control (UAC) enabled in Windows 7, one needs to open an elevated Command Prompt in order to run scripts under administrative privileges. Although the elevated Command Prompt accomplishes the task, the question How to run as script…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Attackers love to prey on accounts that have privileges. Reducing privileged accounts and protecting privileged accounts therefore is paramount. Users, groups, and service accounts need to be protected to help protect the entire Active Directory …

710 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question