Registrations are now open. Join us today!
There is still a lot of work to do on the wiki yet! More information about editing can be found here.
Already have an account?

Microsoft KB Archive/34275

From BetaArchive Wiki
Knowledge Base

BUG: Change Option in Search Menu May Not Replace All Values

Article ID: 34275

Article Last Modified on 11/21/2006

This article was previously published under Q34275


There is a problem with the "Replace all occurrences" feature of the Change... option in the Search menu. When there are multiple occurrences of the item being searched for on the same line, and the insertion point is on the next line when the search is initiated, only the first occurrence of the item on the previous line is replaced. All other replacements are done properly.

Selecting "Verify before replacing" does not correct this problem with "Replace all occurrences."

Microsoft has confirmed this to be a bug in the Microsoft QuickBasic Compiler Version 1.00. We are researching this problem and will post new information as it becomes available.

To work around this problem, place the insertion point anywhere except right after a line with multiple occurrences of the search text.


The following steps demonstrate the problem:

  1. Run QuickBasic and type the following program into the Listing window:

          DIM y(1,1,1,1,1,1)
          DIM x(1,1,1,1,1,1)
          PRINT "test 1"
  2. Place the insertion point (the flashing vertical bar) anywhere on the PRINT "test 1" line.
  3. Select Change... from the Search menu (or press COMMAND-H).
  4. Specify to find "1" and replace it with "2".
  5. Activate the "Replace all occurrences" box.
  6. Click OK.
  7. Only the first "1" on the "DIM x" line will be replaced with "2". All other occurrences of "1" in the program are successfully changed to "2".

Additional query words: MQuickB

Keywords: kbbug KB34275