• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

How to pass cell value in HTML code using VBA

ThrottleWorks

Excel Ninja
Hi,

How to change -007.07 with cell value. I tried Google but not able get the result properly.
Can anyone please tell me how do I replace -007.07 with range value.

-007.07 is amount and will keep changing so I need to pass a cell value for this.
I am not able to edit below mentioned line to get the proper results. Can anyone please help me in this.

strbody = strbody & "<p style='font-family:calibri;font-size:15;color:red'>For -007.07 Amount</p>"
 
Hi Sachin ,

Have you tried something like :

strbody = strbody & "<p style='font-family:calibri;font-size:15;color:red'>For " & [A1] & " Amount</p>"

where the cell A1 contains the amount ?

Narayan
 
Back
Top