Solved

Enter a formula string in Excel VBA (division)

Posted on 2014-01-16
2
656 Views
Last Modified: 2014-01-16
Dear Experts:

I need to enter a formula into K71 as a string. The formula is as follows:

Range("J71") / Range("$B$6").

I got no idea how this works in Excel VBA.

Could somebody please help me with this?

Thank you very much in advance.

Regards, Andreas


strFormula = formula string?

ActiveWorkbook.Sheets("Evaluation").Range("K71").Formula = strFormula
0
Comment
Question by:AndreasHermle
[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 Comments
 
LVL 27

Assisted Solution

by:MacroShadow
MacroShadow earned 250 total points
ID: 39786298
Range("K71").Formula = "=J71/$B$6" 

Open in new window

0
 
LVL 51

Accepted Solution

by:
Rgonzo1971 earned 250 total points
ID: 39786300
Hi,

pls try

strFormula = "=J71/$B$6"
ActiveWorkbook.Sheets("Evaluation").Range("K71").Formula = strFormula

Open in new window

Regards
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

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

This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
This Micro Tutorial will demonstrate in Microsoft Excel how to add style and sexy appeal to horizontal bar charts.
This Micro Tutorial will demonstrate the scrolling table in Microsoft Excel using the INDEX function.

751 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