Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,071
Default Entering Formula with "" within it

A technique that I routinely use is to turn on the macro recorder and
enter the formula in a cell. Turn off the recorder and XL will give
you the correct VBA code! :)

--
Regards,

Tushar Mehta
www.tushar-mehta.com
Excel, PowerPoint, and VBA add-ins, tutorials
Custom MS Office productivity solutions

In article , "=?
Utf-8?B?Um9uIE1jQ29ybWljaw==?="
says...
I am trying to write the appropriate code to enter a formula along the
following lines into a particular cell in a worksheet.

=IF(Range1= "",Range2, Range1)

I've been advised that I should use coded version of the quotes
incorporating Chr (34) - something like:

strQuote = Chr(34)
ActiveCell.Formula = "=IF(Range1= "& Chr(34) &" ,Range2,Range1)"

but I can't seem to get the syntax quite right.

Any help would be appreciated.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Entering an "IF" formula Chris Cullen[_2_] Excel Discussion (Misc queries) 10 July 13th 09 04:55 AM
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
change "true" and "false" to "availble" and "out of stock" inthestands Excel Worksheet Functions 2 July 19th 07 07:05 PM
Format cell to display "Y" or "N"when entering a 1 or zero Brad Excel Discussion (Misc queries) 7 February 8th 07 06:50 PM
Count occurences of "1"/"0" (or"TRUE"/"FALSE") in a row w. conditions in the next BCB New Users to Excel 7 May 13th 06 10:02 PM


All times are GMT +1. The time now is 12:26 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"