https://bugs.documentfoundation.org/show_bug.cgi?id=158185
Bug ID: 158185
Summary: VBA Support 1: The Range.Find method interprets "#" as
a wildcard character
Product: LibreOffice
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: Calc
Assignee: [email protected]
Reporter: [email protected]
Run the following macro on a Calc document that has Sheet1:
Option VBASupport 1
Option Explicit
Sub test()
With Worksheets("Sheet1")
Dim r As Range
.Range("A1").Value = "#a"
.Range("A2").Value = "1a"
Set r = .Cells.Find(What:="#a", LookIn:=xlValues, LookAt:=xlPart, _
SearchOrder:=xlByRows, SearchDirection:=xlNext, MatchCase:=False,
SearchFormat:=False)
If Not (r Is Nothing) Then MsgBox "Found " & r.Address
End With
End Sub
Result: Found $A$2
Excel VBA shows: Found $A$1
Possible reason for the discrepancy: Calc interprets the # sign as a wildcard
character, Excel does not.
--
You are receiving this mail because:
You are the assignee for the bug.