Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
More elaboration on help pages
I just reviewed the example in the Help for ReplaceFormat. Then I
went to the Help for Replace method as applied to a Range object. From that description, I would never have guessed that providing empty strings for the What and Replacement "variants" would yield the effect implied by the ReplaceFormat example. For example, I thought that the ReplaceFormat would only affect replacement text. Are there more comprehensive help pages (possibly on the web) on these classes that elaborate on the terse descriptions in the Help? As a newbie to VBA, and from experience in other environments, I intend to rely quite a bit on accurate, comprehensive, and well organized documentation to figure out how to code. VBA's help seems well organized, but actual descriptive text seems quite terse and incomplete. Is there some kind of definitive standard that one could resort to in order to suss out the subtleties of meaning (which often aren't very subtle in their coding implications)? Thanks. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
More elaboration on help pages
the Help looks perfectly fine to me -- i see no empty strings. Can you
clarify your problem please? from Help: Sets the replacement criteria to use in replacing cell formats. expression.ReplaceFormat expression Required. An expression that returns one of the objects in the Applies To list. Example The following example sets the search criteria to find cells containing Arial, Regular, Size 10 font, replaces their formats with Arial, Bold, Size 8 font, and then notifies the user. Sub MakeBold() ' Establish search criteria. With Application.FindFormat.Font .Name = "Arial" .FontStyle = "Regular" .Size = 10 End With ' Establish replacement criteria. With Application.ReplaceFormat.Font .Name = "Arial" .FontStyle = "Bold" .Size = 8 End With ' Notify user. With Application.ReplaceFormat.Font MsgBox .Name & "-" & .FontStyle & "-" & .Size & _ " font is what the search criteria will replace cell formats with." End With End Sub " wrote: I just reviewed the example in the Help for ReplaceFormat. Then I went to the Help for Replace method as applied to a Range object. From that description, I would never have guessed that providing empty strings for the What and Replacement "variants" would yield the effect implied by the ReplaceFormat example. For example, I thought that the ReplaceFormat would only affect replacement text. Are there more comprehensive help pages (possibly on the web) on these classes that elaborate on the terse descriptions in the Help? As a newbie to VBA, and from experience in other environments, I intend to rely quite a bit on accurate, comprehensive, and well organized documentation to figure out how to code. VBA's help seems well organized, but actual descriptive text seems quite terse and incomplete. Is there some kind of definitive standard that one could resort to in order to suss out the subtleties of meaning (which often aren't very subtle in their coding implications)? Thanks. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
More elaboration on help pages
The Replace Method is for replacing cell values and strings. The
ReplaceFormat method is for just that, replacing formats. VBA is an object oriented langauge. The objects are modified by their properties. John Walkenbach has a good book for beginners, available through Amazon.Com, titled Excel VBA Programming for Dummies which sells at a reasonable price. It explains a lot of these type issues in detail. wrote in message ... I just reviewed the example in the Help for ReplaceFormat. Then I went to the Help for Replace method as applied to a Range object. From that description, I would never have guessed that providing empty strings for the What and Replacement "variants" would yield the effect implied by the ReplaceFormat example. For example, I thought that the ReplaceFormat would only affect replacement text. Are there more comprehensive help pages (possibly on the web) on these classes that elaborate on the terse descriptions in the Help? As a newbie to VBA, and from experience in other environments, I intend to rely quite a bit on accurate, comprehensive, and well organized documentation to figure out how to code. VBA's help seems well organized, but actual descriptive text seems quite terse and incomplete. Is there some kind of definitive standard that one could resort to in order to suss out the subtleties of meaning (which often aren't very subtle in their coding implications)? Thanks. |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
More elaboration on help pages
The actual code in question follows the code that you pasted...here is
the remainder of the example: ' Make the replacements in the worksheet. Cells.Replace What:="", Replacement:="", _ SearchFormat:=True, ReplaceFormat:=True Again, this was provided just as an example. I was wondering if there were help pages online that elaborate more (in general). Thanks. |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
More elaboration on help pages
I'm relatively comfortable with OOP, though in C++/STL/matlab. The
example to which I'm referring is in ReplaceFormat help page, but makes use of Replace. It's the example implies things about how Replace works with null strings in What and Replacement which is not apparent from the Replace help page. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Number of pages in worksheet doesn't match Print Preview pages | Excel Discussion (Misc queries) | |||
How do I delete pages in Excel? Keeps printing blank pages at end. | Charts and Charting in Excel | |||
Need Help -- Baseball stats in excel only has 23 pages--Need to addmore pages.. | Setting up and Configuration of Excel | |||
Need Help -- Baseball stats in excel only has 23 pages--Need to addmore pages... | Excel Worksheet Functions | |||
How do I delete pages from an Excell template of mutiple pages | Excel Discussion (Misc queries) |